Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(91)

Issue 4253070: Dynamically change M2O selection widget according to domain (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years, 11 months ago by nicoe
Modified:
14 years, 10 months ago
Reviewers:
ced
Visibility:
Public.

Patch Set 1 #

Total comments: 2

Patch Set 2 : Empty content when not found #

Total comments: 2

Patch Set 3 : 80 character changes + remove last_key #

Total comments: 2

Patch Set 4 : separate selection computation use domain_get #

Total comments: 5

Patch Set 5 : Correctly handle domain & handle exception #

Patch Set 6 : Use args of common.process_exception #

Total comments: 1

Patch Set 7 : Added False line #

Total comments: 4

Patch Set 8 : Do not "not" the return of process_exception #

Unified diffs Side-by-side diffs Delta from patch set Stats (+50 lines, -40 lines) Patch
M CHANGELOG View 1 2 3 4 5 6 7 1 chunk +2 lines, -0 lines 0 comments Download
M tryton/common/domain_inversion.py View 1 2 3 4 5 6 7 2 chunks +6 lines, -4 lines 0 comments Download
M tryton/gui/window/view_form/model/field.py View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M tryton/gui/window/view_form/view/form_gtk/selection.py View 1 2 3 4 5 6 7 3 chunks +41 lines, -35 lines 0 comments Download

Messages

Total messages: 19
nicoe
14 years, 11 months ago (2011-03-09 17:30:49 UTC) #1
ced
http://codereview.appspot.com/4253070/diff/1/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/1/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode41 tryton/gui/window/view_form/view/form_gtk/selection.py:41: def update_selection(self, record=None): You must add a cache on ...
14 years, 11 months ago (2011-03-09 17:55:06 UTC) #2
nicoe
http://codereview.appspot.com/4253070/diff/1/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/1/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode41 tryton/gui/window/view_form/view/form_gtk/selection.py:41: def update_selection(self, record=None): On 2011/03/09 17:55:07, ced wrote: > ...
14 years, 11 months ago (2011-03-11 13:19:15 UTC) #3
ced
http://codereview.appspot.com/4253070/diff/5001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/5001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode39 tryton/gui/window/view_form/view/form_gtk/selection.py:39: self.last_key = (None, 0) Could be removed http://codereview.appspot.com/4253070/diff/5001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode58 tryton/gui/window/view_form/view/form_gtk/selection.py:58: ...
14 years, 11 months ago (2011-03-11 13:27:29 UTC) #4
ced
http://codereview.appspot.com/4253070/diff/10001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/10001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode50 tryton/gui/window/view_form/view/form_gtk/selection.py:50: domain = PYSONDecoder(context).decode(self.attrs.get('domain')) Call self.field.domain_get Then you can remove ...
14 years, 11 months ago (2011-03-14 09:28:04 UTC) #5
ced
http://codereview.appspot.com/4253070/diff/10001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/10001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode51 tryton/gui/window/view_form/view/form_gtk/selection.py:51: if domain == self._last_domain: This test should be done ...
14 years, 11 months ago (2011-03-14 09:29:34 UTC) #6
nicoe
14 years, 11 months ago (2011-03-14 10:40:59 UTC) #7
ced
http://codereview.appspot.com/4253070/diff/16001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/16001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode9 tryton/gui/window/view_form/view/form_gtk/selection.py:9: from tryton.common import EvalEnvironment No more needed http://codereview.appspot.com/4253070/diff/16001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode75 tryton/gui/window/view_form/view/form_gtk/selection.py:75: ...
14 years, 11 months ago (2011-03-14 10:55:23 UTC) #8
nicoe
14 years, 11 months ago (2011-03-14 11:04:07 UTC) #9
nicoe
14 years, 11 months ago (2011-03-14 11:21:23 UTC) #10
ced
http://codereview.appspot.com/4253070/diff/19002/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/19002/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode71 tryton/gui/window/view_form/view/form_gtk/selection.py:71: selection = [(x['id'], x['rec_name']) for x in result] Could ...
14 years, 11 months ago (2011-03-14 11:37:07 UTC) #11
nicoe
14 years, 11 months ago (2011-03-14 14:03:18 UTC) #12
ced
LGTM
14 years, 11 months ago (2011-03-14 14:14:46 UTC) #13
nicoe
http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode60 tryton/gui/window/view_form/view/form_gtk/selection.py:60: domain = self.field.domain_get(record) Pay attention to localization of the ...
14 years, 11 months ago (2011-03-15 16:28:35 UTC) #14
nicoe
Done in anothe patch set: http://codereview.appspot.com/4277063 http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode60 tryton/gui/window/view_form/view/form_gtk/selection.py:60: domain = self.field.domain_get(record) ...
14 years, 11 months ago (2011-03-18 14:01:15 UTC) #15
ced
http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode69 tryton/gui/window/view_form/view/form_gtk/selection.py:69: result = not common.process_exception(exception, self.window, args) The return value ...
14 years, 10 months ago (2011-03-25 10:18:06 UTC) #16
nicoe
http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py File tryton/gui/window/view_form/view/form_gtk/selection.py (right): http://codereview.appspot.com/4253070/diff/22001/tryton/gui/window/view_form/view/form_gtk/selection.py#newcode69 tryton/gui/window/view_form/view/form_gtk/selection.py:69: result = not common.process_exception(exception, self.window, args) On 2011/03/25 10:18:06, ...
14 years, 10 months ago (2011-03-29 09:55:02 UTC) #17
nicoe
14 years, 10 months ago (2011-03-29 09:55:42 UTC) #18
ced
14 years, 10 months ago (2011-03-29 12:59:29 UTC) #19
LGTM
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b