Add app name
This commit is contained in:
parent
bc99522048
commit
e831f50010
9
dash.py
9
dash.py
|
@ -13,3 +13,12 @@ class DashApp(metaclass=PoolMeta):
|
|||
origins = super(DashApp, cls)._get_origin()
|
||||
origins.extend(['dash.app.delivery', 'dash.app.sale_order'])
|
||||
return origins
|
||||
|
||||
@classmethod
|
||||
def get_selection(cls):
|
||||
options = super(DashApp, cls).get_selection()
|
||||
options.extend([
|
||||
('delivery', 'Delivery'),
|
||||
('sale_order', 'Sale Order'),
|
||||
])
|
||||
return options
|
||||
|
|
1
sale.py
1
sale.py
|
@ -237,6 +237,7 @@ class AppDelivery(ModelSQL, ModelView):
|
|||
'App Delivery'
|
||||
__name__ = 'dash.app.delivery'
|
||||
company = fields.Many2One('company.company', 'Company', required=True)
|
||||
code = fields.Char('Code')
|
||||
|
||||
@classmethod
|
||||
def __setup__(cls):
|
||||
|
|
|
@ -4,4 +4,6 @@ The COPYRIGHT file at the top level of this repository contains the full copyrig
|
|||
<form>
|
||||
<label name="company"/>
|
||||
<field name="company" widget="selection"/>
|
||||
<label name="code"/>
|
||||
<field name="code"/>
|
||||
</form>
|
||||
|
|
|
@ -2,5 +2,6 @@
|
|||
<!-- This file is part sale_shop module for Tryton.
|
||||
The COPYRIGHT file at the top level of this repository contains the full copyright notices and license terms. -->
|
||||
<tree >
|
||||
<field name="code"/>
|
||||
<field name="company"/>
|
||||
</tree>
|
||||
|
|
Loading…
Reference in New Issue