From 472b4b0aa7d499e774bfc3e1a87bed2fa5758b10 Mon Sep 17 00:00:00 2001 From: Sergio Hervas Date: Mon, 13 Feb 2023 14:30:29 +0100 Subject: [PATCH] Display and order by planned date when searching incoming moves from supplier shipment Closes #12060 --- modules/stock/shipment.py | 4 ++++ modules/stock/view/move_list_shipment_in.xml | 1 + 2 files changed, 5 insertions(+) diff --git a/modules/stock/shipment.py b/modules/stock/shipment.py index 79e5bea871..e29103c43c 100644 --- a/modules/stock/shipment.py +++ b/modules/stock/shipment.py @@ -215,6 +215,10 @@ class ShipmentIn(ShipmentMixin, Workflow, ModelSQL, ModelView): [Eval('warehouse_input', -1)], 'parent'), ('to_location', '=', Eval('warehouse_input'))), ], + search_order=[ + ('planned_date', 'ASC NULLS LAST'), + ('id', 'ASC') + ], domain=[ If(Eval('state') == 'draft', ('from_location', '=', Eval('supplier_location')), diff --git a/modules/stock/view/move_list_shipment_in.xml b/modules/stock/view/move_list_shipment_in.xml index 660bf4b2e4..6d1260fbeb 100644 --- a/modules/stock/view/move_list_shipment_in.xml +++ b/modules/stock/view/move_list_shipment_in.xml @@ -3,6 +3,7 @@ this repository contains the full copyright notices and license terms. --> +