You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

100 lines
4.4 KiB

11 years ago
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <odoo>
  3. <record model="ir.ui.view" id="view_mass_object_form">
  4. <field name="name">mass.object.form</field>
  5. <field name="model">mass.object</field>
  6. <field name="arch" type="xml">
  7. <form string="Object">
  8. <header>
  9. <button name="create_action"
  10. type="object"
  11. string="Add Sidebar Button"
  12. class="btn-link oe_highlight"
  13. attrs="{'invisible':[('ref_ir_act_window_id','!=',False)]}"
  14. icon="fa-plus"
  15. help="Display a button in the sidebar of related documents to open a composition wizard"/>
  16. <button name="unlink_action"
  17. type="object"
  18. string="Remove Sidebar Button"
  19. class="btn-link oe_highlight" icon="fa-minus"
  20. attrs="{'invisible':[('ref_ir_act_window_id','=',False)]}"
  21. help="Remove the contextual action to use this template on related documents"
  22. widget="statinfo"/>
  23. <field name="ref_ir_act_window_id" invisible="1"/>
  24. </header>
  25. <sheet>
  26. <div class="oe_title">
  27. <label for="name" class="oe_edit_only"/>
  28. <h1>
  29. <field name="name" required="1"/>
  30. </h1>
  31. <group>
  32. <group>
  33. <field name="model_id" required="1" attrs="{'readonly':[('ref_ir_act_window_id','!=',False)]}"/>
  34. </group>
  35. <group>
  36. <field name="model_ids" invisible="1"/>
  37. </group>
  38. </group>
  39. </div>
  40. <div class="oe_right oe_button_box" name="buttons">
  41. </div>
  42. <notebook colspan="4">
  43. <page string="Fields">
  44. <field name="field_ids" colspan="4" nolabel="1"
  45. domain="[('ttype', 'not in', ['reference', 'function']), ('model_id', 'in', model_ids and model_ids[0][2] or [])]"/>
  46. </page>
  47. <page string="Advanced" attrs="{'invisible':[('ref_ir_act_window_id','=',False)]}">
  48. <group colspan="2" col="2">
  49. <field name="ref_ir_act_window_id"/>
  50. <field name="ref_ir_value_id"/>
  51. </group>
  52. </page>
  53. </notebook>
  54. </sheet>
  55. </form>
  56. </field>
  57. </record>
  58. <record model="ir.ui.view" id="view_mass_object_tree">
  59. <field name="name">mass.object.tree</field>
  60. <field name="model">mass.object</field>
  61. <field name="arch" type="xml">
  62. <tree string="Object">
  63. <field name="name"/>
  64. <field name="model_id"/>
  65. </tree>
  66. </field>
  67. </record>
  68. <record model="ir.actions.act_window" id="action_mass_object_form">
  69. <field name="name">Mass Editing</field>
  70. <field name="res_model">mass.object</field>
  71. <field name="view_type">form</field>
  72. <field name="view_mode">tree,form</field>
  73. <field name="view_id" ref="view_mass_object_tree"/>
  74. </record>
  75. <record id="action_mass_object_form_view1" model="ir.actions.act_window.view">
  76. <field eval="10" name="sequence"/>
  77. <field name="view_mode">tree</field>
  78. <field name="view_id" ref="view_mass_object_tree"/>
  79. <field name="act_window_id" ref="action_mass_object_form"/>
  80. </record>
  81. <record id="action_mass_object_form_view2" model="ir.actions.act_window.view">
  82. <field eval="20" name="sequence"/>
  83. <field name="view_mode">form</field>
  84. <field name="view_id" ref="view_mass_object_form"/>
  85. <field name="act_window_id" ref="action_mass_object_form"/>
  86. </record>
  87. <menuitem id="menu_mass_editing" name="Mass Editing"
  88. parent="base.menu_administration" sequence="6"/>
  89. <menuitem id="menu_mass_object_view" action="action_mass_object_form"
  90. parent="menu_mass_editing"/>
  91. </odoo>