Skip to content

Commit

Permalink
BAH-4006 | Fix. Digit precision for lot specific price details (#177)
Browse files Browse the repository at this point in the history
  • Loading branch information
mohan-13 authored Jul 8, 2024
1 parent 73b3ed5 commit b4192a4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions bahmni_stock/models/stock_move_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
class StockMoveLine(models.Model):
_inherit = 'stock.move.line'

sale_price = fields.Float(string="Sale Price")
mrp = fields.Float(string="MRP")
cost_price = fields.Float(string="Cost Price")
sale_price = fields.Float(string="Sale Price", digits='Product Price')
mrp = fields.Float(string="MRP", digits='Product Price')
cost_price = fields.Float(string="Cost Price", digits='Product Price')
balance = fields.Float(string="Balance")
existing_lot_id = fields.Many2one(
'stock.lot', 'Lot/Serial Number',
Expand Down
6 changes: 3 additions & 3 deletions bahmni_stock/models/stock_production_lot.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,9 @@ def _get_future_stock_forecast(self):
product_uom = self.env['product.uom'].browse(product_uom_id)
lot.stock_forecast = result[0].get('sum') * product_uom.factor

sale_price = fields.Float(string="Sale Price")
mrp = fields.Float(string="MRP")
cost_price = fields.Float(string="Cost Price")
sale_price = fields.Float(string="Sale Price", digits='Product Price')
mrp = fields.Float(string="MRP", digits='Product Price')
cost_price = fields.Float(string="Cost Price", digits='Product Price')
stock_forecast = fields.Float(string="Available forecast",
compute=_get_future_stock_forecast,store=True,
digits=dp.get_precision('Product Unit of Measure'),
Expand Down

0 comments on commit b4192a4

Please sign in to comment.