Pricing Fixed Component
This commit is contained in:
@@ -707,12 +707,24 @@ class Component(ModelSQL, ModelView):
|
||||
|
||||
fix_type = fields.Many2One('price.fixtype',"Fixation type")
|
||||
ratio = fields.Numeric("%",digits=(16,7))
|
||||
price_index = fields.Many2One('price.price',"Curve")
|
||||
price_matrix = fields.Many2One('price.matrix', "Price Matrix")
|
||||
price_index = fields.Many2One(
|
||||
'price.price', "Curve",
|
||||
states={
|
||||
'readonly': Eval('price_source_type') != 'curve',
|
||||
'required': Eval('price_source_type') == 'curve',
|
||||
},
|
||||
depends=['price_source_type'])
|
||||
price_matrix = fields.Many2One(
|
||||
'price.matrix', "Price Matrix",
|
||||
states={
|
||||
'readonly': Eval('price_source_type') != 'matrix',
|
||||
'required': Eval('price_source_type') == 'matrix',
|
||||
},
|
||||
depends=['price_source_type'])
|
||||
fixed_price = fields.Numeric(
|
||||
"Fixed Price", digits=(16, 6),
|
||||
states={
|
||||
'invisible': Eval('price_source_type') != 'fixed',
|
||||
'readonly': Eval('price_source_type') != 'fixed',
|
||||
'required': Eval('price_source_type') == 'fixed',
|
||||
},
|
||||
depends=['price_source_type'])
|
||||
|
||||
@@ -7,12 +7,12 @@
|
||||
<label name="ratio"/>
|
||||
<field name="ratio"/>
|
||||
<newline/>
|
||||
<label name="price_index"/>
|
||||
<label name="price_index"/>
|
||||
<field name="price_index"/>
|
||||
<label name="currency"/>
|
||||
<field name="currency"/>
|
||||
<label name="fixed_price"/>
|
||||
<field name="fixed_price"/>
|
||||
<label name="currency"/>
|
||||
<field name="currency"/>
|
||||
<newline/>
|
||||
<label name="auto"/>
|
||||
<field name="auto"/>
|
||||
|
||||
@@ -7,12 +7,12 @@
|
||||
<label name="ratio"/>
|
||||
<field name="ratio"/>
|
||||
<newline/>
|
||||
<label name="price_index"/>
|
||||
<label name="price_index"/>
|
||||
<field name="price_index"/>
|
||||
<label name="currency"/>
|
||||
<field name="currency"/>
|
||||
<label name="fixed_price"/>
|
||||
<field name="fixed_price"/>
|
||||
<label name="currency"/>
|
||||
<field name="currency"/>
|
||||
<newline/>
|
||||
<label name="auto"/>
|
||||
<field name="auto"/>
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<tree editable="1">
|
||||
<field name="price_source_type"/>
|
||||
<field name="fix_type"/>
|
||||
<field name="ratio" width="60"/>
|
||||
<field name="ratio" width="60"/>
|
||||
<field name="price_index"/>
|
||||
<field name="price_matrix"/>
|
||||
<field name="currency" width="60"/>
|
||||
<field name="fixed_price" width="80"/>
|
||||
<field name="currency" width="60"/>
|
||||
<field name="auto" width="60"/>
|
||||
<field name="fallback" width="80"/>
|
||||
<field name="calendar"/>
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<tree editable="1">
|
||||
<field name="price_source_type"/>
|
||||
<field name="fix_type"/>
|
||||
<field name="ratio"/>
|
||||
<field name="ratio"/>
|
||||
<field name="price_index"/>
|
||||
<field name="price_matrix"/>
|
||||
<field name="currency"/>
|
||||
<field name="fixed_price"/>
|
||||
<field name="currency"/>
|
||||
<field name="auto"/>
|
||||
<field name="fallback"/>
|
||||
<field name="calendar"/>
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<tree editable="1">
|
||||
<field name="price_source_type"/>
|
||||
<field name="fix_type"/>
|
||||
<field name="ratio"/>
|
||||
<field name="ratio"/>
|
||||
<field name="price_index"/>
|
||||
<field name="price_matrix"/>
|
||||
<field name="currency"/>
|
||||
<field name="fixed_price"/>
|
||||
<field name="currency"/>
|
||||
<field name="auto"/>
|
||||
<field name="fallback"/>
|
||||
<field name="calendar"/>
|
||||
|
||||
Reference in New Issue
Block a user