contentoh-components-library 21.1.93 → 21.1.94
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/atoms/InputFormatter/index.js +0 -1
- package/dist/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +120 -68
- package/dist/components/pages/ProviderProductEdition/index.js +4 -0
- package/dist/components/pages/RetailerProductEdition/index.js +5 -1
- package/package.json +1 -1
- package/src/components/atoms/InputFormatter/index.js +0 -1
- package/src/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +145 -77
- package/src/components/pages/ProviderProductEdition/index.js +1 -0
- package/src/components/pages/RetailerProductEdition/index.js +1 -0
|
@@ -62,7 +62,6 @@ var InputFormatter = function InputFormatter(_ref) {
|
|
|
62
62
|
var maxLength = maxChar ? maxChar : 999;
|
|
63
63
|
|
|
64
64
|
var getValue = function getValue(value) {
|
|
65
|
-
console.log(value);
|
|
66
65
|
var temp = value.replace(/\n/gm, "<br>").replace(/\&(nbsp;|amp;)/gm, " ");
|
|
67
66
|
return temp;
|
|
68
67
|
}; //const quillRef = useRef();
|
|
@@ -36,92 +36,144 @@ ProviderProductEditionDefault.args = {
|
|
|
36
36
|
category: 846,
|
|
37
37
|
version: 2,
|
|
38
38
|
productSelected: {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
description_status: "AP",
|
|
43
|
-
images_status: "ACA",
|
|
44
|
-
prio: "none",
|
|
45
|
-
version: 2,
|
|
46
|
-
brand: null,
|
|
39
|
+
articleStatus: "ACA",
|
|
40
|
+
version: 5,
|
|
41
|
+
missing: {},
|
|
47
42
|
article: {
|
|
48
|
-
category: "
|
|
49
|
-
company_name: "
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
upc: "168462"
|
|
43
|
+
category: "Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
44
|
+
company_name: "SIKA MEXICANA S.A. DE C.V.",
|
|
45
|
+
company_id: 383,
|
|
46
|
+
id_category: "2249",
|
|
47
|
+
id_article: 29457,
|
|
48
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
49
|
+
upc: "111187"
|
|
56
50
|
},
|
|
51
|
+
asignations: [],
|
|
57
52
|
retailers: [{
|
|
58
53
|
id: 58,
|
|
59
|
-
name: "The Home Depot Golden"
|
|
54
|
+
name: "The Home Depot Golden",
|
|
55
|
+
country: "México",
|
|
56
|
+
id_region: 1,
|
|
57
|
+
active: 1
|
|
58
|
+
}, {
|
|
59
|
+
id: 59,
|
|
60
|
+
name: "The Home Depot Platinum",
|
|
61
|
+
country: "México",
|
|
62
|
+
id_region: 1,
|
|
63
|
+
active: 1
|
|
64
|
+
}, {
|
|
65
|
+
id: 61,
|
|
66
|
+
name: "Home Depot TAB",
|
|
67
|
+
country: "México",
|
|
68
|
+
id_region: 1,
|
|
69
|
+
active: 1
|
|
60
70
|
}],
|
|
61
|
-
|
|
62
|
-
datasheets: 1,
|
|
63
|
-
descriptions: 1,
|
|
64
|
-
images: 1
|
|
65
|
-
},
|
|
66
|
-
statusByRetailer: {
|
|
67
|
-
58: {
|
|
68
|
-
datasheet: "AP",
|
|
69
|
-
description: "AP",
|
|
70
|
-
images: "ACA"
|
|
71
|
-
}
|
|
72
|
-
},
|
|
73
|
-
retailersWithService: ["58"],
|
|
74
|
-
id_article: 78773,
|
|
71
|
+
percentage: 33.35,
|
|
75
72
|
retailersAvailable: [{
|
|
76
73
|
id: 58,
|
|
77
|
-
name: "The Home Depot Golden"
|
|
74
|
+
name: "The Home Depot Golden",
|
|
75
|
+
country: "México",
|
|
76
|
+
id_region: 1,
|
|
77
|
+
active: 1
|
|
78
|
+
}, {
|
|
79
|
+
id: 59,
|
|
80
|
+
name: "The Home Depot Platinum",
|
|
81
|
+
country: "México",
|
|
82
|
+
id_region: 1,
|
|
83
|
+
active: 1
|
|
84
|
+
}, {
|
|
85
|
+
id: 61,
|
|
86
|
+
name: "Home Depot TAB",
|
|
87
|
+
country: "México",
|
|
88
|
+
id_region: 1,
|
|
89
|
+
active: 1
|
|
90
|
+
}],
|
|
91
|
+
upc: "111187",
|
|
92
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
93
|
+
categoryName: "Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
94
|
+
id_category: "2249",
|
|
95
|
+
id_article: 29457,
|
|
96
|
+
services: [{
|
|
97
|
+
id_article: 29457,
|
|
98
|
+
service: "datasheet",
|
|
99
|
+
quantity: 1,
|
|
100
|
+
price: 0,
|
|
101
|
+
id_user: 1237,
|
|
102
|
+
datasheet_common: null,
|
|
103
|
+
discount: null
|
|
78
104
|
}]
|
|
79
105
|
},
|
|
80
106
|
productToEdit: {
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
product: {
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
description_status: "AP",
|
|
88
|
-
images_status: "ACA",
|
|
89
|
-
prio: "none",
|
|
90
|
-
version: 2,
|
|
91
|
-
brand: null,
|
|
107
|
+
idCategory: "2249",
|
|
108
|
+
ArticleId: 29457,
|
|
109
|
+
product: [{
|
|
110
|
+
articleStatus: "ACA",
|
|
111
|
+
version: 5,
|
|
112
|
+
missing: {},
|
|
92
113
|
article: {
|
|
93
|
-
category: "
|
|
94
|
-
company_name: "
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
upc: "168462"
|
|
114
|
+
category: "Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
115
|
+
company_name: "SIKA MEXICANA S.A. DE C.V.",
|
|
116
|
+
company_id: 383,
|
|
117
|
+
id_category: "2249",
|
|
118
|
+
id_article: 29457,
|
|
119
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
120
|
+
upc: "111187"
|
|
101
121
|
},
|
|
122
|
+
asignations: [],
|
|
102
123
|
retailers: [{
|
|
103
124
|
id: 58,
|
|
104
|
-
name: "The Home Depot Golden"
|
|
125
|
+
name: "The Home Depot Golden",
|
|
126
|
+
country: "México",
|
|
127
|
+
id_region: 1,
|
|
128
|
+
active: 1
|
|
129
|
+
}, {
|
|
130
|
+
id: 59,
|
|
131
|
+
name: "The Home Depot Platinum",
|
|
132
|
+
country: "México",
|
|
133
|
+
id_region: 1,
|
|
134
|
+
active: 1
|
|
135
|
+
}, {
|
|
136
|
+
id: 61,
|
|
137
|
+
name: "Home Depot TAB",
|
|
138
|
+
country: "México",
|
|
139
|
+
id_region: 1,
|
|
140
|
+
active: 1
|
|
105
141
|
}],
|
|
106
|
-
|
|
107
|
-
datasheets: 1,
|
|
108
|
-
descriptions: 1,
|
|
109
|
-
images: 1
|
|
110
|
-
},
|
|
111
|
-
statusByRetailer: {
|
|
112
|
-
58: {
|
|
113
|
-
datasheet: "AP",
|
|
114
|
-
description: "AP",
|
|
115
|
-
images: "ACA"
|
|
116
|
-
}
|
|
117
|
-
},
|
|
118
|
-
retailersWithService: ["58"],
|
|
119
|
-
id_article: 78773,
|
|
142
|
+
percentage: 33.35,
|
|
120
143
|
retailersAvailable: [{
|
|
121
144
|
id: 58,
|
|
122
|
-
name: "The Home Depot Golden"
|
|
145
|
+
name: "The Home Depot Golden",
|
|
146
|
+
country: "México",
|
|
147
|
+
id_region: 1,
|
|
148
|
+
active: 1
|
|
149
|
+
}, {
|
|
150
|
+
id: 59,
|
|
151
|
+
name: "The Home Depot Platinum",
|
|
152
|
+
country: "México",
|
|
153
|
+
id_region: 1,
|
|
154
|
+
active: 1
|
|
155
|
+
}, {
|
|
156
|
+
id: 61,
|
|
157
|
+
name: "Home Depot TAB",
|
|
158
|
+
country: "México",
|
|
159
|
+
id_region: 1,
|
|
160
|
+
active: 1
|
|
161
|
+
}],
|
|
162
|
+
upc: "111187",
|
|
163
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
164
|
+
categoryName: "Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
165
|
+
id_category: "2249",
|
|
166
|
+
id_article: 29457,
|
|
167
|
+
services: [{
|
|
168
|
+
id_article: 29457,
|
|
169
|
+
service: "datasheet",
|
|
170
|
+
quantity: 1,
|
|
171
|
+
price: 0,
|
|
172
|
+
id_user: 1237,
|
|
173
|
+
datasheet_common: null,
|
|
174
|
+
discount: null
|
|
123
175
|
}]
|
|
124
|
-
}
|
|
176
|
+
}]
|
|
125
177
|
},
|
|
126
178
|
location: {
|
|
127
179
|
state: {
|
|
@@ -695,6 +695,10 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
695
695
|
(0, _data.fetchUsers)(token).then(function (res) {
|
|
696
696
|
return setUserGroups(res);
|
|
697
697
|
});
|
|
698
|
+
setImages({
|
|
699
|
+
action: "orderImages",
|
|
700
|
+
retailerId: activeRetailer.id
|
|
701
|
+
});
|
|
698
702
|
}, [product, version]);
|
|
699
703
|
|
|
700
704
|
var loadAssignations = function loadAssignations(currentProduct) {
|
|
@@ -618,8 +618,12 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
|
|
|
618
618
|
|
|
619
619
|
case 20:
|
|
620
620
|
setStatusArray(arr);
|
|
621
|
+
setImages({
|
|
622
|
+
action: "orderImages",
|
|
623
|
+
retailerId: activeRetailer.id
|
|
624
|
+
});
|
|
621
625
|
|
|
622
|
-
case
|
|
626
|
+
case 22:
|
|
623
627
|
case "end":
|
|
624
628
|
return _context4.stop();
|
|
625
629
|
}
|
package/package.json
CHANGED
|
@@ -21,102 +21,170 @@ ProviderProductEditionDefault.args = {
|
|
|
21
21
|
category: 846,
|
|
22
22
|
version: 2,
|
|
23
23
|
productSelected: {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
description_status: "AP",
|
|
28
|
-
images_status: "ACA",
|
|
29
|
-
prio: "none",
|
|
30
|
-
version: 2,
|
|
31
|
-
brand: null,
|
|
24
|
+
articleStatus: "ACA",
|
|
25
|
+
version: 5,
|
|
26
|
+
missing: {},
|
|
32
27
|
article: {
|
|
33
28
|
category:
|
|
34
|
-
"
|
|
35
|
-
company_name: "
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
upc: "168462",
|
|
29
|
+
"Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
30
|
+
company_name: "SIKA MEXICANA S.A. DE C.V.",
|
|
31
|
+
company_id: 383,
|
|
32
|
+
id_category: "2249",
|
|
33
|
+
id_article: 29457,
|
|
34
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
35
|
+
upc: "111187",
|
|
42
36
|
},
|
|
37
|
+
asignations: [],
|
|
43
38
|
retailers: [
|
|
44
39
|
{
|
|
45
40
|
id: 58,
|
|
46
41
|
name: "The Home Depot Golden",
|
|
42
|
+
country: "México",
|
|
43
|
+
id_region: 1,
|
|
44
|
+
active: 1,
|
|
47
45
|
},
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
statusByRetailer: {
|
|
55
|
-
58: {
|
|
56
|
-
datasheet: "AP",
|
|
57
|
-
description: "AP",
|
|
58
|
-
images: "ACA",
|
|
46
|
+
{
|
|
47
|
+
id: 59,
|
|
48
|
+
name: "The Home Depot Platinum",
|
|
49
|
+
country: "México",
|
|
50
|
+
id_region: 1,
|
|
51
|
+
active: 1,
|
|
59
52
|
},
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
53
|
+
{
|
|
54
|
+
id: 61,
|
|
55
|
+
name: "Home Depot TAB",
|
|
56
|
+
country: "México",
|
|
57
|
+
id_region: 1,
|
|
58
|
+
active: 1,
|
|
59
|
+
},
|
|
60
|
+
],
|
|
61
|
+
percentage: 33.35,
|
|
63
62
|
retailersAvailable: [
|
|
64
63
|
{
|
|
65
64
|
id: 58,
|
|
66
65
|
name: "The Home Depot Golden",
|
|
66
|
+
country: "México",
|
|
67
|
+
id_region: 1,
|
|
68
|
+
active: 1,
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
id: 59,
|
|
72
|
+
name: "The Home Depot Platinum",
|
|
73
|
+
country: "México",
|
|
74
|
+
id_region: 1,
|
|
75
|
+
active: 1,
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
id: 61,
|
|
79
|
+
name: "Home Depot TAB",
|
|
80
|
+
country: "México",
|
|
81
|
+
id_region: 1,
|
|
82
|
+
active: 1,
|
|
83
|
+
},
|
|
84
|
+
],
|
|
85
|
+
upc: "111187",
|
|
86
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
87
|
+
categoryName:
|
|
88
|
+
"Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
89
|
+
id_category: "2249",
|
|
90
|
+
id_article: 29457,
|
|
91
|
+
services: [
|
|
92
|
+
{
|
|
93
|
+
id_article: 29457,
|
|
94
|
+
service: "datasheet",
|
|
95
|
+
quantity: 1,
|
|
96
|
+
price: 0,
|
|
97
|
+
id_user: 1237,
|
|
98
|
+
datasheet_common: null,
|
|
99
|
+
discount: null,
|
|
67
100
|
},
|
|
68
101
|
],
|
|
69
102
|
},
|
|
70
103
|
productToEdit: {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
product:
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
country: null,
|
|
88
|
-
id_category: "2522",
|
|
89
|
-
id_article: 78773,
|
|
90
|
-
name: "RACK PARA ROPA DOBLE NEGRO",
|
|
91
|
-
upc: "168462",
|
|
92
|
-
},
|
|
93
|
-
retailers: [
|
|
94
|
-
{
|
|
95
|
-
id: 58,
|
|
96
|
-
name: "The Home Depot Golden",
|
|
97
|
-
},
|
|
98
|
-
],
|
|
99
|
-
services: {
|
|
100
|
-
datasheets: 1,
|
|
101
|
-
descriptions: 1,
|
|
102
|
-
images: 1,
|
|
103
|
-
},
|
|
104
|
-
statusByRetailer: {
|
|
105
|
-
58: {
|
|
106
|
-
datasheet: "AP",
|
|
107
|
-
description: "AP",
|
|
108
|
-
images: "ACA",
|
|
104
|
+
idCategory: "2249",
|
|
105
|
+
ArticleId: 29457,
|
|
106
|
+
product: [
|
|
107
|
+
{
|
|
108
|
+
articleStatus: "ACA",
|
|
109
|
+
version: 5,
|
|
110
|
+
missing: {},
|
|
111
|
+
article: {
|
|
112
|
+
category:
|
|
113
|
+
"Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
114
|
+
company_name: "SIKA MEXICANA S.A. DE C.V.",
|
|
115
|
+
company_id: 383,
|
|
116
|
+
id_category: "2249",
|
|
117
|
+
id_article: 29457,
|
|
118
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
119
|
+
upc: "111187",
|
|
109
120
|
},
|
|
121
|
+
asignations: [],
|
|
122
|
+
retailers: [
|
|
123
|
+
{
|
|
124
|
+
id: 58,
|
|
125
|
+
name: "The Home Depot Golden",
|
|
126
|
+
country: "México",
|
|
127
|
+
id_region: 1,
|
|
128
|
+
active: 1,
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
id: 59,
|
|
132
|
+
name: "The Home Depot Platinum",
|
|
133
|
+
country: "México",
|
|
134
|
+
id_region: 1,
|
|
135
|
+
active: 1,
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
id: 61,
|
|
139
|
+
name: "Home Depot TAB",
|
|
140
|
+
country: "México",
|
|
141
|
+
id_region: 1,
|
|
142
|
+
active: 1,
|
|
143
|
+
},
|
|
144
|
+
],
|
|
145
|
+
percentage: 33.35,
|
|
146
|
+
retailersAvailable: [
|
|
147
|
+
{
|
|
148
|
+
id: 58,
|
|
149
|
+
name: "The Home Depot Golden",
|
|
150
|
+
country: "México",
|
|
151
|
+
id_region: 1,
|
|
152
|
+
active: 1,
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
id: 59,
|
|
156
|
+
name: "The Home Depot Platinum",
|
|
157
|
+
country: "México",
|
|
158
|
+
id_region: 1,
|
|
159
|
+
active: 1,
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
id: 61,
|
|
163
|
+
name: "Home Depot TAB",
|
|
164
|
+
country: "México",
|
|
165
|
+
id_region: 1,
|
|
166
|
+
active: 1,
|
|
167
|
+
},
|
|
168
|
+
],
|
|
169
|
+
upc: "111187",
|
|
170
|
+
name: "SIKA TECHO FRESCO SUPER 15",
|
|
171
|
+
categoryName:
|
|
172
|
+
"Materiales de Construcción|Impermeabilizantes y Recubrimientos|Selladores",
|
|
173
|
+
id_category: "2249",
|
|
174
|
+
id_article: 29457,
|
|
175
|
+
services: [
|
|
176
|
+
{
|
|
177
|
+
id_article: 29457,
|
|
178
|
+
service: "datasheet",
|
|
179
|
+
quantity: 1,
|
|
180
|
+
price: 0,
|
|
181
|
+
id_user: 1237,
|
|
182
|
+
datasheet_common: null,
|
|
183
|
+
discount: null,
|
|
184
|
+
},
|
|
185
|
+
],
|
|
110
186
|
},
|
|
111
|
-
|
|
112
|
-
id_article: 78773,
|
|
113
|
-
retailersAvailable: [
|
|
114
|
-
{
|
|
115
|
-
id: 58,
|
|
116
|
-
name: "The Home Depot Golden",
|
|
117
|
-
},
|
|
118
|
-
],
|
|
119
|
-
},
|
|
187
|
+
],
|
|
120
188
|
},
|
|
121
189
|
location: {
|
|
122
190
|
state: { origin: "Contentoh" },
|
|
@@ -348,6 +348,7 @@ export const ProviderProductEdition = ({
|
|
|
348
348
|
loadData();
|
|
349
349
|
getCart();
|
|
350
350
|
fetchUsers(token).then((res) => setUserGroups(res));
|
|
351
|
+
setImages({ action: "orderImages", retailerId: activeRetailer.id });
|
|
351
352
|
}, [product, version]);
|
|
352
353
|
|
|
353
354
|
const loadAssignations = (currentProduct) => {
|