Commit db40777a by Owo Sugiana

Tambah Kabupaten Tangerang

1 parent 886ddf66
0.3.4 2021-05-03
----------------
- Tambah Kabupaten Tangerang
0.3.3 2021-04-29 0.3.3 2021-04-29
---------------- ----------------
- Tambah Kabupaten Kuningan - Tambah Kabupaten Kuningan
......
from datetime import date
from .default import (
Inquiry as BaseInquiry,
Reversal,
AvailableInvoice as BaseAvailableInvoice,
)
def dmy(tgl):
return tgl.strftime('%d-%m-%Y')
AKHIR_TGL_BAYAR = date(2021, 6, 30)
NOTE_TGL_BAYAR = 'Tanggal bayar {tgl} <= ' + dmy(AKHIR_TGL_BAYAR)
class Inquiry(BaseInquiry):
def get_discount_denda(self): # Override
tgl_bayar = self.tgl_bayar.date()
if tgl_bayar > AKHIR_TGL_BAYAR:
return 0
notes = [NOTE_TGL_BAYAR.format(tgl=dmy(tgl_bayar))]
return self.denda
class AvailableInvoice(BaseAvailableInvoice):
def get_inquiry_class(self): # Override
return Inquiry
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!