Commit 37913b94 by Owo Sugiana

Di Tangsel selain self waji ada kohir

1 parent 7662cd4b
0.4.6 2022-12-13
----------------
- Tangerang Selatan mewajibkan keberadaan Kohir saat inquiry. Kalau tidak ada
record-nya maka invoice juga dianggap tidak ada.
record-nya maka invoice juga dianggap tidak ada, kecuali bertipe self.
0.4.5 2022-10-20
----------------
......
......@@ -21,10 +21,7 @@ from ..models.tangsel import (
SptType,
Kohir,
)
from .base import (
get_db_session,
satu_kalimat,
)
from .base import satu_kalimat
AWAL_DISC = date(2022, 8, 1)
......@@ -35,11 +32,13 @@ MASA_PAJAK = date(2022, 6, 30)
class Inquiry(BaseInquiry):
def get_invoice(self): # Override
DBSession = get_db_session()
q = DBSession.query(Invoice).filter_by(
tahun=self.invoice_id['Tahun'], sptno=self.invoice_id['SptNo'])
q = q.filter(Kohir.spt_id == Invoice.id)
return q.first()
self.invoice = super().get_invoice()
if not self.invoice:
return
if self.is_self():
return self.invoice
if self.get_tgl_kohir():
return self.invoice
def get_invoice_id(self, raw): # Override
if raw.find('367602') == 0: # 3676: Tangsel, 02: PAD
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!