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
Jordi Ballester Alomar
parent
d8b6f851e8
commit
b7d8092b61
@@ -41,7 +41,7 @@
|
||||
/>
|
||||
</group>
|
||||
<group name="quantities" position="inside">
|
||||
<group>
|
||||
<group attrs="{'invisible': [('sale_policy', '=', 'no')]}">
|
||||
<field name="qty_to_sell" />
|
||||
<field name="qty_sold" />
|
||||
</group>
|
||||
@@ -50,7 +50,11 @@
|
||||
<field name="sale_policy" />
|
||||
</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>
|
||||
@@ -67,13 +71,13 @@
|
||||
name="%(action_rma_order_line_make_sale_order)d"
|
||||
string="Create Sales Quotation"
|
||||
class="oe_highlight"
|
||||
attrs="{'invisible':['|', ('qty_to_sell', '=', 0), ('state', '!=', 'approved')]}"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_sell', '=', 0), ('state', '!=', 'approved'), ('sale_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
<button
|
||||
name="%(action_rma_order_line_make_sale_order)d"
|
||||
string="Create Sales Quotation"
|
||||
attrs="{'invisible':['|', ('qty_to_sell', '!=', 0), ('state', '!=', 'approved')]}"
|
||||
attrs="{'invisible':['|', '|', ('qty_to_sell', '!=', 0), ('state', '!=', 'approved'), ('sale_policy', '=', 'no')]}"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
|
||||
Reference in New Issue
Block a user