kuningan.py
1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
from sqlalchemy import (
Column,
Integer,
DateTime,
Float,
Time,
String,
UniqueConstraint,
ForeignKey,
)
from sqlalchemy.ext.declarative import declarative_base
from .default import Invoice
Base = declarative_base()
class Payment(Base):
__tablename__ = 'pad_sspd'
id = Column(Integer, primary_key=True)
tahun = Column(Integer, nullable=False)
sspdno = Column(Integer, nullable=False)
sspdtgl = Column(DateTime, nullable=False)
spt_id = Column(Integer, ForeignKey(Invoice.id), nullable=False)
bunga = Column(Float)
bulan_telat = Column(Integer)
hitung_bunga = Column(Integer)
printed = Column(Integer)
enabled = Column(Integer)
create_date = Column(DateTime)
create_uid = Column(Integer)
write_date = Column(DateTime)
write_uid = Column(Integer)
sspdjam = Column(Time)
tp_id = Column(Integer)
is_validated = Column(Integer)
keterangan = Column(String(255))
denda = Column(Integer)
jml_bayar = Column(Integer)
is_valid = Column(Integer)
__table_args__ = (
UniqueConstraint(tahun, sspdno),
dict(schema='pad'))