Created on 2021-07-20.16:06:57 by bernatnan, last changed 2 months ago by acaubet.
> > No this will miss the point of the check. Shipping product without an > origin is a bad practice as it is missing the workflow of the sale or > purchase. > You are right. Will be better your solution.
On 2021-07-20 17:10, Bernat Brunet wrote: > Another solution may be could be fill the origin of the new move with the > 'stock.move,ID' of the original move and this will avoid the missing origin > warning. No this will miss the point of the check. Shipping product without an origin is a bad practice as it is missing the workflow of the sale or purchase.
Missatge de Cédric Krier <bugs@tryton.org> del dia dt., 20 de jul. 2021 a les 17:00: > > Cédric Krier <cedric.krier@b2ck.com> added the comment: > > On 2021-07-20 16:30, Bernat Brunet wrote: > > I have created Product01 and make an inventory of 100 units. > > You have a shipment in return (id:2) with 150 units and if you try to > Assign, appear the loop origin warning. > > Indeed it happens when Move.assign_try create a new move to be assigned. > So on each run it is a new id that is used for this new move. > I think we should find a way to distinct new records in Warning_.format > so we use another value than the id to build the key. > I think to distinct we could the `Transaction.create_records` and to > replace the id we could use the value of the fields excepted for binary. > Another solution may be could be fill the origin of the new move with the 'stock.move,ID' of the original move and this will avoid the missing origin warning. > ______________________________________ > Tryton issue tracker <bugs@tryton.org> > <https://bugs.tryton.org/issue10591> > ______________________________________ > -- Bernat Brunet Tel. (+34) 935 531 803 <https://www.nan-tic.com/en/news/> <http://twitter.com/nan_tic> <https://www.linkedin.com/company/nan-tic/> Pot consultar la informació sobre el tractament que realitzem de les dades de caràcter personal de conformitat amb l’article 11 LOPD aquí <https://www.nan-tic.com/lopd>.
On 2021-07-20 16:30, Bernat Brunet wrote: > I have created Product01 and make an inventory of 100 units. > You have a shipment in return (id:2) with 150 units and if you try to Assign, appear the loop origin warning. Indeed it happens when Move.assign_try create a new move to be assigned. So on each run it is a new id that is used for this new move. I think we should find a way to distinct new records in Warning_.format so we use another value than the id to build the key. I think to distinct we could the `Transaction.create_records` and to replace the id we could use the value of the fields excepted for binary.
Reproduced on demo.tryton.org (it redirect to https://demo6.0.tryton.org)
I have created Product01 and make an inventory of 100 units.
You have a shipment in return (id:2) with 150 units and if you try to Assign, appear the loop origin warning.
Can not reproduce on demo.tryton.org.
Such infinite warning loop happens if the assigned move was created during the assignation. But for supplier shipment return there is no such creation.
Need to have installed purchase and stock modules.
For example, Product01 have 100 units of stock.
- Try to create a shipment in return manually of 150 units of the Product01, for error.
- When try to assign the shipment, first, appear the warning about the move has not origin.
- If you say YES to proceed, it enter in a loop appearing continuously the same warning, and never appear the warning about stock it's not enough.
History | |||
---|---|---|---|
Date | User | Action | Args |
2022-06-01 15:50:46 | acaubet | set | nosy: + acaubet |
2022-06-01 15:41:29 | ced | link | issue11536 superseder |
2022-02-05 10:06:55 | ced | set | component: - stock, purchase |
2021-10-27 22:20:49 | ced | set | title: Missing origin loop when assign on stock shipment in return -> Support warning keys of newly created record |
2021-07-20 17:27:08 | bernatnan | set | messages: + msg68956 |
2021-07-20 17:21:05 | ced | set | messages: + msg68955 |
2021-07-20 17:10:10 | bernatnan | set | messages: + msg68954 |
2021-07-20 17:00:06 | ced | set | messages: + msg68953 |
2021-07-20 16:30:45 | bernatnan | set | messages:
+ msg68952 status: need-eg -> chatting |
2021-07-20 16:13:49 | ced | set | messages:
+ msg68951 nosy: + ced status: chatting -> need-eg |
Showing 10 items. Show all history (warning: this could be VERY long)