mirror of
https://github.com/ForgeFlow/stock-rma.git
synced 2025-01-21 12:57:49 +02:00
[IMP] Make rma order view cleaner for user
Hide button and fields depending on the policy chosen on the rma line
This commit is contained in:
committed by
DavidJForgeFlow
parent
2760f14ed0
commit
aa7253dc30
@@ -444,6 +444,30 @@
|
||||
</group>
|
||||
</group>
|
||||
<notebook>
|
||||
<page name="quantities" string="Quantities">
|
||||
<group name="quantities" col="4" string="Quantities">
|
||||
<group
|
||||
name="receive"
|
||||
attrs="{'invisible': [('receipt_policy', '=', 'no')]}"
|
||||
>
|
||||
<field name="qty_to_receive" />
|
||||
<field name="qty_incoming" />
|
||||
<field name="qty_received" />
|
||||
</group>
|
||||
<group
|
||||
name="deliver"
|
||||
attrs="{'invisible': [('delivery_policy', '=', 'no')]}"
|
||||
>
|
||||
<field name="qty_to_deliver" />
|
||||
<field name="qty_outgoing" />
|
||||
<field name="qty_delivered" />
|
||||
</group>
|
||||
<group name="supplier_rma">
|
||||
<field name="qty_to_supplier_rma" />
|
||||
<field name="qty_in_supplier_rma" />
|
||||
</group>
|
||||
</group>
|
||||
</page>
|
||||
<page name="route" string="Routes">
|
||||
<group name="inbound" string="Inbound">
|
||||
<field name="in_warehouse_id" />
|
||||
@@ -472,7 +496,11 @@
|
||||
/>
|
||||
</group>
|
||||
</page>
|
||||
<page name="stock" string="Stock Moves">
|
||||
<page
|
||||
name="stock"
|
||||
string="Stock Moves"
|
||||
attrs="{'invisible': [('move_ids', '=', [])]}"
|
||||
>
|
||||
<field name="move_ids" nolabel="1" readonly="1" />
|
||||
</page>
|
||||
<page name="quantities" string="Quantities">
|
||||
|
||||
@@ -103,6 +103,7 @@
|
||||
states="approved"
|
||||
string="Create Incoming Shipment"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_receive', '=', 0), ('state', '!=', 'approved'), ('receipt_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
<button
|
||||
@@ -110,6 +111,7 @@
|
||||
states="approved"
|
||||
string="Create Delivery"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_deliver', '=', 0), ('state', '!=', 'approved'), ('delivery_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
@@ -127,6 +129,7 @@
|
||||
states="approved"
|
||||
string="Create Incoming Shipment"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_receive', '=', 0), ('state', '!=', 'approved'), ('receipt_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
<button
|
||||
@@ -134,6 +137,7 @@
|
||||
states="approved"
|
||||
string="Create Delivery"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_deliver', '=', 0), ('state', '!=', 'approved'), ('delivery_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
|
||||
@@ -95,7 +95,11 @@
|
||||
<field name="refund_policy" />
|
||||
</field>
|
||||
<page name="stock" position="after">
|
||||
<page name="refunds" string="Refunds">
|
||||
<page
|
||||
name="refunds"
|
||||
string="Refunds"
|
||||
attrs="{'invisible': [('refund_line_ids', '=', [])]}"
|
||||
>
|
||||
<field name="refund_line_ids" nolabel="1" />
|
||||
</page>
|
||||
</page>
|
||||
@@ -106,7 +110,10 @@
|
||||
/>
|
||||
</field>
|
||||
<group name="supplier_rma" position="after">
|
||||
<group name="refund">
|
||||
<group
|
||||
name="refund"
|
||||
attrs="{'invisible': [('refund_policy', '=', 'no')]}"
|
||||
>
|
||||
<field name="qty_to_refund" />
|
||||
<field name="qty_refunded" />
|
||||
</group>
|
||||
|
||||
@@ -59,6 +59,7 @@
|
||||
states="approved"
|
||||
string="Create Refund"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_refund', '=', 0), ('state', '!=', 'approved'), ('refund_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
@@ -76,6 +77,7 @@
|
||||
states="approved"
|
||||
string="Create Refund"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_refund', '!=', 0), ('state', '!=', 'approved'), ('refund_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
/>
|
||||
</group>
|
||||
<group name="quantities" position="inside">
|
||||
<group>
|
||||
<group attrs="{'invisible': [('sale_policy', '=', 'no')]}">
|
||||
<field name="qty_to_sell" />
|
||||
<field name="qty_sold" />
|
||||
</group>
|
||||
@@ -44,7 +44,11 @@
|
||||
/>
|
||||
</field>
|
||||
<notebook position="inside">
|
||||
<page name="sale" string="Sale Lines">
|
||||
<page
|
||||
name="sale"
|
||||
string="Sale Lines"
|
||||
attrs="{'invisible': [('sale_line_ids', '=', [])]}"
|
||||
>
|
||||
<field name="sale_line_ids" nolabel="1" />
|
||||
</page>
|
||||
</notebook>
|
||||
@@ -99,6 +103,7 @@
|
||||
states="approved"
|
||||
string="Create Sales Quotation"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_sell', '=', 0), ('state', '!=', 'approved'), ('sale_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
@@ -115,6 +120,7 @@
|
||||
states="approved"
|
||||
string="Create Sales Quotation"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_sell', '!=', 0), ('state', '!=', 'approved'), ('sale_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
|
||||
Reference in New Issue
Block a user