Merge lp:~openerp-dev/openobject-client-web/inline-list-prompt-action into lp:openobject-client-web/trunk
Proposed by
Vaibhav Darji
Status: | Rejected |
---|---|
Rejected by: | Xavier (Open ERP) |
Proposed branch: | lp:~openerp-dev/openobject-client-web/inline-list-prompt-action |
Merge into: | lp:openobject-client-web/trunk |
Diff against target: |
249 lines (+100/-75) 3 files modified
addons/openerp/static/javascript/form.js (+29/-4) addons/openerp/static/javascript/listgrid.js (+58/-64) addons/openerp/widgets/templates/listgrid.mako (+13/-7) |
To merge this branch: | bzr merge lp:~openerp-dev/openobject-client-web/inline-list-prompt-action |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Krisztian Eyssen (community) | Approve | ||
Xavier (Open ERP) (community) | Needs Fixing | ||
Review via email: mp+39436@code.launchpad.net |
Description of the change
Inline ListView Prompt action same as form view.
To post a comment you must log in.
Unmerged revisions
- 3736. By Vaibhav Darji
-
[IMP] Improved inline listgrid validation same as form.
* The validation message is terrible, what is "the record"? How is anybody going to understand that? It was OK for form, but for list is needs to be much clearer. ion(name, o2m) have become far too complex and redundant, please extract redundancies into a function
* old listgridValidat
* In validateForm, `_list_view` can not be `0` or an empty string (or id selector will fail anyway), so you don't need `_list_view != null`, `_list_view` should be enough to test that there is a list view id.
* You probably should not use `is_list_changed` (denoting a boolean value) to store the id of the modified list. Either rename key (to e.g. `modified_list`) or use two different data keys (a boolean to know if a list changed, and then a string to know *which* list changed)
-- listgrid.js
* Why async=false in listgrid save?
* Do not use alert() for errors
* If you have an id (as string) and want to turn it into a jquery id selector, there is now an `idSelector` function in openobject.dom.js, this should be used in ListView.save and in listgridValidation
* Also the `return` after $focus_field is redundant
* In listgridValidation, `0` is not a valid second parameter for parseInt, use `10`.
* jQuery.ajax can take a context keyword argument, this means the `var self=this` aliasing is now unnecessary (just pass `context: this` and in the success callback replace `self` by `this`)
Also more general comments:
* create more, smaller and more focused commits. It's easier to review and cherrypick if each commit does a single job instead of having a single big commit doing 3000 things at once. Intent of change also becomes clearer due to commit messages. You're not limited in number of commits and you don't have to pay for them so...
* Please remember to add comment if you commit/push anything new as launchpad doesn't warn reviewers