<?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.action.report" id="report_hotel_service">
            <field name="name">Service</field>
            <field name="model">hotel.service</field>
            <field name="report_name">hotel.service</field>
            <field name="report">hotel/service.fods</field>
        </record>
        <record model="ir.action.keyword" id="report_service_keyword">
            <field name="keyword">form_print</field>
            <field name="model">hotel.service,-1</field>
            <field name="action" ref="report_hotel_service"/>
        </record>

        <record model="ir.ui.view" id="service_view_tree">
            <field name="model">hotel.service</field>
            <field name="type">tree</field>
            <field name="name">service_tree</field>
        </record>
        <record model="ir.ui.view" id="service_view_form">
            <field name="model">hotel.service</field>
            <field name="type">form</field>
            <field name="name">service_form</field>
        </record>
        <record model="ir.action.act_window" id="act_service_tree">
            <field name="name">Service</field>
            <field name="res_model">hotel.service</field>
        </record>
        <record model="ir.action.act_window.view" id="act_service_view_tree1">
            <field name="sequence" eval="10"/>
            <field name="view" ref="service_view_tree"/>
            <field name="act_window" ref="act_service_tree"/>
        </record>
        <record model="ir.action.act_window.view" id="act_service_view_tree2">
            <field name="sequence" eval="20"/>
            <field name="view" ref="service_view_form"/>
            <field name="act_window" ref="act_service_tree"/>
        </record>
        <menuitem name="Service" parent="hotel.menu_hotel" sequence="40"
            id="menu_hotel_service" action="act_service_tree"/>

        <record model="ir.model.button" id="service_cancel_button">
            <field name="name">finish</field>
            <field name="model" search="[('model', '=', 'hotel.service')]"/>
        </record>
        <record model="ir.model.button-res.group" id="service_cancel_button_group_hotel">
            <field name="button" ref="service_cancel_button"/>
            <field name="group" ref="hotel.group_hotel"/>
        </record>

        <record model="ir.model.button" id="service_draft_button">
            <field name="name">draft</field>
            <field name="model" search="[('model', '=', 'hotel.service')]"/>
        </record>
        <record model="ir.model.button-res.group" id="service_draft_button_group_hotel">
            <field name="button" ref="service_draft_button"/>
            <field name="group" ref="hotel.group_hotel"/>
        </record>

        <record model="ir.model.button" id="service_confirm_button">
            <field name="name">confirm</field>
            <field name="model" search="[('model', '=', 'hotel.service')]"/>
        </record>
        <record model="ir.model.button-res.group" id="service_confirm_button_group_hotel">
            <field name="button" ref="service_confirm_button"/>
            <field name="group" ref="hotel.group_hotel"/>
        </record>

        <!-- Model Access -->
        <record model="ir.model.access" id="access_service">
            <field name="model" search="[('model', '=', 'hotel.service')]"/>
            <field name="perm_read" eval="True"/>
            <field name="perm_write" eval="True"/>
            <field name="perm_create" eval="True"/>
            <field name="perm_delete" eval="True"/>
        </record>
        <record model="ir.model.access" id="access_service_group_hotel">
            <field name="model" search="[('model', '=', 'hotel.service')]"/>
            <field name="group" ref="group_hotel"/>
            <field name="perm_read" eval="True"/>
            <field name="perm_write" eval="True"/>
            <field name="perm_create" eval="True"/>
            <field name="perm_delete" eval="False"/>
        </record>
        <record model="ir.model.access" id="access_service_group_hotel_frontdesk">
            <field name="model" search="[('model', '=', 'hotel.service')]"/>
            <field name="group" ref="group_hotel_frontdesk"/>
            <field name="perm_read" eval="True"/>
            <field name="perm_write" eval="True"/>
            <field name="perm_create" eval="True"/>
            <field name="perm_delete" eval="False"/>
        </record>
        <record model="ir.model.access" id="access_service_group_hotel_admin">
            <field name="model" search="[('model', '=', 'hotel.service')]"/>
            <field name="group" ref="group_hotel_admin"/>
            <field name="perm_read" eval="True"/>
            <field name="perm_write" eval="True"/>
            <field name="perm_create" eval="True"/>
            <field name="perm_delete" eval="True"/>
        </record>

        <record model="ir.ui.view" id="service_line_view_tree">
            <field name="model">hotel.service.line</field>
            <field name="type">tree</field>
            <field name="name">service_line_tree</field>
        </record>
        <record model="ir.ui.view" id="service_line_view_form">
            <field name="model">hotel.service.line</field>
            <field name="type">form</field>
            <field name="name">service_line_form</field>
        </record>
        <record model="ir.action.act_window" id="act_service_line_tree">
            <field name="name">Service Line</field>
            <field name="res_model">hotel.service.line</field>
        </record>

        <record model="ir.ui.view" id="service_kind_view_tree">
            <field name="model">hotel.service.kind</field>
            <field name="type">tree</field>
            <field name="name">service_kind_tree</field>
        </record>
        <record model="ir.ui.view" id="service_kind_view_form">
            <field name="model">hotel.service.kind</field>
            <field name="type">form</field>
            <field name="name">service_kind_form</field>
        </record>
        <record model="ir.action.act_window" id="act_service_kind_tree">
            <field name="name">Service Kind</field>
            <field name="res_model">hotel.service.kind</field>
        </record>
        <record model="ir.action.act_window.view" id="act_service_kind_view_tree1">
            <field name="sequence" eval="10"/>
            <field name="view" ref="service_kind_view_tree"/>
            <field name="act_window" ref="act_service_kind_tree"/>
        </record>
        <record model="ir.action.act_window.view" id="act_service_kind_view_tree2">
            <field name="sequence" eval="20"/>
            <field name="view" ref="service_kind_view_form"/>
            <field name="act_window" ref="act_service_kind_tree"/>
        </record>
        <menuitem parent="hotel.menu_configuration" id="menu_hotel_service_kind"
            sequence="60" action="act_service_kind_tree"/>

        <record model="ir.ui.view" id="create_daily_services_start_view_form">
            <field name="model">hotel.daily_services.start</field>
            <field name="type">form</field>
            <field name="name">create_daily_services_form</field>
        </record>
        <record model="ir.action.wizard" id="wizard_hotel_create_daily_services">
            <field name="name">Create Daily Services</field>
            <field name="wiz_name">hotel.daily_services</field>
        </record>
        <menuitem parent="menu_hotel_service" id="menu_create_payroll_group"
            sequence="10" action="wizard_hotel_create_daily_services"/>

        <record model="ir.action.act_window.domain" id="act_service_form_domain_today">
            <field name="name">Today</field>
            <field name="sequence" eval="10"/>
            <field name="domain" eval="[
                ('service_date', '=', Date())
              ]" pyson="1"/>
            <field name="count" eval="True"/>
            <field name="act_window" ref="act_service_tree"/>
        </record>
        <record model="ir.action.act_window.domain" id="act_service_form_domain_draft">
            <field name="name">Draft</field>
            <field name="sequence" eval="20"/>
            <field name="domain" eval="[('state', '=', 'draft')]" pyson="1"/>
            <field name="count" eval="True"/>
            <field name="act_window" ref="act_service_tree"/>
        </record>
        <record model="ir.action.act_window.domain" id="act_service_form_domain_open">
            <field name="name">Open</field>
            <field name="sequence" eval="30"/>
            <field name="domain" eval="[('state', '=', 'open')]" pyson="1"/>
            <field name="count" eval="True"/>
            <field name="act_window" ref="act_service_tree"/>
        </record>
        <record model="ir.action.act_window.domain" id="act_service_form_domain_confirmed">
            <field name="name">Confirmed</field>
            <field name="sequence" eval="40"/>
            <field name="domain" eval="[
                ('state', '=', 'confirmed')
              ]" pyson="1"/>
            <field name="count" eval="True"/>
            <field name="act_window" ref="act_service_tree"/>
        </record>
        <record model="ir.action.act_window.domain" id="act_service_form_domain_all">
            <field name="name">All</field>
            <field name="sequence" eval="90"/>
            <field name="domain" eval="[]" pyson="1"/>
            <field name="act_window" ref="act_service_tree"/>
        </record>


    </data>
</tryton>
