Skip to content

Commit

Permalink
[MIG] stock_batch_picking_ux: Migration to 15.0
Browse files Browse the repository at this point in the history
  • Loading branch information
augusto-weiss committed Sep 27, 2022
1 parent ca481d0 commit 9a4161c
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
4 changes: 2 additions & 2 deletions stock_batch_picking_ux/__manifest__.py
Expand Up @@ -19,7 +19,7 @@
##############################################################################
{
'name': 'Stock Usability with Batch Picking and stock vouchers',
'version': '13.0.1.3.0',
'version': "15.0.1.0.0",
'category': 'Warehouse Management',
'sequence': 14,
'summary': '',
Expand All @@ -42,7 +42,7 @@
],
'demo': [
],
'installable': False,
'installable': True,
'auto_install': True,
'application': False,
}
4 changes: 2 additions & 2 deletions stock_batch_picking_ux/models/stock_batch_picking.py
Expand Up @@ -193,7 +193,7 @@ def do_unreserve_picking(self):
self.write({'state': 'draft'})
pickings_todo.do_unreserve()

def done(self):
def action_done(self):
# limpiamos todos los pickings que no tienen cantidades hechas en lo moves
for rec in self:
picking_without_qty_done = self.env['stock.picking']
Expand All @@ -202,4 +202,4 @@ def done(self):
# Check if we need to set some qty done.
picking_without_qty_done |= picking
rec.picking_ids -= picking_without_qty_done
return super(StockPickingBatch, self.with_context(picking_batches=self)).done()
return super(StockPickingBatch, self.with_context(picking_batches=self)).action_done()
6 changes: 3 additions & 3 deletions stock_batch_picking_ux/models/stock_picking.py
Expand Up @@ -47,13 +47,13 @@ def force_transfer(self, force_qty=True):
if not pack.qty_done:
pack.unlink()

pick.do_transfer()
pick._action_done()

def action_generate_backorder_wizard(self):
def _action_generate_backorder_wizard(self, show_transfers=False):
if self._context.get('picking_batches', False):
wiz = self.env['stock.backorder.confirmation'].create({'pick_ids': [(4, p.id) for p in self]})
wiz.process()
self._context.get('picking_batches').write({'state': 'done'})
return True
else:
return super().action_generate_backorder_wizard()
return super(StockPicking)._action_generate_backorder_wizard(show_transfers=show_transfers)
1 change: 0 additions & 1 deletion stock_batch_picking_ux/report/batch_picking_list_data.xml
Expand Up @@ -9,7 +9,6 @@
<field name="in_format">oo-ods</field>
<field name="report_file">stock_batch_picking_ux/report/batch_picking_list.ods</field>
<field name="out_format" ref="report_aeroo.report_mimetypes_xls_odt"/>
<field name="parser_state">default</field>
<field name="tml_source">file</field>
<field name="binding_model_id" ref="stock_picking_batch.model_stock_picking_batch"/>
<field name="binding_type">report</field>
Expand Down

0 comments on commit 9a4161c

Please sign in to comment.