This commit allows to call name_search with context key
res_partner_search_mode that can take currently two values: "customer" or
"supplier".
When ordering search results, order partners by the number of SO they have when
the value is "customer" and by the number of PO if the value is "supplier".
Top suppliers/customers are displayed above in a PO/SO partner dropdown.
We have thought about different implementations before selecting this one
res.user
将many2one
字段res.partner
命名为partner_id
,您可以像这样提取用户的所有合作伙伴:如果要使用其他字段(如
^{pr2}$name
)筛选合作伙伴:比较或者使用
customer
字段对您来说更像是一种巧合,因为您的Odoo中没有customer
或supplier
不是用户的合作伙伴。在但是你真的应该用
user_ids
来代替,对于每一个像odoo8的版本。因为这是一个使用res.users
partner_id
字段作为关系的one2many字段,它应该始终有效。在您可以在base: Remove customer/supplier fields on res.partner提交消息中找到详细的解释和示例。在
摘录
相关问题 更多 >
编程相关推荐