Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
4554 มุมมอง

Hallo

I defined a new tree view for account.invoice, with new fields, with id "tree_account_followup".

I'd like to open the "traditional" (native, original) account.invoice_form when the user clicks on that tree view row.

I wrote this action

<record id="act_unpaid" model="ir.actions.act_window">
<field name="name">Invoice followups</field>
<field name="res_model">account.invoice</field>
<field name="view_type">form</field>
<field name="view_mode">tree, form</field>
<field name="domain">[('state', '=', 'statement'), ('days_unpaid', '&gt;', 0)]</field>
</record>

<record id="act_unpaid_tree" model="ir.actions.act_window.view">
<field eval="20" name="sequence"/>
<field name="view_mode">tree</field>
<field name="view_id" ref="tree_account_followup"/>
<field name="act_window_id" ref="act_unpaid"/>
</record>
  1.  SOLVED: Qweb fails loading the treeview complaining about a domain which is not defined in this action.

  2. the form opens with no values in it

How should I write the window action?

อวตาร
ละทิ้ง
ผู้เขียน

I solved a first issue.

Same old mistake, every time: in the treeview I didn't include the "state" field which was referenced in the domain of the window action.

Related Posts ตอบกลับ มุมมอง กิจกรรม
0
มิ.ย. 24
1186
1
ก.ค. 20
3203
2
เม.ย. 22
4869
9
พ.ค. 21
27053
0
ธ.ค. 15
3265