Skip to content
Extraits de code Groupes Projets
Valider 9f7efda6 rédigé par Benjamin - Le Filament's avatar Benjamin - Le Filament
Parcourir les fichiers

[update] partner contribution view: remove is_loss column and filter payments on entry

parent ca1b6dde
Branches
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -198,7 +198,9 @@ class ScopContributionReport(models.Model):
payments_html = False
if self.source == "odoo":
invoice_ids = self.get_invoice_contribution()
payment_ids = invoice_ids.mapped("move_line_payment_ids")
payment_ids = invoice_ids.mapped("move_line_payment_ids").filtered(
lambda p: p.move_id.move_type == "entry"
)
if payment_ids:
payments = payment_ids.mapped(
lambda p: {
......@@ -208,14 +210,6 @@ class ScopContributionReport(models.Model):
"credit": p.credit,
"class": "",
}
if p.move_id.move_type not in ("out_invoice", "out_refund")
else {
"date": p.date,
"name": p.name,
"ref": "",
"credit": p.credit,
"class": "text-danger",
}
)
payments_html = self._get_html_table(payments)
if not payments_html:
......
......@@ -30,10 +30,6 @@
<field name='amount_called' />
<field name='amount_paid' />
<field name='amount_due' />
<field
name='is_loss'
style="text-align: center;"
/>
</tree>
</field>
</page>
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter