Skip to content

Commit

Permalink
Merge pull request #66 from Som-Energia/FIX_remove_invoice_with_issue…
Browse files Browse the repository at this point in the history
…_rights

Fix context when None
  • Loading branch information
MariteSomEnergia committed Oct 1, 2021
2 parents 185efe1 + e318b5c commit 3ede5a1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions som_generationkwh/giscedata_facturacio.py
Original file line number Diff line number Diff line change
Expand Up @@ -577,6 +577,9 @@ def is_gkwh(self, cursor, uid, ids, context=None):

def unlink(self, cursor, uid, ids, context=None):
"""Return gkwh rights to owner when gkwh invoice line is droped"""
if not context:
context = {}

fact_obj = self.pool.get('giscedata.facturacio.factura')
gkwh_lineowner_obj = self.pool.get('generationkwh.invoice.line.owner')
gkwh_dealer_obj = self.pool.get('generationkwh.dealer')
Expand Down

0 comments on commit 3ede5a1

Please sign in to comment.