Skip to content

Commit

Permalink
[Karthi] | BUG | Refactor. Negative Qty Disabled in Batchwise interna… (
Browse files Browse the repository at this point in the history
#136)

* [Karthi] | BUG | Refactor. Negative Qty Disabled in Batchwise internal transfer

* [Karthi] | BUG | Refactor. Negative Qty Disabled in Batchwise internal transfer
  • Loading branch information
karthikeyansp91 authored Apr 2, 2024
1 parent eef5f7d commit eac99c8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bahmni_stock/models/stock_picking.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ def button_validate(self):
ctx.pop('default_immediate_transfer', None)
self = self.with_context(ctx)
### Internal Transfer Batch based code write
if ctx['default_picking_type_id']:
stock_picking_type = self.env['stock.picking.type'].search([('id','=', ctx['default_picking_type_id'])])
if self.picking_type_id:
stock_picking_type = self.env['stock.picking.type'].search([('id','=', self.picking_type_id.id)])
if stock_picking_type.code == 'internal':
for line in self.move_line_ids:
if line.product_id.tracking != 'none':
Expand Down

0 comments on commit eac99c8

Please sign in to comment.