This commit is contained in:
2026-03-12 10:24:34 +01:00
parent b07ad57a36
commit 23c4edfec5
2 changed files with 11 additions and 1 deletions

View File

@@ -494,7 +494,13 @@ class Sale(metaclass=PoolMeta):
for d in line.derivatives:
line.unit_price = d.price_index.get_price(Date.today(),line.unit,line.currency,True)
Line.save([line])
class PriceComposition(ModelSQL,ModelView):
__name__ = 'price.composition'
component = fields.Char("Component")
price = fields.Numerci("Price")
class SaleLine(metaclass=PoolMeta):
__name__ = 'sale.line'
@@ -588,6 +594,7 @@ class SaleLine(metaclass=PoolMeta):
)
pricing_rule = fields.Text("Pricing description")
price_composition = fields.One2Many('price.composition',"Price composition")
@property
def report_fixing_rule(self):

View File

@@ -53,6 +53,9 @@ this repository contains the full copyright notices and license terms. -->
<field name="certif"/>
</xpath>
<xpath expr="/form/notebook/page[@id='taxes']" position="before">
<page string="Price composition" col="4" id="pc">
<field name="price_composition"/>
</page>
<page string="Lots" col="4" id="lots">
<field name="lots" view_ids="lot.lot_view_tree_sequence"/>
</page>