-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Admin] Automatically check edited return items in RMA form #3904
[Admin] Automatically check edited return items in RMA form #3904
Conversation
970742a
to
05851c8
Compare
@@ -4,6 +4,10 @@ Spree.Views.Tables.ReturnItems = Backbone.View.extend({ | |||
var tfoot = document.createElement('tfoot') | |||
new Spree.Views.Tables.SelectableTable.SumReturnItemAmount({el: tfoot, model: this.model}); | |||
this.$el.append(tfoot); | |||
|
|||
this.$el.find('input, select').not('.add-item').on('change', function(e) { | |||
$(this).closest('tr').find('input.add-item').prop('checked', true).change(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Expected line break before .change
newline-per-chained-call
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@spaghetticode thanks, looking good. The only comment I have is that the PR title/commit message could maybe describe what is being changed a bit better — it isn't 100% clear that this is affecting the RMA flow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this change.
This feature got lost with solidusio#3565. It automatically checks rows where the admin changes something, under the assumption that, if a value is changed, then the user means to include the row into the RMA/return. An integration spec is added to properly track this feature.
05851c8
to
3c5e610
Compare
Merging, the only failing spec is already addressed in master. |
This feature got lost with #3565. It automatically checks rows where the admin changes something, under the assumption that, if a value is changed, then the user means to include the row into the RMA/return.
An integration spec is added to properly track this feature.
Checklist: