[6.1]Cash registers add new statement line - crash

Bug #1075070 reported by dana ilinca
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Committed
Medium
OpenERP Publisher's Warranty Team

Bug Description

6.1

I tried to add a new statement line in cash registers but i get the error : Error: Unknown field state in domain [["state","in",["confirm"]]].
I checked the error, is related with account_bank_statement_extensions. The problem can be reproduce also on http://6_1_23953.runbot.openerp.com.

Regards,

Dana

Tags: maintenance

Related branches

Revision history for this message
dana ilinca (dilinca) wrote :
Changed in openobject-addons:
status: New → Confirmed
summary: - Cash registers add new statement line - crash
+ [6.1]Cash registers add new statement line - crash
Changed in openobject-addons:
importance: Undecided → Medium
assignee: nobody → OpenERP Publisher's Warranty Team (openerp-opw)
Revision history for this message
dana ilinca (dilinca) wrote :

Hi,

The solution is to replace in account_view.xml the line <page string="Cash Transactions" attrs="{'invisible': [('state','=','draft')]}">
with this : <page string="Cash Transactions" name="statement_lines" attrs="{'invisible': [('state','=','draft')]}">.
And in account_bank_statement_view.xml add the state

 <!-- add state to bank statement line -->
    <record id="view_bank_statement_form2_add_fields" model="ir.ui.view">
       <field name="name">view.bank.statement.form2.add.fields</field>
       <field name="model">account.bank.statement</field>
       <field name="inherit_id" ref="account.view_bank_statement_form2"/>
      <field name="type">form</field>
      <field name="arch" type="xml">
        <data>
          <xpath expr="/form/notebook/page[@name='statement_lines']/field[@name='line_ids']/tree/field[@name='date']" position="after">
            <field name="state" invisible="1"/>
          </xpath>
          <xpath expr="/form/notebook/page[@name='statement_lines']/field[@name='line_ids']/form/field[@name='date']" position="after">
            <field name="state" invisible="1"/>
          </xpath>
        </data>
      </field>
    </record>

Dana

Revision history for this message
Charles DOUKOURE (charlyjob) wrote :

6.1
For me, any error message but I click on another place the sub total field become empty.
Also, I can not Open cash, i don't know if the problems are linked

Excuse my english, i'm french ...

Revision history for this message
Charles DOUKOURE (charlyjob) wrote :

Here, find my screen during i want to add a cash line.
thank

tags: added: maintenance
Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
Rifakat Husen (OpenERP) (rha-openerp) wrote :

Thanks dana ilinca for your contribution.

I have committed it in,
lp:~openerp-dev/openobject-addons/6.1-opw-587814-rha
r7184, Revision ID: <email address hidden>

I will be soon merged into stable 6.1 mainline.
Best regards.

Changed in openobject-addons:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.