コンテンツへスキップ
メニュー
この質問にフラグが付けられました

I'm using the Partner Affiliate module and have extended sale.order to include a many2one partner_affiliate_id field. Now, in the Sale Order Form, when creating a new Partner Affiliate, I need to include the partner_affiliate_id and partner_id (to be set as the affiliate's parent_id) in the vals that are passed to the res.partner create() method.


How can I add these fields to vals?

アバター
破棄
最善の回答

One method is that you can send the partner_affiliate_id​ in the context fromsale.order​ and get that value in create​ method of res.partner​ like `affiliate_partner_id = self._context.get('partner_affiliate_id​')`.

アバター
破棄
関連投稿 返信 ビュー 活動
3
5月 24
2216
2
4月 24
2000
0
4月 24
933
2
11月 21
2305
0
9月 24
1244