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

I am currently trying to create a custom product discount line.

I got all working but the problem is that I need to know how to update the invoice line values to make my project work.

I tried using "object.write" but it only creates another line of "Product Discount".

I don't want to use the "% discount" of the product because I have my own computations.

here is the sample below:

Any help would be greatly appreciated...


アバター
破棄
最善の回答

Perhaps it's a late answer, however I've recently done something similar and I inherited the model (\account.move.line, in your case) and overrun the create() and _compute_amount() methods, replaceing the native dicount parameter with the custom_discount one, or your own custom computations.

アバター
破棄
関連投稿 返信 ビュー 活動
2
5月 24
7263
1
1月 20
6812
2
7月 17
8198
1
1月 16
4278
0
9月 15
4799