From 2638a9fbfe29520e5be0b88810208f5232aaac7b Mon Sep 17 00:00:00 2001 From: Azka Nathan Date: Thu, 26 Sep 2024 10:10:25 +0700 Subject: cr purchase pricelist --- indoteknik_custom/models/purchase_pricelist.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indoteknik_custom/models/purchase_pricelist.py b/indoteknik_custom/models/purchase_pricelist.py index b5f719cb..e5b35d7f 100755 --- a/indoteknik_custom/models/purchase_pricelist.py +++ b/indoteknik_custom/models/purchase_pricelist.py @@ -24,7 +24,6 @@ class PurchasePricelist(models.Model): count_brand_vendor = fields.Integer(string='Count Brand Vendor') is_winner = fields.Boolean(string='Winner', default=False, help='Pemenang yang direkomendasikan oleh Merchandise') - @api.constrains('include_price') def sync_pricelist_tier(self): for rec in self: promotion_product = self.env['promotion.product'].search([('product_id', '=', rec.product_id.id)]) @@ -119,5 +118,6 @@ class PurchasePricelist(models.Model): tier_prod_pricelist = self.env['product.pricelist.item'].search(product_domain + [('pricelist_id', '=', tier_pricelist.id)], limit=1) tier_prod_pricelist.price_discount = tier_perc + rec.sync_pricelist_tier() rec.product_id.product_tmpl_id._create_solr_queue('_sync_price_to_solr') \ No newline at end of file -- cgit v1.2.3