Commits

Udo Spallek committed 5a4d57f

Add context party_role='bank' to bank view. Fix PySON.

Comments (0)

Files changed (2)

         </record>
         <record model="ir.action.act_window" id="act_bank_view">
             <field name="name">Banks</field>
+            <field name="context">{'party_role': 'bank'}</field>
             <field name="res_model">bank.bank</field>
             <field name="view_type">form</field>
         </record>
                         expr="/form/notebook/page[@id=&quot;accounting&quot;]"
                         position="after">
                         <page string="Bank Accounts" col="1" id="bank_accounts"
-				states="{'invisible':
-					Or(Not(Eval('bank_code', True)), Eval('bank_code', False))}">
+				states="{'invisible':Equal(Get(Eval('context', {}), 'party_role'), 'bank')}">
                             <field name="bank_accounts"/>
                         </page>
                     </xpath>