From 1c4d0d8f582ff5aa9253786f1a0308804ea1c2c5 Mon Sep 17 00:00:00 2001
From: jordan <jordan@le-filament.com>
Date: Tue, 14 Dec 2021 15:06:41 +0100
Subject: [PATCH] [add] decoration_danger on out_refund in draft status

---
 views/scop_bordereau_cg.xml | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/views/scop_bordereau_cg.xml b/views/scop_bordereau_cg.xml
index 9a6683f..6494508 100644
--- a/views/scop_bordereau_cg.xml
+++ b/views/scop_bordereau_cg.xml
@@ -109,7 +109,9 @@
                             <page string="Appels de cotisation">
                                 <field name="invoice_ids" widget="one2many" class="mt-2">
                                     <tree edit="false" create="false" delete="false" default_order="type_contribution_id, cotiz_quarter"
-                                          decoration-info="state == 'draft'" decoration-success="state == 'paid'" decoration-muted="state == 'cancel'">
+                                          decoration-info="state == 'draft'" decoration-success="state == 'paid'"
+                                          decoration-muted="state == 'cancel'" decoration-danger="type == 'out_refund' and state == 'open'">
+                                        <field name="type" invisible="1"/>
                                         <field name="type_contribution_id"/>
                                         <field name="cotiz_quarter"/>
                                         <field name="date_due"/>
-- 
GitLab