Tryton Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(289)

Issue 345051002: production_work: Show cost of production works

Can't Edit
Can't Publish+Mail
Start Review
Created:
1 year, 6 months ago by acaubet
Modified:
6 months, 1 week ago
Reviewers:
pokoli, ced, reviewbot
Visibility:
Public.

Description

Patch Set 1 #

Total comments: 6

Patch Set 2 : Use query, Fix ced and pokoli remarks #

Total comments: 7

Patch Set 3 : Fix ced remarks to improve query #

Patch Set 4 : Apply isort #

Total comments: 1

Patch Set 5 : Use Coalesce to prevent sum of null values #

Patch Set 6 : Reorder view fields #

Total comments: 3

Patch Set 7 : Fix ced remarks and update Production.get_cost #

Total comments: 2

Patch Set 8 : Simplify Production.get_cost method #

Total comments: 1

Patch Set 9 : Add missed super() call #

Total comments: 4

Patch Set 10 : Fix identation and optionals #

Patch Set 11 : Update to tip #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+45 lines, -24 lines) Patch
M CHANGELOG View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -0 lines 0 comments Download
M production.py View 1 2 3 4 5 6 7 8 9 10 1 chunk +4 lines, -24 lines 0 comments Download
M tests/scenario_production_work.rst View 1 1 chunk +4 lines, -0 lines 0 comments Download
M view/work_form.xml View 1 2 3 4 5 1 chunk +2 lines, -0 lines 0 comments Download
M view/work_list_sequence.xml View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -0 lines 0 comments Download
M work.py View 1 2 3 4 5 6 7 8 9 10 4 chunks +32 lines, -0 lines 1 comment Download

Messages

Total messages: 33
acaubet
1 year, 6 months ago (2021-11-30 16:53:45 UTC) #1
reviewbot
flake8 OK URL: https://codereview.tryton.org/345051002
1 year, 6 months ago (2021-11-30 17:00:00 UTC) #2
pokoli
We need a changelog entry Also it will be good to complete the test scenario ...
1 year, 6 months ago (2021-11-30 17:02:10 UTC) #3
ced
https://codereview.tryton.org/345051002/diff/379701002/view/work_list.xml File view/work_list.xml (right): https://codereview.tryton.org/345051002/diff/379701002/view/work_list.xml#newcode8 view/work_list.xml:8: <field name="cost"/> I'm not sure it is need on ...
1 year, 6 months ago (2021-11-30 23:09:56 UTC) #4
acaubet
Use query, Fix ced and pokoli remarks
1 year, 6 months ago (2021-12-01 08:59:28 UTC) #5
reviewbot
flake8 OK URL: https://codereview.tryton.org/345051002
1 year, 6 months ago (2021-12-01 09:32:45 UTC) #6
ced
https://codereview.tryton.org/345051002/diff/367921003/CHANGELOG File CHANGELOG (right): https://codereview.tryton.org/345051002/diff/367921003/CHANGELOG#newcode1 CHANGELOG:1: * Show cost of production works I think it ...
1 year, 5 months ago (2021-12-13 00:03:51 UTC) #7
acaubet
Fix ced remarks to improve query
1 year, 4 months ago (2022-01-21 12:49:00 UTC) #8
acaubet
Apply isort
1 year, 4 months ago (2022-01-21 12:53:17 UTC) #9
reviewbot
checks OK URL: https://codereview.tryton.org/345051002
1 year, 4 months ago (2022-01-21 13:13:23 UTC) #10
acaubet
When costs[cost] is None I recieve the following: Traceback (most recent call last): File "/trytond/wsgi.py", ...
1 year, 4 months ago (2022-01-26 14:48:09 UTC) #11
pokoli
https://codereview.tryton.org/345051002/diff/376541002/work.py File work.py (right): https://codereview.tryton.org/345051002/diff/376541002/work.py#newcode271 work.py:271: work.id, Sum(cycle.cost), you should Coalesce the cost to 0 ...
1 year, 4 months ago (2022-01-26 14:50:23 UTC) #12
acaubet
Use Coalesce to prevent sum of null values
1 year, 4 months ago (2022-02-03 16:01:11 UTC) #13
acaubet
Reorder view fields
1 year, 4 months ago (2022-02-03 16:03:31 UTC) #14
reviewbot
checks OK URL: https://codereview.tryton.org/345051002
1 year, 4 months ago (2022-02-03 16:14:03 UTC) #15
ced
I think Production.get_cost should be updated to sum the new cost of its works. https://codereview.tryton.org/345051002/diff/367921003/CHANGELOG ...
1 year, 3 months ago (2022-02-16 23:23:27 UTC) #16
acaubet
Fix ced remarks and update Production.get_cost
1 year, 2 months ago (2022-03-22 16:11:12 UTC) #17
pokoli
https://codereview.tryton.org/345051002/diff/368211002/production.py File production.py (right): https://codereview.tryton.org/345051002/diff/368211002/production.py#newcode44 production.py:44: costs = Work.get_cost(self.works) I think its easier to do: ...
1 year, 2 months ago (2022-03-22 16:16:48 UTC) #18
reviewbot
checks OK URL: https://codereview.tryton.org/345051002
1 year, 2 months ago (2022-03-22 16:27:04 UTC) #19
acaubet
Simplify Production.get_cost method
1 year, 2 months ago (2022-03-23 08:34:04 UTC) #20
reviewbot
checks OK URL: https://codereview.tryton.org/345051002
1 year, 2 months ago (2022-03-23 08:37:44 UTC) #21
pokoli
https://codereview.tryton.org/345051002/diff/368211002/production.py File production.py (right): https://codereview.tryton.org/345051002/diff/368211002/production.py#newcode43 production.py:43: cost = super(Production, self).get_cost(name) super call should not be ...
1 year, 2 months ago (2022-03-23 08:40:27 UTC) #22
acaubet
Add missed super() call
1 year, 2 months ago (2022-03-23 08:50:21 UTC) #23
reviewbot
checks OK URL: https://codereview.tryton.org/345051002
1 year, 2 months ago (2022-03-23 08:59:48 UTC) #24
ced
https://codereview.tryton.org/345051002/diff/403091003/view/work_list_sequence.xml File view/work_list_sequence.xml (right): https://codereview.tryton.org/345051002/diff/403091003/view/work_list_sequence.xml#newcode8 view/work_list_sequence.xml:8: <field name="cost"/> I would define it as optional="0" https://codereview.tryton.org/345051002/diff/403091003/work.py ...
1 year, 2 months ago (2022-04-03 17:44:58 UTC) #25
acaubet
Fix identation and optionals
1 year, 2 months ago (2022-04-05 11:58:20 UTC) #26
reviewbot
checks OK URL: https://codereview.tryton.org/345051002
1 year, 2 months ago (2022-04-05 12:07:51 UTC) #27
ced
It will be good to update the scenario to test the cost computation on work.
10 months, 3 weeks ago (2022-07-16 16:45:51 UTC) #28
acaubet
On 2022/07/16 16:45:51, ced wrote: > It will be good to update the scenario to ...
9 months, 4 weeks ago (2022-08-11 11:29:58 UTC) #29
acaubet
Update to tip
9 months, 4 weeks ago (2022-08-11 11:42:43 UTC) #30
reviewbot
checks OK URL: https://codereview.tryton.org/345051002
9 months, 4 weeks ago (2022-08-11 11:46:36 UTC) #31
ced
On 2022/08/11 11:29:58, acaubet wrote: > On 2022/07/16 16:45:51, ced wrote: > > It will ...
6 months, 1 week ago (2022-11-27 22:40:24 UTC) #32
ced
6 months, 1 week ago (2022-11-27 22:40:29 UTC) #33
https://codereview.tryton.org/345051002/diff/443461003/work.py
File work.py (right):

https://codereview.tryton.org/345051002/diff/443461003/work.py#newcode260
work.py:260: for sub_ids in grouped_slice([w.id for w in works]):
It will be better to slice the instances and after that build the list of ids.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld d9ca037-tainted