Merge pull request 'EGON GML Payment date' (#260) from fix_egon_payment_date into master
Reviewed-on: SGD-Nord/konova#260
This commit is contained in:
commit
f7b01f4fc4
@ -67,6 +67,7 @@ class EgonGmlBuilder:
|
|||||||
"""
|
"""
|
||||||
intervention = None
|
intervention = None
|
||||||
gml = None
|
gml = None
|
||||||
|
_PAYMENT_FALLBACK_DATE = ""
|
||||||
|
|
||||||
def __init__(self, intervention):
|
def __init__(self, intervention):
|
||||||
self.intervention = intervention
|
self.intervention = intervention
|
||||||
@ -164,7 +165,10 @@ class EgonGmlBuilder:
|
|||||||
payment_date = None
|
payment_date = None
|
||||||
if payment is not None:
|
if payment is not None:
|
||||||
payment_date = payment.due_on
|
payment_date = payment.due_on
|
||||||
payment_date = payment_date.strftime(DEFAULT_DATE_FORMAT)
|
if payment_date is not None:
|
||||||
|
payment_date = payment_date.strftime(DEFAULT_DATE_FORMAT)
|
||||||
|
else:
|
||||||
|
payment_date = self._PAYMENT_FALLBACK_DATE
|
||||||
|
|
||||||
cons_office = self.intervention.responsible.conservation_office
|
cons_office = self.intervention.responsible.conservation_office
|
||||||
reg_office = self.intervention.responsible.registration_office
|
reg_office = self.intervention.responsible.registration_office
|
||||||
|
Loading…
Reference in New Issue
Block a user