Add party name to a list of orderlines

15 views
Skip to first unread message

edbo....@gmail.com

unread,
May 16, 2018, 1:52:14 PM5/16/18
to tryton-dev
Last weekend we finally migrated from OpenERP v5 to Tryton and are already happy with the system. However during working with Tryton colleagues discovered some issues which are not available in Tryton (yet). So we decided to implement them.

One of the issues is that they searched a lot in order-lines (sale, invoice, purchase) and filter them on party or on product or on both. In OpenERP this was already there and they got used to it to get easy an overview what a client has both in the past and for which price.

Creating a new list in Tryton isn't hard, but we couldn't find an example on how to get the party name also in the list of orderlines. We already created a very simple orderline tree:
<tree>
<field name="sale"/>
<field name="description"/>
<field name="quantity"/>
<field name="unit"/>
<field name="unit_price"/>
<field name="amount"/>
</tree>

But we want also a field
<field name="party"/>
in the tree with the party name. The part name isn't available on the orderline, but in the parent order. Adding sale.party or something didn't work. Is this possible without adding an extra function-field? and how can this be solved?


Thanks!

Maxime Richez

unread,
May 17, 2018, 3:07:44 AM5/17/18
to tryton-dev
For me best solution is to add a function field party on your orderline
Reply all
Reply to author
Forward
0 new messages