summaryrefslogtreecommitdiff
path: root/indoteknik_api/models
diff options
context:
space:
mode:
authorAzka Nathan <darizkyfaz@gmail.com>2025-04-30 10:15:35 +0700
committerAzka Nathan <darizkyfaz@gmail.com>2025-04-30 10:15:35 +0700
commit475173ec46981926aa90e99f796e38ef1d46b61e (patch)
tree7a60d68b1dc779ecd031187eaadfed0c94de597d /indoteknik_api/models
parent840bc3f8c04933a56a31c279ef6e220c277bd36d (diff)
sequence pricelist and fix bug validation invoice date and date doc kirim
Diffstat (limited to 'indoteknik_api/models')
-rw-r--r--indoteknik_api/models/product_pricelist.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/indoteknik_api/models/product_pricelist.py b/indoteknik_api/models/product_pricelist.py
index 3ba38940..e0debf38 100644
--- a/indoteknik_api/models/product_pricelist.py
+++ b/indoteknik_api/models/product_pricelist.py
@@ -106,14 +106,13 @@ class ProductPricelist(models.Model):
else:
is_show_program = False
-
current_time = datetime.now().strftime('%Y-%m-%d %H:%M:%S')
pricelist = self.search([
('is_flash_sale', '=', True),
('is_show_program', '=', is_show_program),
('start_date', '<=', current_time),
('end_date', '>=', current_time)
- ], order='start_date asc')
+ ], order='number asc')
return pricelist
def is_flash_sale_product(self, product_id: int):