mirror of
https://gitlab.com/datalifeit/trytond-carrier_load_done2running
synced 2023-12-14 04:42:57 +01:00
parent
94dee53c2d
commit
32611f2318
3
load.py
3
load.py
|
@ -4,13 +4,12 @@ from trytond.pool import PoolMeta, Pool
|
||||||
from trytond.pyson import Eval, Or, Id
|
from trytond.pyson import Eval, Or, Id
|
||||||
from trytond.transaction import Transaction
|
from trytond.transaction import Transaction
|
||||||
|
|
||||||
__metaclass__ = PoolMeta
|
|
||||||
|
|
||||||
__all__ = ['LoadOrder']
|
__all__ = ['LoadOrder']
|
||||||
|
|
||||||
|
|
||||||
class LoadOrder:
|
class LoadOrder:
|
||||||
__name__ = 'carrier.load.order'
|
__name__ = 'carrier.load.order'
|
||||||
|
__metaclass__ = PoolMeta
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def __setup__(cls):
|
def __setup__(cls):
|
||||||
|
|
1
load.xml
1
load.xml
|
@ -14,7 +14,6 @@ this repository contains the full copyright notices and license terms. -->
|
||||||
|
|
||||||
<record model="ir.ui.view" id="load_order_view_form">
|
<record model="ir.ui.view" id="load_order_view_form">
|
||||||
<field name="model">carrier.load.order</field>
|
<field name="model">carrier.load.order</field>
|
||||||
<field name="type">form</field>
|
|
||||||
<field name="name">load_order_form</field>
|
<field name="name">load_order_form</field>
|
||||||
<field name="inherit" ref="carrier_load.load_order_view_form"/>
|
<field name="inherit" ref="carrier_load.load_order_view_form"/>
|
||||||
</record>
|
</record>
|
||||||
|
|
|
@ -25,10 +25,10 @@ Create database::
|
||||||
|
|
||||||
Install agro Module::
|
Install agro Module::
|
||||||
|
|
||||||
>>> Module = Model.get('ir.module.module')
|
>>> Module = Model.get('ir.module')
|
||||||
>>> module, = Module.find([('name', '=', 'carrier_load_done2running')])
|
>>> module, = Module.find([('name', '=', 'carrier_load_done2running')])
|
||||||
>>> module.click('install')
|
>>> module.click('install')
|
||||||
>>> Wizard('ir.module.module.install_upgrade').execute('upgrade')
|
>>> Wizard('ir.module.install_upgrade').execute('upgrade')
|
||||||
|
|
||||||
Create company::
|
Create company::
|
||||||
|
|
||||||
|
@ -193,7 +193,7 @@ Add other products to unit load::
|
||||||
>>> product = Product()
|
>>> product = Product()
|
||||||
>>> template = ProductTemplate()
|
>>> template = ProductTemplate()
|
||||||
>>> template.name = 'Plastic Case 30x30'
|
>>> template.name = 'Plastic Case 30x30'
|
||||||
>>> template.category = category
|
>>> template.categories.append(category)
|
||||||
>>> template.default_uom = unit
|
>>> template.default_uom = unit
|
||||||
>>> template.type = 'goods'
|
>>> template.type = 'goods'
|
||||||
>>> template.salable = True
|
>>> template.salable = True
|
||||||
|
@ -353,7 +353,7 @@ Check sale::
|
||||||
True
|
True
|
||||||
>>> order.sale.state
|
>>> order.sale.state
|
||||||
u'quotation'
|
u'quotation'
|
||||||
>>> order.sale.reference != None
|
>>> order.sale.number != None
|
||||||
True
|
True
|
||||||
>>> len(order.sale.lines)
|
>>> len(order.sale.lines)
|
||||||
1
|
1
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
[tryton]
|
[tryton]
|
||||||
version=3.6.1
|
version=4.0.3
|
||||||
depends:
|
depends:
|
||||||
carrier_load_ul
|
carrier_load_ul
|
||||||
ir
|
ir
|
||||||
|
|
Loading…
Reference in a new issue