summaryrefslogtreecommitdiff
path: root/indoteknik_custom/views/vendor_approval.xml
diff options
context:
space:
mode:
authorit-fixcomart <it@fixcomart.co.id>2024-10-08 15:24:18 +0700
committerit-fixcomart <it@fixcomart.co.id>2024-10-08 15:24:18 +0700
commit2fcddbb073a04ed6ba0e9666a8ab5082a3ef4073 (patch)
treed4a3a423adf53ea8c086397abbcfe05a369fe637 /indoteknik_custom/views/vendor_approval.xml
parentec1e2331be248a505d89c00244d6b0fe5bd61c26 (diff)
parentce1c714c95f68b07f9b891600ba1e3b88288652c (diff)
Merge branch 'production' into iman/telegram
# Conflicts: # indoteknik_custom/models/__init__.py
Diffstat (limited to 'indoteknik_custom/views/vendor_approval.xml')
-rw-r--r--indoteknik_custom/views/vendor_approval.xml106
1 files changed, 106 insertions, 0 deletions
diff --git a/indoteknik_custom/views/vendor_approval.xml b/indoteknik_custom/views/vendor_approval.xml
new file mode 100644
index 00000000..605edfbf
--- /dev/null
+++ b/indoteknik_custom/views/vendor_approval.xml
@@ -0,0 +1,106 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<odoo>
+ <data>
+ <record id="vendor_approval_tree" model="ir.ui.view">
+ <field name="name">vendor.approval.tree</field>
+ <field name="model">vendor.approval</field>
+ <field name="arch" type="xml">
+ <tree default_order="create_date desc" create="0">
+ <field name="number"/>
+ <field name="create_date_so"/>
+ <field name="order_id"/>
+ <field name="partner_id"/>
+ <field name="state"/>
+ </tree>
+ </field>
+ </record>
+
+ <record id="vendor_approval_line_tree" model="ir.ui.view">
+ <field name="name">vendor.approval.line.tree</field>
+ <field name="model">vendor.approval.line</field>
+ <field name="arch" type="xml">
+ <tree>
+ <field name="product_id"/>
+ <field name="sales_price"/>
+ <field name="product_uom_qty"/>
+ <field name="sales_tax_id"/>
+ <field name="margin_after"/>
+ <field name="vendor_id"/>
+ <field name="vendor_md_id"/>
+ <field name="purchase_price"/>
+ <field name="purchase_price_md"/>
+ <field name="margin_before"/>
+ <field name="purchase_tax_id"/>
+ <field name="percent_margin_difference"/>
+ </tree>
+ </field>
+ </record>
+
+ <record id="vendor_approval_form" model="ir.ui.view">
+ <field name="name">vendor.approval.form</field>
+ <field name="model">vendor.approval</field>
+ <field name="arch" type="xml">
+ <form create="false">
+ <header>
+ <button name="action_approve"
+ string="Approve"
+ type="object"
+ attrs="{'invisible': [('state', 'not in', ['draft'])]}"
+ />
+ <button name="action_reject"
+ string="Reject"
+ type="object"
+ attrs="{'invisible': [('state', 'not in', ['draft'])]}"
+ />
+ </header>
+ <sheet>
+ <group>
+ <group>
+ <field name="partner_id" readonly="1"/>
+ <field name="order_id" readonly="1"/>
+ <field name="state" readonly="1"/>
+ <field name="create_date_so" readonly="1"/>
+ </group>
+ </group>
+ <notebook>
+ <page string="SO Line">
+ <field name="vendor_approval_line" readonly="1"/>
+ </page>
+ </notebook>
+ </sheet>
+ <div class="oe_chatter">
+ <field name="message_follower_ids" widget="mail_followers"/>
+ <field name="message_ids" widget="mail_thread"/>
+ </div>
+ </form>
+ </field>
+ </record>
+
+ <record id="vendor_approval_view_search" model="ir.ui.view">
+ <field name="name">vendor.approval.search.view</field> <!-- Made the name more descriptive -->
+ <field name="model">vendor.approval</field>
+ <field name="arch" type="xml">
+ <search string="Search Vendor Approval">
+ <field name="number"/>
+ <field name="partner_id"/>
+ <field name="order_id"/>
+ </search>
+ </field>
+ </record>
+
+ <record id="vendor_approval_action" model="ir.actions.act_window">
+ <field name="name">Vendor Approval</field>
+ <field name="type">ir.actions.act_window</field>
+ <field name="res_model">vendor.approval</field>
+ <field name="view_mode">tree,form</field>
+ </record>
+
+ <menuitem
+ id="menu_vendor_approval"
+ name="Vendor Approval"
+ parent="sale.product_menu_catalog"
+ sequence="4"
+ action="vendor_approval_action"
+ />
+ </data>
+</odoo>