mirror of
https://github.com/ForgeFlow/stock-rma.git
synced 2025-01-21 12:57:49 +02:00
388 lines
21 KiB
XML
388 lines
21 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<odoo>
|
|
<data>
|
|
<record id="view_rma_line_tree" model="ir.ui.view">
|
|
<field name="name">rma.order.line.tree</field>
|
|
<field name="model">rma.order.line</field>
|
|
<field name="arch" type="xml">
|
|
<tree string="RMA Line" nocreate="1"
|
|
decoration-muted="state in ('draft','to_approve')">
|
|
<field name="rma_id"/>
|
|
<field name="state" invisible="1"/>
|
|
<field name="partner_id"/>
|
|
<field name="product_id"/>
|
|
<field name="lot_id" groups="stock.group_production_lot"/>
|
|
<field name="name"/>
|
|
<field name="origin"/>
|
|
<field name="operation_id"/>
|
|
<field name="supplier_address_id"/>
|
|
<field name="uom_id" groups="product.group_uom"/>
|
|
<field name="product_qty"/>
|
|
<field name="price_unit"/>
|
|
</tree>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="view_rma_line_supplier_tree" model="ir.ui.view">
|
|
<field name="name">rma.order.line.supplier.tree</field>
|
|
<field name="model">rma.order.line</field>
|
|
<field name="arch" type="xml">
|
|
<tree string="RMA Line" nocreate="1"
|
|
decoration-muted="state in ('draft','to_approve')">
|
|
<field name="rma_id"/>
|
|
<field name="state" invisible="1"/>
|
|
<field name="partner_id"/>
|
|
<field name="product_id"/>
|
|
<field name="lot_id" groups="stock.group_production_lot"/>
|
|
<field name="name"/>
|
|
<field name="origin"/>
|
|
<field name="operation_id" domain="[('type','=','supplier')]"/>
|
|
<field name="uom_id" groups="product.group_uom"/>
|
|
<field name="product_qty"/>
|
|
<field name="price_unit"/>
|
|
</tree>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="view_rma_line_supplier_form" model="ir.ui.view">
|
|
<field name="name">rma.order.line.supplier.form</field>
|
|
<field name="model">rma.order.line</field>
|
|
<field name="arch" type="xml">
|
|
<form string="RMA Line" nocreate="1">
|
|
<sheet>
|
|
<header/>
|
|
<div name="button_box" class="oe_button_box">
|
|
<button type="object" name="action_view_in_shipments"
|
|
class="oe_stat_button"
|
|
icon="fa-truck"
|
|
groups="stock.group_stock_user">
|
|
<field name="in_shipment_count" widget="statinfo"
|
|
string="Shipments"/>
|
|
</button>
|
|
<button type="object" name="action_view_out_shipments"
|
|
class="oe_stat_button"
|
|
icon="fa-truck"
|
|
groups="stock.group_stock_user">
|
|
<field name="out_shipment_count" widget="statinfo"
|
|
string="Deliveries"/>
|
|
</button>
|
|
<button type="object" name="action_view_procurements"
|
|
class="oe_stat_button"
|
|
icon="fa-warning"
|
|
groups="stock.group_stock_user">
|
|
<field name="procurement_count" widget="statinfo"
|
|
string="Proc. Exceptions"/>
|
|
</button>
|
|
</div>
|
|
<div class="oe_title" name="title">
|
|
<h1>
|
|
<field name="rma_id" required="False"
|
|
readonly="True"
|
|
invisible="context.get('hide_title',False)"/>
|
|
</h1>
|
|
</div>
|
|
<group>
|
|
<group name="product" string="Product">
|
|
<field name="product_id"/>
|
|
<newline/>
|
|
<field name="product_tracking" invisible="1"/>
|
|
<field name="lot_id"
|
|
groups="stock.group_production_lot"
|
|
attrs="{'required': [('product_tracking', 'in', ('serial', 'lot'))]}"/>
|
|
</group>
|
|
<group name="product_qty" string="Quantity">
|
|
<field name="product_qty"/>
|
|
<field name="price_unit"/>
|
|
<field name="uom_id" groups="product.group_uom"/>
|
|
</group>
|
|
<newline/>
|
|
<group name="operation" string="Operation" colspan="2">
|
|
<field name="operation_id"
|
|
domain="[('type','=','supplier')]"/>
|
|
<field name="receipt_policy"/>
|
|
<field name="delivery_policy"/>
|
|
</group>
|
|
</group>
|
|
<notebook>
|
|
<page name="description" string="Description">
|
|
<field name="description" nolabel="1"/>
|
|
</page>
|
|
<page name="route" string="Routes" groups="stock.group_adv_location">
|
|
<group>
|
|
<group>
|
|
<group name="inbound" string="Inbound">
|
|
<field name="in_warehouse_id"/>
|
|
<field name="location_id"
|
|
domain="[('usage', '=', 'internal')]"/>
|
|
<field name="in_route_id"/>
|
|
<field name="supplier_to_customer"/>
|
|
</group>
|
|
<group name="outbound" string="Outbound">
|
|
<field name="out_warehouse_id"/>
|
|
<field name="delivery_address_id"
|
|
groups='rma.group_rma_delivery_invoice_address'/>
|
|
<field name="out_route_id"/>
|
|
</group>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
<page name="stock" string="Stock Moves">
|
|
<field name="move_ids" nolabel="1" readonly="1"/>
|
|
</page>
|
|
<page name="quantities" string="Quantities">
|
|
<group>
|
|
<group name="quantities" col="4" string="Quantities">
|
|
<group name="receive">
|
|
<field name="qty_to_receive"/>
|
|
<field name="qty_incoming"/>
|
|
<field name="qty_received"/>
|
|
</group>
|
|
<group name="deliver">
|
|
<field name="qty_to_deliver"/>
|
|
<field name="qty_outgoing"/>
|
|
<field name="qty_delivered"/>
|
|
</group>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
<page name="other" string="Other Info">
|
|
<group name="general" string="General">
|
|
<field name="name"/>
|
|
<field name="origin"/>
|
|
<field name="reference_move_id"/>
|
|
<field name="state" invisible="1"/>
|
|
</group>
|
|
<group name="contact" string="Contact">
|
|
<field name="requested_by" readonly="1"/>
|
|
<field name="assigned_to" readonly="1"/>
|
|
</group>
|
|
<group name="company" string="Company"
|
|
groups="base.group_multi_company">
|
|
<field name="company_id"/>
|
|
</group>
|
|
</page>
|
|
</notebook>
|
|
</sheet>
|
|
</form>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="view_rma_line_form" model="ir.ui.view">
|
|
<field name="name">rma.order.line.form</field>
|
|
<field name="model">rma.order.line</field>
|
|
<field name="arch" type="xml">
|
|
<form string="Rma Line" nocreate="1">
|
|
<sheet>
|
|
<header/>
|
|
<div name="button_box" class="oe_button_box">
|
|
<button type="object" name="action_view_in_shipments"
|
|
class="oe_stat_button"
|
|
icon="fa-truck"
|
|
groups="stock.group_stock_user">
|
|
<field name="in_shipment_count" widget="statinfo"
|
|
string="Shipments"/>
|
|
</button>
|
|
<button type="object" name="action_view_out_shipments"
|
|
class="oe_stat_button"
|
|
icon="fa-truck"
|
|
groups="stock.group_stock_user">
|
|
<field name="out_shipment_count" widget="statinfo"
|
|
string="Deliveries"/>
|
|
</button>
|
|
<button type="object" name="action_view_invoice"
|
|
class="oe_stat_button"
|
|
icon="fa-pencil-square-o"
|
|
string="Origin Inv">
|
|
</button>
|
|
<button type="object" name="action_view_procurements"
|
|
class="oe_stat_button"
|
|
icon="fa-warning"
|
|
groups="stock.group_stock_user">
|
|
<field name="procurement_count" widget="statinfo"
|
|
string="Exceptions"/>
|
|
</button>
|
|
</div>
|
|
<div class="oe_title" name="title">
|
|
<h1>
|
|
<field name="rma_id" required="False"
|
|
readonly="True"
|
|
invisible="context.get('hide_title',False)"/>
|
|
</h1>
|
|
</div>
|
|
<group>
|
|
<group name="product" string="Product">
|
|
<field name="product_id"/>
|
|
<newline/>
|
|
<field name="product_tracking" invisible="1"/>
|
|
<field name="lot_id"
|
|
groups="stock.group_production_lot"
|
|
attrs="{'required': [('product_tracking', 'in', ('serial', 'lot'))]}"/>
|
|
</group>
|
|
<group name="product_qty" string="Quantity">
|
|
<field name="product_qty"/>
|
|
<field name="uom_id" groups="product.group_uom"/>
|
|
<field name="price_unit"/>
|
|
</group>
|
|
<newline/>
|
|
<group name="operation" string="Operation">
|
|
<field name="operation_id" domain="[('type','=','customer')]"/>
|
|
<field name="receipt_policy"/>
|
|
<field name="delivery_policy"/>
|
|
</group>
|
|
</group>
|
|
<notebook>
|
|
<page name="route" string="Routes">
|
|
<group>
|
|
<group>
|
|
<group name="inbound" string="Inbound">
|
|
<field name="in_warehouse_id"/>
|
|
<field name="location_id"
|
|
domain="[('usage', '=', 'internal')]"/>
|
|
<field name="in_route_id"/>
|
|
<field name="customer_to_supplier"/>
|
|
<field name="supplier_address_id"
|
|
attrs="{'required':[('customer_to_supplier', '=', True)],
|
|
'invisible':[('customer_to_supplier', '=', False)]}"/>
|
|
</group>
|
|
<group name="outbound" string="Outbound">
|
|
<field name="out_warehouse_id"/>
|
|
<field name="delivery_address_id"
|
|
groups='rma.group_rma_delivery_invoice_address'/>
|
|
<field name="out_route_id"/>
|
|
</group>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
<page name="stock" string="Stock Moves">
|
|
<field name="move_ids" nolabel="1" readonly="1"/>
|
|
</page>
|
|
<page name="quantities" string="Quantities">
|
|
<group>
|
|
<group name="quantities" col="4" string="Quantities">
|
|
<group name="receive">
|
|
<field name="qty_to_receive"/>
|
|
<field name="qty_incoming"/>
|
|
<field name="qty_received"/>
|
|
</group>
|
|
<group name="deliver">
|
|
<field name="qty_to_deliver"/>
|
|
<field name="qty_outgoing"/>
|
|
<field name="qty_delivered"/>
|
|
</group>
|
|
<group name="supplier_rma"
|
|
attrs="{'invisible':[('customer_to_supplier','=',False)]}">
|
|
<field name="qty_to_supplier_rma"/>
|
|
<field name="qty_in_supplier_rma"/>
|
|
</group>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
<page name="other" string="Other Info">
|
|
<group name="general" string="General">
|
|
<field name="name"/>
|
|
<field name="origin"/>
|
|
<field name="reference_move_id"/>
|
|
<field name="state" invisible="1"/>
|
|
</group>
|
|
<group name="contact" string="Contact">
|
|
<field name="requested_by" readonly="1"/>
|
|
<field name="assigned_to" readonly="1"/>
|
|
</group>
|
|
<group name="company" string="Company"
|
|
groups="base.group_multi_company">
|
|
<field name="company_id"/>
|
|
</group>
|
|
</page>
|
|
</notebook>
|
|
</sheet>
|
|
</form>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="view_rma_rma_line_filter" model="ir.ui.view">
|
|
<field name="name">rma.order.line.select</field>
|
|
<field name="model">rma.order.line</field>
|
|
<field name="arch" type="xml">
|
|
<search string="Search RMA line">
|
|
<field name="rma_id"/>
|
|
<field name="partner_id"/>
|
|
<field name="requested_by"/>
|
|
<field name="assigned_to"/>
|
|
<field name="product_id"/>
|
|
<field name="lot_id"/>
|
|
<separator/>
|
|
<filter domain="[('assigned_to','=',uid)]" help="My RMAs"/>
|
|
<group expand="0" string="Group By">
|
|
<filter name="partner" string="Partner" domain="[]"
|
|
context="{'group_by':'partner_id'}"/>
|
|
<filter name="operation" string="Operation" domain="[]"
|
|
context="{'group_by':'operation_id'}"/>
|
|
<filter name="product" string="Product" domain="[]"
|
|
context="{'group_by':'product_id'}"/>
|
|
<filter name="to_receive" string="To Receive" domain="[('qty_to_receive', '>', 0)]"
|
|
context="{'group_by':'partner_id'}"/>
|
|
<filter name="to_deliver" string="To Deliver" domain="[('qty_to_deliver', '>', 0)]"
|
|
context="{'group_by':'partner_id'}"/>
|
|
</group>
|
|
</search>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="action_rma_customer_lines" model="ir.actions.act_window">
|
|
<field name="name">Customer RMA Lines</field>
|
|
<field name="res_model">rma.order.line</field>
|
|
<field name="domain">[('state','in', ['approved', 'done']),
|
|
('type','=', 'customer'),
|
|
('customer_to_supplier','=', False)
|
|
]</field>
|
|
<field name="context">{"search_default_assigned_to":uid}</field>
|
|
<field name="view_type">form</field>
|
|
<field name="view_mode">tree,form</field>
|
|
<field name="view_id" ref="view_rma_line_tree"/>
|
|
</record>
|
|
|
|
<record id="action_rma_supplier_lines" model="ir.actions.act_window">
|
|
<field name="name">Supplier RMA Lines</field>
|
|
<field name="res_model">rma.order.line</field>
|
|
<field name="domain">[('state','in', ['approved', 'done']),
|
|
('type','=', 'supplier')]</field>
|
|
<field name="context">{"search_default_assigned_to":uid, "supplier":1}</field>
|
|
<field name="view_type">form</field>
|
|
<field name="view_mode">tree,form</field>
|
|
<field name="view_id" ref="view_rma_line_supplier_tree"/>
|
|
</record>
|
|
|
|
<record id="action_rma_line_supplier_tree"
|
|
model="ir.actions.act_window.view">
|
|
<field eval="3" name="sequence"/>
|
|
<field name="view_mode">tree</field>
|
|
<field name="act_window_id" ref="action_rma_supplier_lines"/>
|
|
</record>
|
|
|
|
<record id="action_rma_line_supplier_form"
|
|
model="ir.actions.act_window.view">
|
|
<field eval="4" name="sequence"/>
|
|
<field name="view_mode">form</field>
|
|
<field name="view_id" ref="view_rma_line_supplier_form"/>
|
|
<field name="act_window_id" ref="action_rma_supplier_lines"/>
|
|
</record>
|
|
|
|
<menuitem
|
|
id="menu_rma_line_customer"
|
|
sequence="20"
|
|
parent="menu_customer_rma"
|
|
groups="rma.group_rma_customer_user"
|
|
action="action_rma_customer_lines"
|
|
/>
|
|
|
|
<menuitem
|
|
id="menu_rma_line_supplier"
|
|
sequence="20"
|
|
parent="menu_supplier_rma"
|
|
groups="rma.group_rma_supplier_user"
|
|
action="action_rma_supplier_lines"
|
|
/>
|
|
|
|
</data>
|
|
</odoo>
|