pos_table_views.xml 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!-- Copyright 2017 OpenSynergy Indonesia
  3. License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
  4. <openerp>
  5. <data>
  6. <record id="pos_table_view_tree" model="ir.ui.view">
  7. <field name="name">Tree Pos Table</field>
  8. <field name="model">pos.table</field>
  9. <field name="arch" type="xml">
  10. <tree>
  11. <field name="name" string="Nombre"/>
  12. <field name="type" string="Tipo"/>
  13. <field name="floor_id" string="Grupo"/>
  14. <field name="capacity" string="Número de asientos" attrs="{'invisible': [('type', '!=', 'table')]}"/>
  15. </tree>
  16. </field>
  17. </record>
  18. <record id="pos_table_view_form" model="ir.ui.view">
  19. <field name="name">Form Pos Table</field>
  20. <field name="model">pos.table</field>
  21. <field name="arch" type="xml">
  22. <form string="Restaurant Table">
  23. <!-- <header>
  24. <field name="state" widget="statusbar"/>
  25. </header> -->
  26. <group name="grp_pos_table">
  27. <field name="floor_id" string="Agrupar por"/>
  28. <field name="type" string="Tipo" widget="radio" readonly="1"/>
  29. <field name="name" string="Nro de Mesa" attrs="{'invisible': [('type', '!=', 'table')], 'required':[('type','=','table')]}"/>
  30. <field name="employee_id" string="Chofer" attrs="{'invisible': [('type', '!=', 'delivery')], 'required':[('type','=','delivery')]}"/>
  31. <field name="capacity" string="Número de asientos" attrs="{'invisible': [('type', '!=', 'table')]}"/>
  32. </group>
  33. </form>
  34. </field>
  35. </record>
  36. <record id="pos_table_action" model="ir.actions.act_window">
  37. <field name="name">Mesas o Delivery</field>
  38. <field name="type">ir.actions.act_window</field>
  39. <field name="res_model">pos.table</field>
  40. <field name="view_type">form</field>
  41. <field name="view_mode">tree,form</field>
  42. </record>
  43. <menuitem
  44. id="pos_table_menu"
  45. name="Mesas o Delivery"
  46. parent="point_of_sale.menu_point_config_product"
  47. groups="point_of_sale.group_pos_manager"
  48. action="pos_table_action"
  49. />
  50. </data>
  51. </openerp>