helpdesk_ticket_views.xml 4.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <odoo>
  3. <!-- Extend helpdesk.ticket form view -->
  4. <record id="helpdesk_ticket_view_form_inherit_helpdesk_extras" model="ir.ui.view">
  5. <field name="name">helpdesk.ticket.form.inherit.helpdesk.extras</field>
  6. <field name="inherit_id" ref="helpdesk.helpdesk_ticket_view_form"/>
  7. <field name="model">helpdesk.ticket</field>
  8. <field name="priority">20</field>
  9. <field name="arch" type="xml">
  10. <!-- Add Extras page with all custom fields -->
  11. <xpath expr="//notebook" position="inside">
  12. <page string="Extras" name="extras">
  13. <group>
  14. <group string="Request Information">
  15. <field name="request_type_id" required="1"/>
  16. <field name="affected_module_id"/>
  17. <field name="affected_user_email" widget="email" placeholder="email@example.com"/>
  18. <field name="business_impact"/>
  19. </group>
  20. <group string="Details">
  21. <field name="reproduce_steps"
  22. invisible="request_type_code != 'incident'"
  23. placeholder="Describe step by step how to reproduce the issue..."/>
  24. <field name="business_goal"
  25. invisible="request_type_code != 'improvement'"
  26. placeholder="Describe the business objective for this improvement..."/>
  27. </group>
  28. </group>
  29. <group string="Approval &amp; Billing">
  30. <field name="client_authorization"/>
  31. <field name="estimated_hours"/>
  32. <field name="approval_status"/>
  33. </group>
  34. <group string="Attachments">
  35. <field name="attachment_ids"/>
  36. </group>
  37. <group string="Template Information" invisible="not has_template">
  38. <field name="team_id" invisible="1"/>
  39. <div class="alert alert-info" role="alert">
  40. <strong>Template Active:</strong> This ticket uses a template configured for the team.
  41. <br/>
  42. <small>Template fields are configured in Helpdesk > Configuration > Templates</small>
  43. <br/>
  44. <small>Template fields will be displayed in the web form when creating tickets.</small>
  45. </div>
  46. </group>
  47. </page>
  48. </xpath>
  49. </field>
  50. </record>
  51. <!-- Extend helpdesk.ticket tree view -->
  52. <record id="helpdesk_ticket_view_tree_inherit_helpdesk_extras" model="ir.ui.view">
  53. <field name="name">helpdesk.ticket.tree.inherit.helpdesk.extras</field>
  54. <field name="inherit_id" ref="helpdesk.helpdesk_tickets_view_tree"/>
  55. <field name="model">helpdesk.ticket</field>
  56. <field name="arch" type="xml">
  57. <xpath expr="//field[@name='name']" position="after">
  58. <field name="request_type_id" optional="show"/>
  59. <field name="affected_module_id" optional="show"/>
  60. <field name="approval_status" optional="show"/>
  61. </xpath>
  62. </field>
  63. </record>
  64. <!-- Extend helpdesk.ticket search view -->
  65. <record id="helpdesk_ticket_view_search_inherit_helpdesk_extras" model="ir.ui.view">
  66. <field name="name">helpdesk.ticket.search.inherit.helpdesk.extras</field>
  67. <field name="inherit_id" ref="helpdesk.helpdesk_tickets_view_search_base"/>
  68. <field name="model">helpdesk.ticket</field>
  69. <field name="arch" type="xml">
  70. <xpath expr="//field[@name='partner_id']" position="after">
  71. <field name="affected_module_id" string="Affected Module"/>
  72. </xpath>
  73. </field>
  74. </record>
  75. </odoo>