[IMP] rma_account: add index in account.move.line to field 'rma_line_id'

This commit is contained in:
Jordi Ballester Alomar
2023-02-27 16:08:38 +01:00
committed by AaronHForgeFlow
parent 8c33885fbc
commit c218a8bca8
2 changed files with 3 additions and 2 deletions

View File

@@ -235,6 +235,7 @@ class AccountMoveLine(models.Model):
comodel_name="rma.order.line",
string="RMA line",
ondelete="set null",
index=True,
help="This will contain the rma line that originated this line",
)

View File

@@ -59,13 +59,13 @@
name="%(action_rma_refund)d"
string="Create Refund"
class="oe_highlight"
attrs="{'invisible':['|', '|', ('qty_to_refund', '=', 0), ('state', '!=', 'approved'), ('refund_policy', '=', 'no')]}"
attrs="{'invisible':['|', '|', '|', ('qty_to_refund', '=', 0), ('qty_to_refund', '<', 0), ('state', '!=', 'approved'), ('refund_policy', '=', 'no')]}"
type="action"
/>
<button
name="%(action_rma_refund)d"
string="Create Refund"
attrs="{'invisible':['|', '|', ('qty_to_refund', '!=', 0), ('state', '!=', 'approved'), ('refund_policy', '=', 'no')]}"
attrs="{'invisible':['|', '|', ('qty_to_refund', '>', 0), ('state', '!=', 'approved'), ('refund_policy', '=', 'no')]}"
type="action"
/>
</xpath>