Issue 10773

Title
Do not set cost or list price without company (or warehouse)
Priority
bug
Status
resolved
Nosy list
ced, pokoli, reviewbot, roundup-bot
Assigned to
ced
Keywords
review

Created on 2021-09-21.14:36:45 by ced, last changed 1 week ago by roundup-bot.

Messages

New changeset ba2a49de3db7 by Cédric Krier in branch 'default':
Prevent editing list and cost prices without proper context
https://hg.tryton.org/tryton-env/rev/ba2a49de3db7
New changeset 7a60c89918d0 by Cédric Krier in branch 'default':
Prevent editing list and cost prices without proper context
https://hg.tryton.org/modules/stock/rev/7a60c89918d0
New changeset 53790b0b786f by Cédric Krier in branch 'default':
Prevent editing list and cost prices without proper context
https://hg.tryton.org/modules/product_cost_warehouse/rev/53790b0b786f
New changeset a131b05bbb5d by Cédric Krier in branch 'default':
Prevent editing list and cost prices without proper context
https://hg.tryton.org/modules/product/rev/a131b05bbb5d
New changeset 219d43b34ac1 by Cédric Krier in branch 'default':
Prevent editing list and cost prices without proper context
https://hg.tryton.org/modules/carrier_weight/rev/219d43b34ac1
New changeset d68f43103529 by Cédric Krier in branch 'default':
Prevent editing list and cost prices without proper context
https://hg.tryton.org/modules/carrier_percentage/rev/d68f43103529
Author: [hidden] (ced) Tryton committer Tryton translator
Date: 2021-10-03.00:26:04

Because we already store the company, it is a CompanyValue.
And the case where two companies would have the same currency and would share the same price is just a special case. I do not see the point to complexify the code just to save the creation of two records instead of one.

Author: [hidden] (pokoli) Tryton committer Tryton translator
Date: 2021-09-21.15:22:49

So why not storing the currency instead of the company?
Two companies with the same currency can share the same list price without problems.

Author: [hidden] (ced) Tryton committer Tryton translator
Date: 2021-09-21.14:36:45

The prices are linked to the company for the currency. So it makes no sense to store a price without the company.
Idem when the cost price is per warehouse.

History
Date User Action Args
2021-10-08 19:17:41roundup-botsetmessages: + msg70793
2021-10-08 19:17:33roundup-botsetmessages: + msg70792
2021-10-08 19:17:20roundup-botsetmessages: + msg70791
2021-10-08 19:17:17roundup-botsetmessages: + msg70790
2021-10-08 19:17:11roundup-botsetmessages: + msg70789
2021-10-08 19:17:05roundup-botsetmessages: + msg70788
nosy: + roundup-bot
status: testing -> resolved
2021-10-03 00:26:04cedsetmessages: + msg70565
2021-09-21 15:22:49pokolisetmessages: + msg70245
nosy: + pokoli
2021-09-21 14:59:08reviewbotsetmessages: + msg70243
nosy: + reviewbot
2021-09-21 14:38:41cedsetkeyword: + review
reviews: 338951002
status: in-progress -> testing

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