File tree Expand file tree Collapse file tree 3 files changed +19
-19
lines changed
GroupedProduct/view/frontend/web/js
Wishlist/view/frontend/web/js Expand file tree Collapse file tree 3 files changed +19
-19
lines changed Original file line number Diff line number Diff line change @@ -88,23 +88,21 @@ define([
88
88
*/
89
89
_parseQueryParams : function ( queryString ) {
90
90
var queryParams = $ . parseQuery ( {
91
- query : queryString
92
- } ) ;
93
- var form = this . element ,
91
+ query : queryString
92
+ } ) ,
93
+ form = this . element ,
94
94
options = $ ( this . options . productBundleSelector , form ) ,
95
95
qtys = $ ( this . options . qtyFieldSelector , form ) ;
96
96
97
97
$ . each ( queryParams , $ . proxy ( function ( key , value ) {
98
- options . each ( function ( index , option ) {
99
- if ( option . name === key ) {
100
- $ ( option ) . val ( value ) . change ( ) ;
101
- $ ( option ) . attr ( 'value' , value ) ;
98
+ options . each ( function ( index , option ) {
99
+ if ( option . name === key ) {
100
+ $ ( option ) . val ( value ) ;
102
101
}
103
102
} ) ;
104
- qtys . each ( function ( index , qty ) {
103
+ qtys . each ( function ( index , qty ) {
105
104
if ( qty . name === key ) {
106
105
$ ( qty ) . val ( value ) ;
107
- $ ( qty ) . attr ( 'value' , value ) ;
108
106
}
109
107
} ) ;
110
108
} , this ) ) ;
Original file line number Diff line number Diff line change 6
6
'jquery' ,
7
7
'underscore' ,
8
8
'jquery-ui-modules/widget' ,
9
- 'jquery/jquery.parsequery' ,
10
- ] , function ( $ , _ ) {
9
+ 'jquery/jquery.parsequery'
10
+ ] , function ( $ ) {
11
11
'use strict' ;
12
12
13
13
$ . widget ( 'mage.groupedProduct' , {
@@ -46,19 +46,20 @@ define([
46
46
*/
47
47
_parseQueryParams : function ( queryString ) {
48
48
var queryParams = $ . parseQuery ( {
49
- query : queryString
50
- } ) ;
51
- var form = this . element ,
49
+ query : queryString
50
+ } ) ,
51
+ form = this . element ,
52
52
qtyNameSelector = this . options . qtyNameSelector ,
53
53
qtys = $ ( this . options . qtySelector , form ) ;
54
54
55
55
$ . each ( queryParams , $ . proxy ( function ( key , value ) {
56
- qtys . each ( function ( index , qty ) {
56
+ qtys . each ( function ( index , qty ) {
57
57
var nameSelector = qtyNameSelector . concat ( '[' , key , ']' ) ;
58
- if ( qty . name === nameSelector ) {
59
- $ ( qty ) . attr ( 'value' , value ) ;
58
+
59
+ if ( qty . name === nameSelector ) {
60
+ $ ( qty ) . val ( value ) ;
60
61
}
61
- } )
62
+ } ) ;
62
63
} , this ) ) ;
63
64
}
64
65
} ) ;
Original file line number Diff line number Diff line change @@ -71,7 +71,8 @@ define([
71
71
72
72
$ ( this . options . qtyInfo ) . trigger ( 'change' ) ;
73
73
for ( key in this . options . productType ) {
74
- if ( this . options . productType . hasOwnProperty ( key ) && this . options . productType [ key ] + 'Info' in this . options ) {
74
+ if ( this . options . productType . hasOwnProperty ( key )
75
+ && this . options . productType [ key ] + 'Info' in this . options ) {
75
76
$ ( this . options [ this . options . productType [ key ] + 'Info' ] ) . trigger ( 'change' ) ;
76
77
}
77
78
}
You can’t perform that action at this time.
0 commit comments