Commit fac04ebd by aa.gusti

sipkd

1 parent 985e4f1c
...@@ -75,6 +75,7 @@ def validate_parent(tabel, departemen_kd, departemen_nm, rekening, tanggal): ...@@ -75,6 +75,7 @@ def validate_parent(tabel, departemen_kd, departemen_nm, rekening, tanggal):
filter_by(tahun=str(row.tahun), filter_by(tahun=str(row.tahun),
kode=row.kode.strip(), kode=row.kode.strip(),
departemen_kd = departemen_kd.strip(), departemen_kd = departemen_kd.strip(),
tanggal = tanggal
).first() ).first()
if not induk: if not induk:
induk = tabel() induk = tabel()
...@@ -140,11 +141,11 @@ def import_by(all=False): ...@@ -140,11 +141,11 @@ def import_by(all=False):
eis.jumlah = row.realisasi eis.jumlah = row.realisasi
EisDBSession.add(eis) EisDBSession.add(eis)
EisDBSession.flush() EisDBSession.flush()
validate_parent(EisByPayment, eis.departemen_kd, eis.departemen_nm, eis.kode) validate_parent(EisByPayment, eis.departemen_kd, eis.departemen_nm, eis.kode, eis.tanggal)
EisDBSession.commit() EisDBSession.commit()
EisDBSession.commit() EisDBSession.commit()
#import_ap(True) import_ap(True)
import_by(True) import_by(True)
calculate(EisApPayment,True) calculate(EisApPayment,True)
calculate(EisByPayment,True) calculate(EisByPayment,True)
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!