19.0 vanilla

This commit is contained in:
Ernad Husremovic 2026-03-09 09:29:53 +01:00
parent 6e54c1af6c
commit 3ca647e428
1087 changed files with 132065 additions and 108499 deletions

View file

@ -0,0 +1,19 @@
<?xml version="1.0"?>
<odoo>
<record id="view_pos_preset_form_inherit_pos_restaurant" model="ir.ui.view">
<field name="name">pos.preset.form</field>
<field name="model">pos.preset</field>
<field name="inherit_id" ref="point_of_sale.view_pos_preset_form"></field>
<field name="arch" type="xml">
<xpath expr="//page[@name='resource']" position="after">
<page string="Options" name="options">
<group>
<group name="restaurant" string="Restaurant">
<field name="use_guest" />
</group>
</group>
</page>
</xpath>
</field>
</record>
</odoo>

View file

@ -8,19 +8,24 @@
<field name="arch" type="xml">
<form string="Restaurant Floor">
<sheet>
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" attrs="{'invisible': [('active', '=', True)]}"/>
<widget name="web_ribbon" title="Archived" bg_color="text-bg-danger" invisible="active"/>
<field name="active" invisible="1"/>
<field name="floor_background_image" widget='image' class="oe_avatar" options='{"preview_image": "floor_background_image"}'/>
<group col="4">
<field name="name" />
<field name="pos_config_id" />
<field name="pos_config_ids" widget="many2many_tags"/>
<field name="background_color" groups="base.group_no_one" />
</group>
<field name="table_ids">
<tree string='Tables'>
<field name="name" />
<list string='Tables' editable="bottom">
<field name="table_number" />
<field name="seats" />
<field name="shape" />
</tree>
<field name="height" optional="hide" />
<field name="width" optional="hide" />
<field name="color" widget="color" optional="hide" />
<field name="active" optional="hide" />
</list>
</field>
</sheet>
</form>
@ -31,11 +36,11 @@
<field name="name">Restaurant Floors</field>
<field name="model">restaurant.floor</field>
<field name="arch" type="xml">
<tree string="Restaurant Floors">
<list string="Restaurant Floors">
<field name="sequence" widget="handle" />
<field name="name" />
<field name="pos_config_id" />
</tree>
<field name="pos_config_ids" widget="many2many_tags"/>
</list>
</field>
</record>
@ -55,13 +60,11 @@
<field name="model">restaurant.floor</field>
<field name="arch" type="xml">
<kanban class="o_kanban_mobile">
<field name="name"/>
<field name="pos_config_id" />
<templates>
<t t-name="kanban-box">
<div t-attf-class="oe_kanban_global_click">
<div><strong>Floor Name: </strong><t t-esc="record.name.value"/></div>
<div><strong>Point of Sale: </strong><t t-esc="record.pos_config_id.value"/></div>
<t t-name="card">
<div><strong>Floor Name: </strong><field name="name"/></div>
<div class="d-flex">
<strong>Point of Sales:</strong><field name="pos_config_ids" class="ms-1"/>
</div>
</t>
</templates>
@ -71,9 +74,8 @@
<record id="action_restaurant_floor_form" model="ir.actions.act_window">
<field name="name">Floor Plans</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">restaurant.floor</field>
<field name="view_mode">tree,kanban,form</field>
<field name="view_mode">list,kanban,form</field>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Add a new restaurant floor
@ -89,18 +91,20 @@
<field name="model">restaurant.table</field>
<field name="arch" type="xml">
<form string="Restaurant Table">
<group col="2">
<field name="name" />
<field name="seats" />
</group>
<group col="4" string="Appearance" groups="base.group_no_one">
<field name="shape" />
<field name="color" />
<field name="position_h" />
<field name="position_v" />
<field name="width" />
<field name="height" />
</group>
<sheet>
<group col="2">
<field name="table_number" />
<field name="seats" />
</group>
<group col="4" string="Appearance" groups="base.group_no_one">
<field name="shape" />
<field name="color" />
<field name="position_h" />
<field name="position_v" />
<field name="width" />
<field name="height" />
</group>
</sheet>
</form>
</field>
</record>
@ -109,63 +113,5 @@
parent="point_of_sale.menu_point_config_product"
action="action_restaurant_floor_form"
sequence="10"
groups="base.group_no_one"/>
<!-- RESTAURANT PRINTERS -->
<record id="view_restaurant_printer_form" model="ir.ui.view">
<field name="name">Order Printer</field>
<field name="model">restaurant.printer</field>
<field name="arch" type="xml">
<form string="POS Printer">
<sheet>
<group>
<field name="name" />
<field name="printer_type" widget="radio"/>
<field name="proxy_ip" attrs="{'invisible': [('printer_type', '!=', 'iot')]}"/>
<field name="product_categories_ids" />
</group>
</sheet>
</form>
</field>
</record>
<record id="action_restaurant_printer_form" model="ir.actions.act_window">
<field name="name">Order Printers</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">restaurant.printer</field>
<field name="view_mode">tree,kanban,form</field>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Add a new restaurant order printer
</p><p>
Order Printers are used by restaurants and bars to print the
order updates in the kitchen/bar when the waiter updates the order.
</p><p>
Each Order Printer has an IP Address that defines the IoT Box/Hardware
Proxy where the printer can be found, and a list of product categories.
An Order Printer will only print updates for products belonging to one of
its categories.
</p>
</field>
</record>
<record id="view_restaurant_printer" model="ir.ui.view">
<field name="name">Order Printers</field>
<field name="model">restaurant.printer</field>
<field name="arch" type="xml">
<tree string="Restaurant Order Printers">
<field name="name" />
<field name="proxy_ip" />
<field name="product_categories_ids" widget="many2many_tags"/>
</tree>
</field>
</record>
<menuitem id="menu_restaurant_printer_all"
parent="point_of_sale.menu_point_config_product"
action="action_restaurant_printer_form"
sequence="15"
groups="base.group_no_one"/>
groups="point_of_sale.group_pos_user"/>
</odoo>

View file

@ -6,100 +6,36 @@
<field name="inherit_id" ref="point_of_sale.res_config_settings_view_form"/>
<field name="arch" type="xml">
<div id="warning_text_pos_restaurant" position="replace"/>
<div id="pos_interface_section" position="after">
<h2 class="mt16" attrs="{'invisible': [('pos_module_pos_restaurant', '=', False)]}">Restaurant &amp; Bar</h2>
<div class="row mt16 o_settings_container" id="restaurant_section" attrs="{'invisible': [('pos_module_pos_restaurant', '=', False)]}">
<div class="col-12 col-lg-6 o_setting_box"
id="is_table_management"
attrs="{'invisible': [('pos_module_pos_restaurant', '=', False)]}">
<div class="o_setting_left_pane">
<field name="pos_is_table_management" attrs="{'readonly': [('pos_has_active_session','=', True)]}"/>
<block id="restaurant_section" position="inside">
<setting id="floor_and_table_map" string="Floors &amp; Tables Map" help="Design floors and assign orders to tables" documentation="/applications/sales/point_of_sale/restaurant/floors_tables.html" invisible="is_kiosk_mode or not pos_module_pos_restaurant">
<div class="content-group">
<div class="mt16">
<label string="Floors" for="pos_floor_ids" class="o_light_label me-2"/>
<field name="pos_floor_ids" widget="many2many_tags" readonly="pos_has_active_session" />
</div>
<div class="o_setting_right_pane">
<label for="pos_is_table_management" string="Floors &amp; Tables Map"/>
<div class="text-muted">
Design floors and assign orders to tables
</div>
<div class="content-group" attrs="{'invisible': [('pos_is_table_management','=',False)]}">
<div class="mt16">
<label string="Floors" for="pos_floor_ids" class="o_light_label"/>
<field name="pos_floor_ids" widget="many2many_tags" attrs="{'readonly': [('pos_has_active_session','=', True)]}" />
</div>
<div>
<button name="%(pos_restaurant.action_restaurant_floor_form)d" icon="fa-arrow-right" type="action" string="Floors" class="btn-link"/>
</div>
</div>
<div>
<button name="%(pos_restaurant.action_restaurant_floor_form)d" icon="oi-arrow-right" type="action" string="Floors" class="btn-link"/>
</div>
</div>
<div class="col-12 col-lg-6 o_setting_box"
id="iface_orderline_notes"
attrs="{'invisible': [('pos_module_pos_restaurant', '=', False)]}">
<div class="o_setting_left_pane">
<field name="pos_iface_orderline_notes"/>
</div>
<div class="o_setting_right_pane">
<label for="pos_iface_orderline_notes" string="Kitchen Notes"/>
<div class="text-muted">
Add internal notes on order lines for the kitchen
</div>
</div>
</div>
<div class="col-12 col-lg-6 o_setting_box"
id="iface_printbill"
attrs="{'invisible': [('pos_module_pos_restaurant', '=', False)]}">
<div class="o_setting_left_pane">
<field name="pos_iface_printbill"/>
</div>
<div class="o_setting_right_pane">
<label for="pos_iface_printbill" string="Early Receipt Printing" />
<div class="text-muted">
Allow to print receipt before payment
</div>
</div>
</div>
<div class="col-12 col-lg-6 o_setting_box"
id="iface_splitbill"
attrs="{'invisible': [('pos_module_pos_restaurant', '=', False)]}">
<div class="o_setting_left_pane">
<field name="pos_iface_splitbill" string="Allow Bill Splitting"/>
</div>
<div class="o_setting_right_pane">
<label for="pos_iface_splitbill" string="Allow Bill Splitting"/>
<div class="text-muted">
Split total or order lines
</div>
</div>
</div>
<div class="col-12 col-lg-6 o_setting_box"
id="is_order_printer"
attrs="{'invisible': [('pos_module_pos_restaurant', '=', False)]}">
<div class="o_setting_left_pane">
<field name="pos_is_order_printer"/>
</div>
<div class="o_setting_right_pane">
<label for="pos_is_order_printer" string="Kitchen Printers"/>
<div class="text-muted">
Print orders at the kitchen, at the bar, etc.
</div>
<div class="content-group" attrs="{'invisible': [('pos_is_order_printer', '=', False)]}">
<div class="mt16">
<label string="Printers" for="pos_printer_ids" class="o_light_label"/>
<field name="pos_printer_ids" widget="many2many_tags"/>
</div>
<div>
<button name="%(pos_restaurant.action_restaurant_printer_form)d" icon="fa-arrow-right" type="action" string="Printers" class="btn-link"/>
</div>
</div>
</div>
</div>
</div>
</div>
</setting>
<setting string="Early Receipt Printing" help="Allow to print receipt before payment" id="iface_printbill" invisible="not pos_module_pos_restaurant or is_kiosk_mode">
<field name="pos_iface_printbill"/>
</setting>
<setting help="Split total or order lines" id="iface_splitbill" documentation="/applications/sales/point_of_sale/restaurant/bill_printing.html" invisible="not pos_module_pos_restaurant or is_kiosk_mode">
<field name="pos_iface_splitbill" string="Allow Bill Splitting"/>
</setting>
</block>
<div id="tip_product" position="after">
<div attrs="{'invisible': ['|', ('pos_module_pos_restaurant', '=', False), ('pos_iface_tipproduct', '=', False)]}">
<div invisible="not pos_module_pos_restaurant or not pos_iface_tipproduct or country_code == 'BE'">
<field name="pos_set_tip_after_payment" class="oe_inline"/>
<label class="fw-normal" for="pos_set_tip_after_payment" string="Add tip after payment (North America specific)"/>
<label class="fw-normal" for="pos_set_tip_after_payment" string="Add tip after payment"/>
</div>
</div>
<block id="pos_interface_section" position="inside">
<setting invisible="not pos_module_pos_restaurant or is_kiosk_mode" help="Select the table first or after registering the order">
<field name="pos_default_screen" widget="radio"/>
</setting>
</block>
</field>
</record>
</odoo>