base_copy_user_access.xml 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <openerp>
  3. <data>
  4. <record id="base_copy_user_access_view_form" model="ir.ui.view">
  5. <field name="name">Copy User Access</field>
  6. <field name="model">base.copy_user_access</field>
  7. <field name="arch" type="xml">
  8. <form string="Copy Access Right From User">
  9. <group col="4">
  10. <field name="user_id" required="True" />
  11. </group>
  12. <footer>
  13. <button name="copy_access_right" string="Copy" type="object" class="oe_highlight"/>
  14. Or
  15. <button special="cancel" string="_Cancel" class="oe_link"/>
  16. </footer>
  17. </form>
  18. </field>
  19. </record>
  20. <record id="base_copy_user_access_action" model="ir.actions.act_window">
  21. <field name="name">Copy User Access</field>
  22. <field name="type">ir.actions.act_window</field>
  23. <field name="res_model">base.copy_user_access</field>
  24. <field name="view_type">form</field>
  25. <field name="view_mode">form</field>
  26. <field name="view_id" ref="base_copy_user_access_view_form"/>
  27. <field name="target">new</field>
  28. <field name="multi">True</field>
  29. </record>
  30. <record id="base_copy_user_access_values" model="ir.values">
  31. <field name="model_id" ref="base.model_res_users" />
  32. <field name="name">Copy User Access</field>
  33. <field name="key2">client_action_multi</field>
  34. <field name="value" eval="'ir.actions.act_window,' + str(ref('base_copy_user_access_action'))" />
  35. <field name="key">action</field>
  36. <field name="model">res.users</field>
  37. </record>
  38. </data>
  39. </openerp>