Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Owo Sugiana
/
sismiop-models
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit c22f4a4a
authored
Feb 04, 2021
by
Owo Sugiana
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Penambahan Kabupaten Cirebon
1 parent
87bfecd7
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
67 additions
and
12 deletions
CHANGES.txt
sismiop/scripts/inquiry.py
sismiop/services/bogor_kota.py
sismiop/services/cirebon_kab.py
CHANGES.txt
View file @
c22f4a4
0.1.20 2021-0
1-28
0.1.20 2021-0
2-03
-----------------
- Penambahan Kabupaten Cirebon
- Perubahan rumus Kota Bogor
0.1.19 2021-01-25
...
...
sismiop/scripts/inquiry.py
View file @
c22f4a4
...
...
@@ -81,7 +81,8 @@ def show_inquiry(inq):
pay
,
[
'pembayaran_sppt_ke'
,
'kd_kanwil'
,
'kd_kantor'
,
'kd_kanwil_bank'
,
'kd_kppbb_bank'
,
'kd_bank_tunggal'
,
'kd_bank_persepsi'
,
'kd_tp'
,
'tgl_rekam_byr_sppt'
,
'tgl_pembayaran_sppt'
,
'jml_sppt_yg_dibayar'
,
'denda_sppt'
,
'tgl_pembayaran_sppt'
,
'jml_sppt_yg_dibayar'
,
'denda_sblm_diskon'
,
'denda_sppt'
,
'discount_pokok'
,
'discount_denda'
,
'discount'
])
...
...
sismiop/services/bogor_kota.py
View file @
c22f4a4
from
time
import
time
from
datetime
import
(
date
,
datetime
,
)
from
opensipkd.hitung
import
round_up
from
datetime
import
date
from
..models.default
import
PenguranganCovid
from
..models.bogor_kota
import
PenguranganPst
from
.base
import
(
...
...
@@ -55,7 +50,7 @@ class Inquiry(BaseInquiry, Common):
def
hitung_discount_pokok
(
self
):
potongan
=
NILAI_DISC
[
self
.
tgl_bayar
.
month
]
self
.
discount_pokok
=
potongan
*
self
.
tagihan
self
.
discount_pokok
=
int
(
potongan
*
self
.
tagihan
)
def
hitung_discount_denda
(
self
):
self
.
discount_denda
=
self
.
denda
...
...
@@ -64,13 +59,14 @@ class Inquiry(BaseInquiry, Common):
self
.
discount_pokok
=
self
.
discount_denda
=
0
if
self
.
tgl_bayar
<
AWAL_DISC
or
self
.
tgl_bayar
>
AKHIR_DISC
:
return
if
not
self
.
is_pst
():
if
self
.
denda
:
self
.
hitung_discount_denda
()
elif
not
self
.
is_pst
():
self
.
hitung_discount_pokok
()
self
.
hitung_discount_denda
()
self
.
discount
=
self
.
discount_pokok
+
self
.
discount_denda
def
before_save
(
self
,
bayar
):
# Override
if
not
self
.
discount
_pokok
and
not
self
.
discount_denda
:
if
not
self
.
discount
:
return
inv
=
self
.
invoice
pc
=
PenguranganCovid
(
...
...
sismiop/services/cirebon_kab.py
0 → 100644
View file @
c22f4a4
from
datetime
import
date
from
..models.kuningan
import
PembayaranSppt
from
.base
import
(
get_db_session
,
Query
,
)
from
.default
import
(
Inquiry
as
BaseInquiry
,
Reversal
as
BaseReversal
,
AvailableInvoice
as
BaseAvailableInvoice
,
)
AKHIR_DISC
=
date
(
2021
,
10
,
31
)
# Discount pokok berdasarkan bulan
NILAI_DISC
=
{
2
:
0.1
,
3
:
0.1
,
4
:
0.1
,
5
:
0.1
,
6
:
0.1
,
7
:
0.1
,
8
:
0.08
,
9
:
0.08
,
10
:
0.05
}
class
Inquiry
(
BaseInquiry
):
def
get_payment_model
(
self
):
# Override
return
PembayaranSppt
def
hitung_discount
(
self
):
# Override
self
.
discount_pokok
=
self
.
discount_denda
=
0
if
self
.
invoice
.
thn_pajak_sppt
!=
'2021'
\
or
self
.
tgl_bayar
>
AKHIR_DISC
:
return
potongan
=
NILAI_DISC
[
self
.
tgl_bayar
.
month
]
self
.
discount
=
self
.
discount_pokok
=
int
(
potongan
*
self
.
tagihan
)
def
before_save
(
self
,
payment
):
# Override
payment
.
denda_sblm_diskon
=
self
.
denda
payment
.
discount_pokok
=
self
.
discount
payment
.
discount_denda
=
0
class
Reversal
(
BaseReversal
):
def
get_payment_model
(
self
):
# Override
return
PembayaranSppt
def
before_save
(
self
):
# Override
self
.
payment
.
discount_pokok
=
0
class
AvailableInvoice
(
BaseAvailableInvoice
):
def
get_inquiry_class
(
self
):
return
Inquiry
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment