diff --git a/delivery_package_number/__manifest__.py b/delivery_package_number/__manifest__.py index 28e1b21afc..88abb166fd 100644 --- a/delivery_package_number/__manifest__.py +++ b/delivery_package_number/__manifest__.py @@ -10,13 +10,14 @@ "license": "AGPL-3", "installable": True, "application": False, - "depends": ["delivery"], + "depends": ["delivery", "stock_delivery"], "data": [ "security/ir.model.access.csv", "data/paperformat_data.xml", "reports/report_package_number.xml", "views/stock_picking_type_views.xml", "views/stock_picking_views.xml", + "wizard/stock_backorder_confirmation_views.xml", "wizard/stock_number_package_validate_wiz_view.xml", ], } diff --git a/delivery_package_number/tests/test_delivery_package_number.py b/delivery_package_number/tests/test_delivery_package_number.py index e2de1a07b7..aa1f891323 100644 --- a/delivery_package_number/tests/test_delivery_package_number.py +++ b/delivery_package_number/tests/test_delivery_package_number.py @@ -28,13 +28,13 @@ def setUpClass(cls): { "product_id": cls.product.id, "product_uom_id": cls.product.uom_id.id, - "qty_done": 5, + "quantity": 5, "location_id": cls.wh1.lot_stock_id.id, "location_dest_id": cls.wh1.wh_output_stock_loc_id.id, "picking_id": cls.picking.id, } ) - cls.ml2 = cls.ml1.copy({"qty_done": 0}) + cls.ml2 = cls.ml1.copy({"quantity": 0}) def test_number_of_packages(self): # By default it's computed to 0 @@ -47,7 +47,7 @@ def test_number_of_packages(self): # We add a package and it recalculates self.picking.action_put_in_pack() self.assertEqual(self.picking.number_of_packages, 1) - self.ml2.qty_done = 5 + self.ml2.quantity = 5 self.picking.action_put_in_pack() self.assertEqual(self.picking.number_of_packages, 2) # We can later set it manually if we want to @@ -64,7 +64,7 @@ def test_backorder(self): order = order_form.save() order.action_confirm() picking = order.picking_ids - picking.move_ids.quantity_done = 2 + picking.move_ids.quantity = 2 picking.number_of_packages = 2 action = picking.with_context( test_delivery_package_number=True diff --git a/delivery_package_number/views/stock_picking_views.xml b/delivery_package_number/views/stock_picking_views.xml index 6a717b4106..d2ebeb7f51 100644 --- a/delivery_package_number/views/stock_picking_views.xml +++ b/delivery_package_number/views/stock_picking_views.xml @@ -2,14 +2,14 @@ stock.picking - + - + diff --git a/delivery_package_number/wizard/__init__.py b/delivery_package_number/wizard/__init__.py index 0c0e9106ee..adb752bf71 100644 --- a/delivery_package_number/wizard/__init__.py +++ b/delivery_package_number/wizard/__init__.py @@ -1,3 +1,3 @@ -from . import stock_inmediate_transfer +from . import stock_number_package_mixin from . import stock_backorder_confirmation from . import stock_number_package_validate_wiz diff --git a/delivery_package_number/wizard/stock_backorder_confirmation_views.xml b/delivery_package_number/wizard/stock_backorder_confirmation_views.xml index c91240fd2b..b3e47ac45b 100644 --- a/delivery_package_number/wizard/stock_backorder_confirmation_views.xml +++ b/delivery_package_number/wizard/stock_backorder_confirmation_views.xml @@ -7,7 +7,7 @@ - + @@ -15,11 +15,11 @@ diff --git a/delivery_package_number/wizard/stock_immediate_transfer_views.xml b/delivery_package_number/wizard/stock_immediate_transfer_views.xml deleted file mode 100644 index 936bf5af0d..0000000000 --- a/delivery_package_number/wizard/stock_immediate_transfer_views.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - stock.immediate.transfer - - - - - - - - - - - - - -