Skip to Content
Menu
This question has been flagged
5794 Views

when I add it inside record it is not visible! where should I put it plz?

<record id="view_pointage_tree_byUser" model="ir.ui.view">
            <field name="name">hr.check.pointage.tree.byUser</field>
            <field name="model">arr.button</field>

            <field name="arch" type="xml">

                <button name="open_something" string="Confirmer le pointage" type="object" />
                <tree string="Employee x pointages">
                    <field name="employee_id"/>
                    <field name="check_in"/>
                    <field name="check_out"/>
                    <field name="worked_hours"/>
                </tree>
            </field>
        </record>
  
          <record id="action_pointage_byUser" model="ir.actions.act_window">
            <field name="name">Pointages byuder</field>
            <field name="res_model">arr.button</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
           
        </record>


---------------------

class DataButton(models.Model):
    _name = 'arr.button'
    @api.multi
    def open_something(self):
        DATETIME_FORMAT = "%Y-%m-%d %H:%M:%S"
        in_before=8
        out_before=15

         ...


Avatar
Discard