# Customer shipments and packing

**URL:** <https://discuss.tryton.org/t/customer-shipments-and-packing/3228>\
**Category:** Developer\
**Tags:** stock\
**Created:** [September 17, 2020, 1:41pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228 "2020-09-17T13:41:10Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![maxx](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/maxx/32/2320_2.png) [@maxx](https://discuss.tryton.org/u/maxx)\
**Post date:** [September 17, 2020, 1:41pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228/1 "2020-09-17T13:41:11Z")

</div>

Hi,  
I’ll try to illustrate a problem discussed yesterday on irc ([IRC logs of #tryton for Wednesday, 2020-09-16](https://www.tryton.org/~irclog/2020-09-16.log.html)).  
It concerns customer shipments and packing. In our case, we are using lots.  
Here’s the screen with the inventory moves:

 ![2020-09-16_14-40](https://discuss-cdn.tryton.org/uploads/default/original/2X/a/a068730e15832356b9641ba7173d25b86b81c063.png)  
And the screen with the outgoing moves which is similar to the inventory moves in state “Waiting”:  
 ![2020-09-16_14-41](https://discuss-cdn.tryton.org/uploads/default/original/2X/8/8002adaa2b7af168f035429186503290a5254586.png)

We click on “assign” or “Manual Assign”, state is now “Assigned” and “From Location” and “Lot” field are updated with the datas “where and which product/lot to pick”:

 ![2020-09-16_16-19](https://discuss-cdn.tryton.org/uploads/default/original/2X/8/838714ed8d2628abfc334d24162d9abf27d368c4.png)

Outgoing moves stay unchanged:

 ![2020-09-16_16-19_1](https://discuss-cdn.tryton.org/uploads/default/original/2X/b/b21c4896d91a160c7c9c99d4c7a07c2c21fa44bb.png)

Until there nothing special. Strange part is about packing.  
I would then doing packing on my picking list. So i’m clicking on the “+” on the packages list. I’m selecting package type:

 ![2020-09-16_16-21](https://discuss-cdn.tryton.org/uploads/default/original/2X/b/bb36b22007dbcb495cd5ddbd1f203eee24e75759.png)  
And now i would like to associate some lines of my picking list with specific lots number to this package but only the outgoing moves (which are not updated following my inventory moves) are available for association with the package:  
 ![2020-09-16_16-20](https://discuss-cdn.tryton.org/uploads/default/original/2X/a/a9c087924e9b5582f9ca2bfd9fe4f0a6990b3761.png)  
Those outgoing moves are updated after clicking on “Make Shipment” (but then it is no more possible to edit packages).

This synchronization is made with [http://hg.tryton.org/modules/stock/file/tip/shipment.py#l1218](http://hg.tryton.org/modules/stock/file/tip/shipment.py#l1218)  
which is called on workflow events “Assign” and “Pack”. But for the “assign” workflow nothing seems updated by this method.

For us it seems important to know which lots are in a specific package. To know for example lots number 1,2,3 & 4 are on pallet 1, etc… But to do such thing we have to edit also outgoing moves as duplicate of inventory moves before packing. Should tryton have an intermediate state “picked” in the workflow between assigned and before packed to allow to select the correct moves for the packing ? When clicking on the “Pick” button inventory moves would be synced on outgoing moves and packing would possible only in the state “picked”. What do you think ?

---

<div class="post-metadata">

**Author:** ![tbruyere](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/tbruyere/32/37_2.png) [@tbruyere](https://discuss.tryton.org/u/tbruyere)\
**Post date:** [September 25, 2020, 12:55pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228/2 "2020-09-25T12:55:14Z")

</div>

When you use the “lot” module and the “move split” module and you have to take several different lots in stock for an order, you cannot manage the packages without losing the origin of the exit movement on the internal movement. Explanation by an example.

Sale of 3 units of product A.  
Creation of an internal movement of 3 units of product A  
Split of the internal movement into 3 lines because 3 lot number is necessary.  
Manually modification of the output movements with a 3 line split with manual indication of the “lot” number.  
Internal movements lose their “origin” because the exit movement was destroyed during the split. I can now manage the packages.  
If I want to synchronize internal movements to external movements, I lose the ability to manage packets because synchronization is done during shipping.

---

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [September 25, 2020, 12:59pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228/3 "2020-09-25T12:59:00Z")

</div>

> [@maxx](#):
>
> Should tryton have an intermediate state “picked” in the workflow between assigned and before packed to allow to select the correct moves for the packing ?

It make sense but only when using packaging (the stock\_package module is activated).

Do you think it’s possible to have this module activated but have a shipment that is not packaged? If so we should probably define a flag to define if the shipment requires packages or not and require only this step if the flag is set. Probably this flag should be always true for base modules but allow to be overriden on custom modules.

---

<div class="post-metadata">

**Author:** ![maxx](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/maxx/32/2320_2.png) [@maxx](https://discuss.tryton.org/u/maxx)\
**Post date:** [September 25, 2020, 1:05pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228/4 "2020-09-25T13:05:29Z")

</div>

Here’s an issue to add this extra step in shipment out workflow:

> **[Add new state before packing in shipment out workflow (#9634) · Issues ·...](https://foss.heptapod.net/tryton/tryton/-/issues/9634)**
>
> Following discuss https://discuss.tryton.org/t/customer-shipments-and-packing/3228 It seems necessary to add a new workflow step to sync inventory moves before packing in shipment out process....

> [@pokoli](#):
>
> It make sense but only when using packaging (the stock\_package module is activated).

That’s what i thought, but the “pack” step exists in the shipment\_out module and stock\_package module overload this step. Waiting for comments to update code to solve all shipments cases 🙂

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [September 25, 2020, 2:00pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228/5 "2020-09-25T14:00:38Z")

</div>

> [@pokoli](#):
>
> It make sense but only when using packaging (the stock\_package module is activated).

I do not agree. If you have an output location, you need the three steps pick, pack, ship even if you do not register in the system the packaging.

---

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [September 25, 2020, 2:29pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228/6 "2020-09-25T14:29:17Z")

</div>

> [@ced](#):
>
> If you have an output location, you need the three steps pick, pack, ship even if you do not register in the system the packaging.

But currently the case is that “pick and pack” is done in the same step (when the pack button is clicked).

So probably we can keep the same behaviour to keep a simpler workflow for the ones that does not require this features.

It’s just a mather of hidding the pick button when there is no packaging and sync moves on both buttons.

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [September 25, 2020, 2:31pm UTC](https://discuss.tryton.org/t/customer-shipments-and-packing/3228/7 "2020-09-25T14:31:02Z")

</div>

> [@pokoli](#):
>
> So probably we can keep the same behaviour to keep a simpler workflow for the ones that does not require this features.

Those should not use an outgoing location.
