Tryton - Issues



Title Client does not refresh sequence in tree view
Priority bug Status resolved
Superseder Nosy List adrien.benduc, ced, jcavallo, reviewbot, roundup-bot
Type behavior Components tryton
Assigned To ced Keywords review
Reviews 34921002
View: 34921002

Created on 2017-04-13.10:49:38 by adrien.benduc, last changed by roundup-bot.

New changeset 9446d3650c92 by C?dric Krier in branch 'default':
Set sequence also when using product on One2Many
review34921002 updated at
msg33357 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2017-04-22.01:17:24
It should be fixed by review34921002
msg33230 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2017-04-13.15:59:34
I have been confused by the "Product variable" description in msg33218, I thought you were talking about the Product model and never your were talking about the product operation.
So yes, tryton is missing a call to set the sequence after adding the product result.
sao is not really affected because it does not have yet support for sequence.
msg33229 (view) Author: [hidden] (adrien.benduc) Date: 2017-04-13.15:12:11
I try, but the scenario is not easy to explain.
I'm talking about the product feature because, as I sait previously,
Main model [A] has a One2Many (using PRODUCT feature) on a model [B] witch the target Many2One [C] is the PRODUCT.
So when I add a new record in my One2Many list, sequence is not SET, and thanks to your Hint about Group.set_sequence,
I realized, that in my case, using the product feature, the update_sequence is never called.

Juste to be sure we are talking about the same thing:
product: Only for One2Many fields, a comma separated list of target field name used to create records from the cartesian product.
msg33227 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2017-04-13.14:30:39
Please be precise and consistent in your communications.
Why are you talking now about the product feature?
What is the defecting behaviour you have?
msg33226 (view) Author: [hidden] (adrien.benduc) Date: 2017-04-13.14:23:20
As far as I can see, the sequence is never updated in case of new product (One2Many._new_product) unlike One2Many._new_single which update it.
Maybe we should do the same ?
msg33221 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2017-04-13.12:29:29
The sequence is not necessary set, it really depends, check Group.set_sequence.
So if the order when saving is the expected one, for me there is no issue.
msg33220 (view) Author: [hidden] (adrien.benduc) Date: 2017-04-13.12:01:21
I mean:
I create a new record from the A model view, by clicking on the "+" of the One2Many field.

So if the default order sequence is set to None, it is only when the first drag and drop occurs that all the sequences are set ?
msg33219 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2017-04-13.11:33:28
The scenario is not clear.
Which "new record from the [A]" are you talking about?
Also sequence field are by default set to None.
msg33218 (view) Author: [hidden] (adrien.benduc) Date: 2017-04-13.10:49:38
The case is the following:

We have a One2Many which point on an intermerdiary table.
This intermediary table has a Many2One on the "Product" variable.

Here is a more visualizable schema:

|main model| [A] => One2Many |intermediary model| [B] => Many2One |produt| [C]

The Form view of [A] defines the One2Many field with a "tree,form" view and [B] is tree editable. 
The Form view of [A] also defines the product on the field One2Many (which is the Many2One [C])
In this very special case, the sequence field defined on [B] used to order records is not set when I create a new record from the [A] form view.
Date User Action Args
2017-04-29 10:31:48roundup-botsetstatus: testing -> resolved
nosy: + roundup-bot
messages: + msg33494
2017-04-22 01:38:02reviewbotsetnosy: + reviewbot
messages: + msg33359
2017-04-22 01:17:24cedsetstatus: chatting -> testing
reviews: 34921002
messages: + msg33357
keyword: + review
assignedto: ced
2017-04-13 15:59:34cedsetstatus: need-eg -> chatting
messages: + msg33230
2017-04-13 15:12:11adrien.benducsetmessages: + msg33229
2017-04-13 14:30:40cedsetmessages: + msg33227
2017-04-13 14:23:20adrien.benducsetmessages: + msg33226
2017-04-13 12:29:38cedsettitle: tryton: Client does not refresh sequence in tree view -> Client does not refresh sequence in tree view
2017-04-13 12:29:29cedsetmessages: + msg33221
2017-04-13 12:01:21adrien.benducsetmessages: + msg33220

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