summaryrefslogtreecommitdiff
path: root/indoteknik_custom/views
diff options
context:
space:
mode:
authorHafidBuroiroh <hafidburoiroh09@gmail.com>2026-02-24 08:47:38 +0700
committerHafidBuroiroh <hafidburoiroh09@gmail.com>2026-02-24 08:47:38 +0700
commit7bfc92fdb73a89c5bc0b4c711315cbd5ea3ff268 (patch)
treee68a7ae7d08f85cf9b5ce6b708d9d5b551656e52 /indoteknik_custom/views
parentb468da04ba901590b764694bfdd47366bc649dab (diff)
<hafid> sourcing job dari sale order ga include crm
Diffstat (limited to 'indoteknik_custom/views')
-rwxr-xr-xindoteknik_custom/views/sale_order.xml6
-rw-r--r--indoteknik_custom/views/sourcing.xml617
2 files changed, 623 insertions, 0 deletions
diff --git a/indoteknik_custom/views/sale_order.xml b/indoteknik_custom/views/sale_order.xml
index c3df92ec..ac871ead 100755
--- a/indoteknik_custom/views/sale_order.xml
+++ b/indoteknik_custom/views/sale_order.xml
@@ -46,6 +46,12 @@
type="object"
string="Refund"
class="btn-primary" />
+
+ <button name="action_open_sjo"
+ type="object"
+ string="Request Sourcing"
+ class="btn-primary"
+ attrs="{'invisible': [('state', '!=', 'draft')]}"/>
</xpath>
<xpath expr="//sheet" position="before">
<field name="partner_is_cbd_locked" invisible="1"/>
diff --git a/indoteknik_custom/views/sourcing.xml b/indoteknik_custom/views/sourcing.xml
new file mode 100644
index 00000000..f3bb5b33
--- /dev/null
+++ b/indoteknik_custom/views/sourcing.xml
@@ -0,0 +1,617 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<odoo>
+ <!-- Sales View -->
+ <record id="view_sourcing_job_order_search" model="ir.ui.view">
+ <field name="name">sourcing.job.order.search</field>
+ <field name="model">sourcing.job.order</field>
+ <field name="arch" type="xml">
+ <search string="Search Sourcing Job Order">
+ <field name="state" string="Status"/>
+ <filter name="done"
+ string="Complete"
+ domain="[('state', '=', 'done')]" />
+ <filter name="by_create_uid"
+ string="My Activity"
+ domain="[('create_uid', '=', uid)]"/>
+ </search>
+ </field>
+ </record>
+
+ <record id="view_wizard_export_sjo_to_so_form" model="ir.ui.view">
+ <field name="name">wizard.export.sjo.to.so.form</field>
+ <field name="model">wizard.export.sjo.to.so</field>
+ <field name="arch" type="xml">
+ <form string="Export Products to SO">
+ <group>
+ <field name="sjo_id" readonly="1"/>
+ <field name="line_ids" widget="many2many_tags" invisible="1"/>
+ <field name="product_ids" widget="many2many_tags" options="{'no_create': True}"/>
+ </group>
+
+ <footer>
+ <button name="action_confirm"
+ string="Export to SO"
+ type="object"
+ class="btn-primary"/>
+
+ <button string="Cancel"
+ class="btn-secondary"
+ special="cancel"/>
+ </footer>
+ </form>
+ </field>
+ </record>
+
+ <record id="view_reopen_cancel_line_wizard" model="ir.ui.view">
+ <field name="name">reopen.cancel.line.wizard.form</field>
+ <field name="model">reopen.cancel.line.wizard</field>
+ <field name="arch" type="xml">
+ <form string="Reason Reopen">
+ <group>
+ <field name="reason" placeholder="Alasan kenapa mau direopen..."/>
+ </group>
+ <footer>
+ <button name="action_confirm"
+ type="object"
+ string="Confirm Reopen"
+ class="btn-primary"/>
+ <button string="Cancel" special="cancel"/>
+ </footer>
+ </form>
+ </field>
+ </record>
+
+ <record id="view_sourcing_job_order_tree" model="ir.ui.view">
+ <field name="name">sourcing.job.order.tree</field>
+ <field name="model">sourcing.job.order</field>
+ <field name="arch" type="xml">
+ <tree string="Sourcing Job Orders"
+ decoration-success="state=='done'"
+ decoration-danger="state=='cancel'"
+ decoration-warning="state=='taken'">
+ <field name="is_priority" optional="hide" readonly="1"/>
+ <field name="name"/>
+ <field name="eta_sales" optional="hide"/>
+ <field name="eta_complete" optional="hide"/>
+ <!-- <field name="leads_id"/> -->
+ <field name="create_uid" widget="many2one_avatar_user"/>
+ <field name="md_user_id" widget="many2many_tags"/>
+ <field name="state" widget="badge"/>
+ <field name="create_date"/>
+ <field name="progress_status"
+ decoration-info="progress_status in ['🟡 On Track', '🔵 Ontime']"
+ decoration-success="'🟢' in progress_status"
+ decoration-danger="'🔴' in progress_status"
+ decoration-muted="'âš«' in progress_status"/>
+ </tree>
+ </field>
+ </record>
+
+ <record id="view_sourcing_job_order_form" model="ir.ui.view">
+ <field name="name">sourcing.job.order.form</field>
+ <field name="model">sourcing.job.order</field>
+ <field name="arch" type="xml">
+ <form string="Sourcing Job Order">
+ <header>
+ <button name="action_cancel"
+ string="Cancel"
+ type="object"
+ class="btn-secondary"
+ icon="fa-times"
+ groups="indoteknik_custom.group_role_merchandiser"
+ attrs="{'invisible': [('state', 'in', ['cancel', 'done'])]}"/>
+
+ <button name="action_open_export_wizard"
+ type="object"
+ string="Input to SO"
+ class="btn-primary"
+ attrs="{'invisible':['|', ('state','not in',('done','partial')), ('so_id', '=', False)]}"/>
+
+ <field name="state" widget="statusbar"
+ statusbar_visible="draft,taken,partial,done,cancel" attrs="{'invisible': [('state', '!=', 'cancel')]}"/>
+
+ <field name="state" widget="statusbar"
+ statusbar_visible="draft,taken,partial,done" attrs="{'invisible': [('state', '=', 'cancel')]}"/>
+ </header>
+
+ <sheet>
+ <div class="oe_button_box" name="button_box">
+ <button name="action_open_converted_products"
+ type="object"
+ class="oe_stat_button"
+ icon="fa-cubes"
+ attrs="{'invisible': [('converted_product_count', '=', 0)]}">
+ <field name="converted_product_count" widget="statinfo" string="Products"/>
+ </button>
+ </div>
+ <widget name="web_ribbon"
+ title="COMPLETE"
+ bg_color="bg-success"
+ attrs="{'invisible': [('state', '!=', 'done')]}"/>
+
+ <widget name="web_ribbon"
+ title="CANCEL"
+ bg_color="bg-danger"
+ attrs="{'invisible': [('state', '!=', 'cancel')]}"/>
+ <h1>
+ <field name="name" readonly="1"/>
+ </h1>
+
+ <group>
+ <group>
+ <!-- <field name="leads_id" readonly="1"/> -->
+ <field name="eta_sales"/>
+ <field name="eta_complete" readonly="1"/>
+ <field name="has_price_in_lines" invisible="1"/>
+ <field name="so_id" readonly="1"/>
+ </group>
+ <group>
+ <field name="create_uid" readonly="1" widget="many2one_avatar_user"/>
+ <field name="md_user_id" widget="many2many_tags"/>
+ <field name="approval_sales" readonly="1"/>
+ <field name="progress_status"
+ decoration-info="progress_status in ['🟡 On Track', '🔵 Ontime']"
+ decoration-success="'🟢' in progress_status"
+ decoration-danger="'🔴' in progress_status"
+ decoration-muted="'âš«' in progress_status"/>
+ </group>
+ </group>
+
+ <notebook>
+ <page string="Product Line" groups="indoteknik_custom.group_role_sales"
+ attrs="{'invisible': [('has_price_in_lines', '=', True)]}">
+ <field name="line_sales_input_ids" attrs="{'readonly': [('state', '!=', 'draft')]}">
+ <tree>
+ <field name="brand"/>
+ <field name="product_name"/>
+ <field name="descriptions"/>
+ <field name="quantity"/>
+ <field name="md_person_ids" widget="many2one_avatar_user"/>
+ <field name="state" readonly="1" widget="badge"
+ decoration-warning="state in ('sourcing','sent')"
+ decoration-info="state == 'approve'"
+ decoration-success="state == 'done'"
+ decoration-danger="state == 'cancel'"/>
+ <field name="note" optional="hide"/>
+ <field name="budget" optional="hide"/>
+ </tree>
+ <form string="Product Line">
+ <group>
+
+ <field name="brand" placeholder="Jika tidak mengetahui Brandnya isi saja *No Brand" required="1"/>
+ <field name="product_name"/>
+ <field name="descriptions" required="1"/>
+ <field name="quantity"/>
+ <field name="note"/>
+ <field name="budget"/>
+ <field name="attachment_type"/>
+
+ <field name="product_attachment_pdf"
+ filename="product_attachment_filename"
+ attrs="{'invisible':[('attachment_type','!=','pdf')]}"/>
+
+ <field name="product_attachment_img"
+ filename="product_attachment_filename"
+ widget="image"
+ attrs="{'invisible':[('attachment_type','!=','img')]}"/>
+
+ <field name="product_attachment_other"
+ filename="product_attachment_filename"
+ attrs="{'invisible':[('attachment_type','!=','other')]}"/>
+ </group>
+ </form>
+ </field>
+ </page>
+
+ <!-- MD EDIT -->
+ <!-- <page string="MD Lines" groups="indoteknik_custom.group_role_merchandiser">
+ <field name="line_md_edit_ids">
+ <tree
+ decoration-success="state in ('done', 'convert')"
+ decoration-danger="state=='cancel'"
+ decoration-warning="state=='sourcing'">
+ <field name="selected" widget="boolean_toggle"/>
+ <field name="code"/>
+ <field name="brand"/>
+ <field name="product_name"/>
+ <field name="descriptions"/>
+ <field name="quantity"/>
+ <field name="price"/>
+ <field name="vendor_id"/>
+ <field name="tax_id"/>
+ <field name="subtotal"/>
+ <field name="state"/>
+ <field name="sla"/>
+ <button name="action_convert_to_product"
+ string="Convert"
+ type="object"
+ icon="fa-exchange"
+ attrs="{'invisible': [('state', '!=', 'done')]}"/>
+ <button name="action_cancel_line"
+ string="Unavailable"
+ type="object"
+ class="btn-danger"
+ groups="indoteknik_custom.group_role_merchandiser"
+ attrs="{'invisible': [('state', '=', 'cancel')]}"/>
+ </tree>
+ <form string="MD Line">
+ <group>
+ <group>
+ <field name="code"/>
+ <field name="brand"/>
+ <field name="product_name"/>
+ <field name="descriptions"/>
+ <field name="quantity"/>
+ <field name="price"/>
+ <field name="vendor_id"/>
+ <field name="tax_id"/>
+ <field name="subtotal" readonly="1"/>
+ <field name="sla"/>
+ </group>
+ <group>
+ <field name="product_category"/>
+ <field name="product_type"/>
+ <field name="product_class" widget="many2many_tags"/>
+ <field name="note"/>
+ <field name="budget"/>
+ <field name="product_image" widget="image"/>
+ <field name="state" readonly="1" force_save="1"/>
+ <field name="reason" attrs="{'invisible': [('state', 'in', ['cancel', 'done', 'convert'])]}"/>
+ </group>
+ </group>
+ </form>
+ </field>
+ </page> -->
+
+ <!-- SALES VIEW -->
+ <page string="Product Line" groups="indoteknik_custom.group_role_sales" attrs="{'invisible': [('has_price_in_lines', '=', False)]}">
+ <field name="line_sales_view_ids">
+ <tree create="0" delete="0"
+ decoration-warning="state in ('sourcing','sent')"
+ decoration-info="state == 'approve'"
+ decoration-success="state == 'done'"
+ decoration-danger="state == 'cancel'">
+ <button name="action_reopen_cancel"
+ type="object"
+ string="Reopen"
+ class="btn-warning"
+ attrs="{
+ 'invisible': [
+ ('state','!=','cancel'),
+ ]
+ }"/>
+
+ <field name="product_id" readonly="1"/>
+ <field name="code" readonly="1"/>
+ <field name="brand" readonly="1"/>
+ <field name="product_name" readonly="1"/>
+ <field name="descriptions" readonly="1"/>
+ <field name="quantity" readonly="1"/>
+ <field name="price" readonly="1"/>
+ <field name="vendor_id" readonly="1"/>
+ <field name="tax_id" readonly="1"/>
+ <field name="subtotal" readonly="1"/>
+ <field name="state" readonly="1" widget="badge"
+ decoration-warning="state in ('sourcing','sent')"
+ decoration-info="state == 'approve'"
+ decoration-success="state == 'done'"
+ decoration-danger="state == 'cancel'"/>
+ </tree>
+ </field>
+ </page>
+
+ <page string="Cancel Reason" attrs="{'invisible': [('state', 'in', ['done'])]}">
+ <group>
+ <field name="cancel_reason"/>
+ </group>
+ </page>
+ </notebook>
+ </sheet>
+ <div class="oe_chatter">
+ <field name="message_follower_ids" widget="mail_followers"/>
+ <field name="message_ids" widget="mail_thread"/>
+ <field name="activity_ids" widget="mail_activity"/>
+ </div>
+ </form>
+ </field>
+ </record>
+
+ <record id="action_wizard_export_sjo_to_so" model="ir.actions.act_window">
+ <field name="name">Export Products to SO</field>
+ <field name="res_model">wizard.export.sjo.to.so</field>
+ <field name="view_mode">form</field>
+ <field name="view_id" ref="view_wizard_export_sjo_to_so_form"/>
+ <field name="target">new</field>
+ <field name="context">{'default_sjo_id': active_id}</field>
+ </record>
+
+ <record id="action_sourcing_job_order_sales" model="ir.actions.act_window">
+ <field name="name">Sourcing Job Orders</field>
+ <field name="res_model">sourcing.job.order</field>
+ <field name="view_mode">tree,form</field>
+ <field name="search_view_id" ref="view_sourcing_job_order_search"/>
+ <field name="context">{'search_default_by_create_uid': 1}</field>
+ <field name="groups_id" eval="[(4, ref('indoteknik_custom.group_role_sales'))]"/>
+ </record>
+
+ <menuitem id="menu_sourcing_job_order_sales"
+ name="Sourcing Job Orders"
+ parent="indoteknik_custom.menu_monitoring_in_sale"
+ action="action_sourcing_job_order_sales"
+ groups="indoteknik_custom.group_role_sales"
+ sequence="102"/>
+
+ <!-- MD Views -->
+ <record id="view_sourcing_job_order_line_search" model="ir.ui.view">
+ <field name="name">sourcing.job.order_line.search</field>
+ <field name="model">sourcing.job.order.line</field>
+ <field name="arch" type="xml">
+ <search string="Search MD Job">
+ <field name="state" string="Status"/>
+ <filter name="untaken"
+ string="Untaken"
+ domain="[('state', '=', 'draft')]" />
+ <filter name="my_job"
+ string="My Job"
+ domain="[('md_person_ids', '=', uid), ('state', '=', 'sourcing')]"/>
+ </search>
+ </field>
+ </record>
+
+ <record id="view_sjo_template_wizard" model="ir.ui.view">
+ <field name="name">sjo.template.wizard.form</field>
+ <field name="model">sourcing.job.order.line.template.wizard</field>
+ <field name="arch" type="xml">
+ <form string="Import Sourcing Job Order Line">
+ <group string="Download Template">
+ <field name="file" filename="filename" readonly="1"/>
+ <field name="filename" invisible="1"/>
+
+ <button name="action_generate_template"
+ string="Download Template"
+ type="object"
+ class="btn-secondary"/>
+ </group>
+
+ <separator string="Import Excel"/>
+
+ <group>
+ <field name="order_id" required="1"/>
+ <field name="excel_file" filename="excel_filename"/>
+ <field name="excel_filename" invisible="1"/>
+ </group>
+
+ <footer>
+ <button name="action_import_excel"
+ string="Import"
+ type="object"
+ class="btn-primary"/>
+
+ <button string="Close" special="cancel"/>
+ </footer>
+
+ </form>
+ </field>
+ </record>
+
+ <record id="action_import_sjo_line_server" model="ir.actions.server">
+ <field name="name">Import Line</field>
+ <field name="model_id" ref="model_sourcing_job_order_line"/>
+ <field name="binding_model_id" ref="model_sourcing_job_order_line"/>
+ <field name="binding_view_types">list</field>
+ <field name="state">code</field>
+
+ <field name="code">
+ action = {
+ 'type': 'ir.actions.act_window',
+ 'name': 'Import SJO Line',
+ 'res_model': 'sourcing.job.order.line.template.wizard',
+ 'view_mode': 'form',
+ 'target': 'new',
+ 'context': {'default_order_id': env.context.get('active_id')}
+ }
+ </field>
+ </record>
+
+ <record id="view_sourcing_job_order_line_tree" model="ir.ui.view">
+ <field name="name">sourcing.job.order.line.tree</field>
+ <field name="model">sourcing.job.order.line</field>
+ <field name="arch" type="xml">
+ <tree string="Sourcing Job Order"
+ decoration-warning="state=='sourcing'"
+ decoration-success="state== 'done'"
+ decoration-danger="state=='cancel'"
+ decoration-info="state in ('sent','approve')">
+ <field name="order_id" />
+ <field name="md_person_ids" widget="many2one_avatar_user"/>
+ <field name="brand"/>
+ <field name="product_name"/>
+ <field name="descriptions"/>
+ <field name="attachment_type" />
+ <field name="quantity"/>
+ <field name="state" widget="badge"
+ decoration-muted="state=='draft'"
+ decoration-warning="state=='sourcing'"
+ decoration-success="state in ('done','convert')"
+ decoration-danger="state=='cancel'"/>
+ <field name="budget" optional="hide"/>
+ <field name="note" optional="hide"/>
+ </tree>
+ </field>
+ </record>
+
+ <record id="view_reject_sourcing_wizard" model="ir.ui.view">
+ <field name="name">reject.sourcing.wizard.form</field>
+ <field name="model">sourcing.reject.wizard</field>
+ <field name="arch" type="xml">
+ <form string="Alasan Reject">
+ <group>
+ <field name="reason" placeholder="Isi alasan reject..."/>
+ </group>
+ <footer>
+ <button name="action_confirm_reject"
+ type="object"
+ string="Confirm Reject"
+ class="btn-primary"/>
+ <button string="Cancel" special="cancel"/>
+ </footer>
+ </form>
+ </field>
+ </record>
+
+ <record id="view_sourcing_job_order_line_form" model="ir.ui.view">
+ <field name="name">sourcing.job.order.line.form</field>
+ <field name="model">sourcing.job.order.line</field>
+ <field name="arch" type="xml">
+ <form string="Sourcing Job">
+ <header>
+ <button name="action_take"
+ string="Take"
+ type="object"
+ class="btn-primary"
+ icon="fa-hand-paper-o"
+ attrs="{'invisible': [('state', '!=', 'draft')]}"/>
+
+ <button name="action_cancel"
+ string="Cancel"
+ type="object"
+ class="btn-secondary"
+ icon="fa-times"
+ groups="indoteknik_custom.group_role_merchandiser"
+ attrs="{'invisible': [('state', 'in', ['cancel', 'done'])]}"/>
+
+ <button name="action_convert"
+ string="Convert Lines"
+ type="object"
+ class="btn-success"
+ groups="indoteknik_custom.group_role_merchandiser"
+ attrs="{'invisible': [('state', '!=', 'approve')]}"/>
+
+ <button name="action_ask_approval"
+ string="Ask Approval"
+ type="object"
+ groups="indoteknik_custom.group_role_merchandiser"
+ attrs="{'invisible': [('state', '!=', 'sourcing')]}"/>
+
+ <button name="action_reject_approval"
+ string="Reject"
+ type="object"
+ groups="indoteknik_custom.group_role_sales"
+ attrs="{'invisible': [('state', '!=', 'sent')]}"/>
+
+ <button name="action_approve_approval"
+ string="Approve"
+ class="btn-primary"
+ type="object"
+ groups="indoteknik_custom.group_role_sales"
+ attrs="{'invisible': [('state', '!=', 'sent')]}"/>
+
+ <field name="state" widget="statusbar"
+ statusbar_visible="draft,sourcing,sent,approve,done,cancel" attrs="{'invisible': [('state', '!=', 'cancel')]}"/>
+
+ <field name="state" widget="statusbar"
+ statusbar_visible="draft,sourcing,sent,approve,done" attrs="{'invisible': [('state', '=', 'cancel')]}"/>
+ </header>
+ <sheet >
+ <widget name="web_ribbon"
+ title="COMPLETE"
+ bg_color="bg-success"
+ attrs="{'invisible': [('state', '!=', 'done')]}"/>
+
+ <widget name="web_ribbon"
+ title="CANCEL"
+ bg_color="bg-danger"
+ attrs="{'invisible': [('state', '!=', 'cancel')]}"/>
+ <h1>
+ <field name="order_id" readonly="1"/>
+ </h1>
+ <group col="2">
+ <group>
+ <field name="create_uid" invisible="1"/>
+ <field name="md_person_ids" widget="many2one_avatar_user" readonly="1"/>
+ <field name="product_id" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="code" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="brand" required="1" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="product_name" required="1" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="descriptions" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="quantity" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="price" required="1" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="now_price" force_save="1" readonly="1"/>
+ <field name="last_updated_price" readonly="1"/>
+ <field name="vendor_id" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="tax_id" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="subtotal" readonly="1" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="sla" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ </group>
+
+ <group>
+ <field name="product_category" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="product_type" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="product_class" widget="many2many_tags" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="note" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="budget" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+ <field name="attachment_type" attrs="{'readonly': [('state', 'in', ['done', 'cancel', 'approve'])]}"/>
+
+ <field name="product_attachment_pdf"
+ filename="product_attachment_filename"
+ widget="pdf_viewer"
+ attrs="{'invisible':[('attachment_type','!=','pdf')]}"/>
+
+ <field name="product_attachment_img"
+ filename="product_attachment_filename"
+ widget="image"
+ attrs="{'invisible':[('attachment_type','!=','img')]}"/>
+
+ <field name="product_attachment_other"
+ filename="product_attachment_filename"
+ attrs="{'invisible':[('attachment_type','!=','other')]}"/>
+ </group>
+ </group>
+ <notebook>
+ <page string="Cancel Reason" attrs="{'invisible': [('state', 'in', ['done', 'approve'])]}">
+ <group>
+ <field name="reason"/>
+ </group>
+ </page>
+ </notebook>
+ </sheet>
+ <div class="oe_chatter">
+ <field name="message_follower_ids" widget="mail_followers"/>
+ <field name="message_ids" widget="mail_thread"/>
+ <field name="activity_ids" widget="mail_activity"/>
+ </div>
+ </form>
+ </field>
+ </record>
+
+ <record id="action_sourcing_job_order_line_multi_take" model="ir.actions.server">
+ <field name="name">Take Selected Jobs</field>
+ <field name="model_id" ref="model_sourcing_job_order_line"/>
+ <field name="binding_model_id" ref="model_sourcing_job_order_line"/>
+ <field name="binding_type">action</field>
+ <field name="state">code</field>
+ <field name="code">action = records.action_multi_take()</field>
+ <field name="groups_id" eval="[(4, ref('indoteknik_custom.group_role_merchandiser'))]"/>
+ </record>
+
+ <record id="action_sourcing_job_order_md" model="ir.actions.act_window">
+ <field name="name">Sourcing Job Orders</field>
+ <field name="res_model">sourcing.job.order.line</field>
+ <field name="view_mode">tree,form</field>
+ <field name="search_view_id" ref="view_sourcing_job_order_line_search"/>
+ <field name="context">{'search_default_untaken': 1, 'search_default_my_job': 1}</field>
+ <field name="groups_id" eval="[(4, ref('indoteknik_custom.group_role_merchandiser'))]"/>
+ </record>
+
+ <menuitem id="menu_md_root"
+ name="MD"
+ parent="crm.crm_menu_root"
+ sequence="80"/>
+
+ <menuitem id="menu_sourcing_job_order_md"
+ name="Sourcing Job"
+ parent="indoteknik_custom.menu_monitoring_in_sale"
+ action="action_sourcing_job_order_md"
+ groups="indoteknik_custom.group_role_merchandiser"
+ sequence="91"/>
+</odoo>