Spaces:
Sleeping
Sleeping
jonathanjordan21
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -92,21 +92,21 @@ vehicle_tax_info = {
|
|
92 |
"type": "SUV",
|
93 |
"tanggal": "23 Desember 2024",
|
94 |
"status": "Belum Bayar",
|
95 |
-
"harga_jual":
|
96 |
},
|
97 |
"B 5678 XYZ": {
|
98 |
"no_rangka": "9876543210",
|
99 |
"type": "Sedan",
|
100 |
"tanggal": "15 Januari 2025",
|
101 |
"status": "Belum Bayar",
|
102 |
-
"harga_jual":
|
103 |
},
|
104 |
"D 3456 DEF": {
|
105 |
"no_rangka": "4561237890",
|
106 |
"type": "MPV",
|
107 |
"tanggal": "10 Februari 2025",
|
108 |
"status": "Sudah Bayar",
|
109 |
-
"harga_jual":
|
110 |
}
|
111 |
}
|
112 |
|
@@ -207,16 +207,18 @@ def build_output(result, description, result_detail, plate_number):
|
|
207 |
|
208 |
|
209 |
def build_outputs(results, descriptions, result_details, plate_number):
|
210 |
-
out = "--------------------------------------------------"
|
211 |
vehicle = vehicle_tax_info.get(plate_number)
|
|
|
|
|
212 |
out = "\nPlate Number: " + plate_number + "\n"
|
213 |
out += "\n".join([k + " : " + str(v) for k,v in vehicle.items()])
|
214 |
-
|
215 |
out += "\n----------------------------------------------"
|
|
|
216 |
out += f"\nWajib Pajak dengan NoPol {plate_number} ingin melakukan proses berikut:\n"
|
217 |
|
218 |
for i, (res,desc,detail) in enumerate(zip(results, descriptions, result_details)):
|
219 |
-
|
|
|
220 |
|
221 |
out += "----------------------------\nEstimasi biaya: "
|
222 |
|
|
|
92 |
"type": "SUV",
|
93 |
"tanggal": "23 Desember 2024",
|
94 |
"status": "Belum Bayar",
|
95 |
+
"harga_jual": 500_000_000 # In Rupiah
|
96 |
},
|
97 |
"B 5678 XYZ": {
|
98 |
"no_rangka": "9876543210",
|
99 |
"type": "Sedan",
|
100 |
"tanggal": "15 Januari 2025",
|
101 |
"status": "Belum Bayar",
|
102 |
+
"harga_jual": 375_800_000 # In Rupiah
|
103 |
},
|
104 |
"D 3456 DEF": {
|
105 |
"no_rangka": "4561237890",
|
106 |
"type": "MPV",
|
107 |
"tanggal": "10 Februari 2025",
|
108 |
"status": "Sudah Bayar",
|
109 |
+
"harga_jual": 400_000_000 # In Rupiah
|
110 |
}
|
111 |
}
|
112 |
|
|
|
207 |
|
208 |
|
209 |
def build_outputs(results, descriptions, result_details, plate_number):
|
|
|
210 |
vehicle = vehicle_tax_info.get(plate_number)
|
211 |
+
|
212 |
+
out = "--------------------------------------------------"
|
213 |
out = "\nPlate Number: " + plate_number + "\n"
|
214 |
out += "\n".join([k + " : " + str(v) for k,v in vehicle.items()])
|
|
|
215 |
out += "\n----------------------------------------------"
|
216 |
+
|
217 |
out += f"\nWajib Pajak dengan NoPol {plate_number} ingin melakukan proses berikut:\n"
|
218 |
|
219 |
for i, (res,desc,detail) in enumerate(zip(results, descriptions, result_details)):
|
220 |
+
harga_jual = vehicle.get("harga_jual")
|
221 |
+
out += f"{i+1}. {detail}\nDetail perhitungan: {desc.replace('harga_jual', harga_jual)} = {res}\n"
|
222 |
|
223 |
out += "----------------------------\nEstimasi biaya: "
|
224 |
|