Tryton - Issues

 

Message57362

Author pokoli
Recipients
Date 2020-04-21.17:51:52
Content
We've found some strange bug on sao today that make the product of an invoice disapear after after creating a line with it. 

Here are the steps to reproduce:

1. Create a product with a new line on it. This can be done using tryton but only copypasting some text with newline on it. You will see that on Tryton an arrow is shown to represent the newline.
2. Go to sao and create a new invoice line using this product.
3. After saving the invoice the product disapears from the form.

(same procedure works as expected on tryton)

This is because the name of the product is compared with the input value [1] but the newline value is not present on the html widget, so the field is removed. 

We've found it with products that are not created from the user interface but importing an external file (which contained the new line characters). I consider this a corner case out of the normal usage but I'm also reporting this bug to see if we can do something to prevent that the many2one field is cleared.



[1] https://hg.tryton.org/sao/file/0e779982f8ba/src/view/form.js#l2417
History
Date User Action Args
2020-04-21 17:51:53pokolisetmessageid: <1587484313.68.0.938128438643.issue9248@tryton.org>
2020-04-21 17:51:53pokolilinkissue9248 messages
2020-04-21 17:51:52pokolicreate

Showing 10 items. Show all history (warning: this could be VERY long)