main #7
@@ -213,6 +213,7 @@ def register():
|
|||||||
sale.SaleStrategy,
|
sale.SaleStrategy,
|
||||||
sale.OpenPosition,
|
sale.OpenPosition,
|
||||||
sale.Backtoback,
|
sale.Backtoback,
|
||||||
|
sale.AnalyticDimensionAssignment,
|
||||||
module='sale', type_='model')
|
module='sale', type_='model')
|
||||||
Pool.register(
|
Pool.register(
|
||||||
lot.LotShipping,
|
lot.LotShipping,
|
||||||
|
|||||||
@@ -254,6 +254,8 @@ class Purchase(metaclass=PoolMeta):
|
|||||||
broker = fields.Many2One('party.party',"Broker",domain=[('categories.parent', 'child_of', [4])])
|
broker = fields.Many2One('party.party',"Broker",domain=[('categories.parent', 'child_of', [4])])
|
||||||
tol_min = fields.Numeric("Tol - in %")
|
tol_min = fields.Numeric("Tol - in %")
|
||||||
tol_max = fields.Numeric("Tol + in %")
|
tol_max = fields.Numeric("Tol + in %")
|
||||||
|
tol_min_qt = fields.Numeric("Tol -")
|
||||||
|
tol_max_qt = fields.Numeric("Tol +")
|
||||||
certif = fields.Many2One('purchase.certification',"Certification")
|
certif = fields.Many2One('purchase.certification',"Certification")
|
||||||
wb = fields.Many2One('purchase.weight.basis',"Weight basis")
|
wb = fields.Many2One('purchase.weight.basis',"Weight basis")
|
||||||
association = fields.Many2One('purchase.association',"Association")
|
association = fields.Many2One('purchase.association',"Association")
|
||||||
@@ -275,6 +277,9 @@ class Purchase(metaclass=PoolMeta):
|
|||||||
'purchase',
|
'purchase',
|
||||||
'Analytic Dimensions'
|
'Analytic Dimensions'
|
||||||
)
|
)
|
||||||
|
trader = fields.Many2One('party.party',"Trader")
|
||||||
|
operator = fields.Many2One('party.party',"Operator")
|
||||||
|
our_reference = fields.Char("Our Reference")
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def default_viewer(cls):
|
def default_viewer(cls):
|
||||||
@@ -436,6 +441,12 @@ class Line(metaclass=PoolMeta):
|
|||||||
tol_max = fields.Numeric("Tol + in %",states={
|
tol_max = fields.Numeric("Tol + in %",states={
|
||||||
'readonly': (Eval('inherit_tol')),
|
'readonly': (Eval('inherit_tol')),
|
||||||
})
|
})
|
||||||
|
tol_min_qt = fields.Numeric("Tol -",states={
|
||||||
|
'readonly': (Eval('inherit_tol')),
|
||||||
|
})
|
||||||
|
tol_max_qt = fields.Numeric("Tol +",states={
|
||||||
|
'readonly': (Eval('inherit_tol')),
|
||||||
|
})
|
||||||
inherit_tol = fields.Boolean("Inherit tolerance")
|
inherit_tol = fields.Boolean("Inherit tolerance")
|
||||||
tol_min_v = fields.Function(fields.Numeric("Qt min"),'get_tol_min')
|
tol_min_v = fields.Function(fields.Numeric("Qt min"),'get_tol_min')
|
||||||
tol_max_v = fields.Function(fields.Numeric("Qt max"),'get_tol_max')
|
tol_max_v = fields.Function(fields.Numeric("Qt max"),'get_tol_max')
|
||||||
|
|||||||
@@ -32,6 +32,11 @@ class ContractDocumentType(metaclass=PoolMeta):
|
|||||||
# lc_in = fields.Many2One('lc.letter.incoming', 'LC in')
|
# lc_in = fields.Many2One('lc.letter.incoming', 'LC in')
|
||||||
sale = fields.Many2One('sale.sale', "Sale")
|
sale = fields.Many2One('sale.sale', "Sale")
|
||||||
|
|
||||||
|
class AnalyticDimensionAssignment(metaclass=PoolMeta):
|
||||||
|
'Analytic Dimension Assignment'
|
||||||
|
__name__ = 'analytic.dimension.assignment'
|
||||||
|
sale = fields.Many2One('sale.sale', "Sale")
|
||||||
|
|
||||||
class Estimated(metaclass=PoolMeta):
|
class Estimated(metaclass=PoolMeta):
|
||||||
"Estimated date"
|
"Estimated date"
|
||||||
__name__ = 'pricing.estimated'
|
__name__ = 'pricing.estimated'
|
||||||
@@ -221,6 +226,8 @@ class Sale(metaclass=PoolMeta):
|
|||||||
broker = fields.Many2One('party.party',"Broker",domain=[('categories.parent', 'child_of', [4])])
|
broker = fields.Many2One('party.party',"Broker",domain=[('categories.parent', 'child_of', [4])])
|
||||||
tol_min = fields.Numeric("Tol - in %")
|
tol_min = fields.Numeric("Tol - in %")
|
||||||
tol_max = fields.Numeric("Tol + in %")
|
tol_max = fields.Numeric("Tol + in %")
|
||||||
|
tol_min_qt = fields.Numeric("Tol -")
|
||||||
|
tol_max_qt = fields.Numeric("Tol +")
|
||||||
# certification = fields.Selection([
|
# certification = fields.Selection([
|
||||||
# (None, ''),
|
# (None, ''),
|
||||||
# ('bci', 'BCI'),
|
# ('bci', 'BCI'),
|
||||||
@@ -238,6 +245,14 @@ class Sale(metaclass=PoolMeta):
|
|||||||
doc_template = fields.Many2One('doc.template',"Template")
|
doc_template = fields.Many2One('doc.template',"Template")
|
||||||
required_documents = fields.Many2Many(
|
required_documents = fields.Many2Many(
|
||||||
'contract.document.type', 'sale', 'doc_type', 'Required Documents')
|
'contract.document.type', 'sale', 'doc_type', 'Required Documents')
|
||||||
|
analytic_dimensions = fields.One2Many(
|
||||||
|
'analytic.dimension.assignment',
|
||||||
|
'sale',
|
||||||
|
'Analytic Dimensions'
|
||||||
|
)
|
||||||
|
trader = fields.Many2One('party.party',"Trader")
|
||||||
|
operator = fields.Many2One('party.party',"Operator")
|
||||||
|
our_reference = fields.Char("Our Reference")
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def default_viewer(cls):
|
def default_viewer(cls):
|
||||||
@@ -382,6 +397,12 @@ class SaleLine(metaclass=PoolMeta):
|
|||||||
tol_max = fields.Numeric("Tol + in %",states={
|
tol_max = fields.Numeric("Tol + in %",states={
|
||||||
'readonly': (Eval('inherit_tol')),
|
'readonly': (Eval('inherit_tol')),
|
||||||
})
|
})
|
||||||
|
tol_min_qt = fields.Numeric("Tol -",states={
|
||||||
|
'readonly': (Eval('inherit_tol')),
|
||||||
|
})
|
||||||
|
tol_max_qt = fields.Numeric("Tol +",states={
|
||||||
|
'readonly': (Eval('inherit_tol')),
|
||||||
|
})
|
||||||
inherit_tol = fields.Boolean("Inherit tolerance")
|
inherit_tol = fields.Boolean("Inherit tolerance")
|
||||||
tol_min_v = fields.Function(fields.Numeric("Qt min"),'get_tol_min')
|
tol_min_v = fields.Function(fields.Numeric("Qt min"),'get_tol_min')
|
||||||
tol_max_v = fields.Function(fields.Numeric("Qt max"),'get_tol_max')
|
tol_max_v = fields.Function(fields.Numeric("Qt max"),'get_tol_max')
|
||||||
|
|||||||
@@ -50,6 +50,9 @@ this repository contains the full copyright notices and license terms. -->
|
|||||||
<newline/>
|
<newline/>
|
||||||
<field name="required_documents" colspan="4"/>
|
<field name="required_documents" colspan="4"/>
|
||||||
</page>
|
</page>
|
||||||
|
<page string="Dimensions" id="di">
|
||||||
|
<field name="analytic_dimensions" colspan="4"/>
|
||||||
|
</page>
|
||||||
</xpath>
|
</xpath>
|
||||||
<xpath expr="/form/notebook/page[@id='sale']/notebook/page[@id='line']/field[@name='payment_term']" position="after">
|
<xpath expr="/form/notebook/page[@id='sale']/notebook/page[@id='line']/field[@name='payment_term']" position="after">
|
||||||
<label name="from_location"/>
|
<label name="from_location"/>
|
||||||
|
|||||||
Reference in New Issue
Block a user