This commit is contained in:
sinergia 2023-09-03 17:15:07 -05:00
commit 2c9bcc82ce
6 changed files with 39 additions and 2 deletions

View File

@ -1,5 +1,5 @@
from trytond.pool import Pool
from . import product, sale, production, invoice
from . import product, sale, production, invoice, user
__all__ = ['register']
@ -10,6 +10,7 @@ def register():
invoice.InvoiceLine,
sale.Sale,
sale.Line,
user.User,
production.Production,
module='sale_fast_food', type_='model')
Pool.register(

View File

@ -40,4 +40,8 @@ msgstr "Subtotal"
msgctxt "field:sale.sale,total_discount:"
msgid "Total Discount"
msgstr "Total Descuento"
msgstr "Total Descuento"
msgctxt "field:res.user,waiter:"
msgid "Waiter"
msgstr "Mesero"

View File

@ -2,6 +2,7 @@
version=6.4
depends:
ir
res
product
sale
sale_supply_production
@ -11,3 +12,4 @@ depends:
xml:
product.xml
sale.xml
user.xml

8
user.py Normal file
View File

@ -0,0 +1,8 @@
from trytond.model import fields
from trytond.pool import Pool, PoolMeta
class User(metaclass=PoolMeta):
"User"
__name__ = 'res.user'
waiter = fields.Boolean('Waiter')

13
user.xml Normal file
View File

@ -0,0 +1,13 @@
<?xml version="1.0"?>
<!-- This file is part of Tryton. The COPYRIGHT file at the top level of
this repository contains the full copyright notices and license terms. -->
<tryton>
<data>
<record model="ir.ui.view" id="user_view_form" >
<field name="name">user_form</field>
<field name="inherit" ref="res.user_view_form"/>
<field name="model">res.user</field>
</record>
</data>
</tryton>

9
view/user_form.xml Normal file
View File

@ -0,0 +1,9 @@
<?xml version="1.0"?>
<!-- This file is part of Tryton. The COPYRIGHT file at the top level of
this repository contains the full copyright notices and license terms. -->
<data>
<xpath expr="//field[@name='name']" position="after">
<label name="waiter"/>
<field name="waiter"/>
</xpath>
</data>