<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
    <record id="sos_materials_expenditure_view_tree" model="ir.ui.view">
    <field name="name">sos_materials_expenditure.view.tree</field>
    <field name="model">sos_materials_expenditure</field>
    <field name="arch" type="xml">
    <tree>
    <field name="plan_id"/>
    <field name="write_uid" string="Last Edited By" optional="hide"/>
    <field name="write_date" string="Last Edited On" optional="hide"/>
    </tree>
    </field>
    </record>


 <record id="action_materials_expenditure" model="ir.actions.act_window">
    <field name="name">Materials Expenditure</field>
    <field name="type">ir.actions.act_window</field>
    <field name="res_model">sos_materials_expenditure</field>
    <field name="view_mode">tree,form</field>
    <field name="view_id" ref="sos_materials_expenditure_view_tree"/>
</record>
<record id="sos_materials_expenditure_form_view" model="ir.ui.view">
    <field name="name">Form</field>
    <field name="model">sos_materials_expenditure</field>
    <field name="arch" type="xml">
        <form>

            <sheet>
        <h2 style="text-align: center;text-transform: uppercase;text-shadow: 1px 1p 1px #140718;color: #65407c;padding:5px;">Materials Expenditure</h2><hr></hr><br></br>  
        <group>
        <group>
        <field name="plan_id"/>
        <field name="mon_ref_no"/>
        <field name="mrn_ref_no"/>
        </group>

        </group>
                <notebook>
                <page string="Materials">
                <field name="line_ids_material">
                <tree editable="bottom">
                <field name="component_id"/>
                <field name="material_code"/>
                <field name="quantity"/>
                <field name="approx_price"/>
                <field name="total_cost"/>
                </tree>
                </field>
                </page>
                <page string="Summary">
                <group>
                <field name="overall_total" style="font-size:22px;font-weight:bold"/>
                </group>
                </page>
               
                </notebook>
                 <br></br> 
            </sheet>
        </form>
    </field>
</record>


              <menuitem id="materials_expenditure_menu"
              name="Materials Expenditure"
              parent="travel_root_menu"
              action="action_materials_expenditure" groups="sos_inventory.sos_ce_user,sos_inventory.sos_ce_head,sos_inventory.sos_finance_user,sos_inventory.sos_management_user"/>
              
</odoo>
