contentoh-components-library 21.4.7 → 21.4.8

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.
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
@@ -7,12 +7,16 @@ Object.defineProperty(exports, "__esModule", {
7
7
  });
8
8
  exports.default = exports.ProviderProductEditionDefault = void 0;
9
9
 
10
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
11
+
10
12
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
11
13
 
12
14
  var _index = require("./index");
13
15
 
14
16
  var _jsxRuntime = require("react/jsx-runtime");
15
17
 
18
+ var _productSelected;
19
+
16
20
  var _default = {
17
21
  title: "Components/pages/ProviderProductEdition",
18
22
  component: _index.ProviderProductEdition
@@ -35,53 +39,17 @@ ProviderProductEditionDefault.args = {
35
39
  articleId: 238,
36
40
  category: 846,
37
41
  version: 2,
38
- productSelected: {
39
- orderId: 15142,
40
- status: "AA",
41
- datasheet_status: "AA",
42
- prio: "none",
43
- version: 3,
44
- description_status: "AA",
45
- images_status: "AA",
46
- brand: "Garnier",
47
- retailerOrder: 0,
48
- missing: {
49
- datasheet: null,
50
- descriptions: null,
51
- images: null
52
- },
53
- services: {
54
- datasheets: 1,
55
- descriptions: 1,
56
- images: 1
57
- },
58
- article: {
59
- category: "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores",
60
- company_name: "GRUPO BRAHMA",
61
- country: "México",
62
- id_category: "697",
63
- id_datasheet_especialist: 54,
64
- id_datasheet_facilitator: 52,
65
- id_description_especialist: 54,
66
- id_description_facilitator: 52,
67
- id_images_especialist: 55,
68
- id_images_facilitator: 53,
69
- id_order: 15142,
70
- id_article: 39270,
71
- id_auditor: 37,
72
- name: "Acondicionador Garnier Fructis 650 ml",
73
- timestamp: "2023-03-27T18:37:48.000Z",
74
- upc: "750955287656712"
75
- },
76
- retailers: [{
77
- id: 12,
78
- name: "La Comer"
79
- }, {
80
- id: 29,
81
- name: "Farmacias del Ahorro"
82
- }, {
83
- id: 63,
84
- name: "DAX"
42
+ productSelected: (_productSelected = {
43
+ id_article: 43,
44
+ id_category: 2126,
45
+ name: "LIMA CERRAJERO 6 PULGADAS ACERO BELLOTA",
46
+ upc: "137915",
47
+ timestamp: "2022-11-14T16:03:56.000Z",
48
+ categoryName: "Herramientas|Herramientas Manuales|Herramientas de Corte y Desbaste",
49
+ version: 1,
50
+ retailersAvailable: [{
51
+ name: "The Home Depot Golden",
52
+ id: 58
85
53
  }],
86
54
  statusByRetailer: {
87
55
  12: {
@@ -100,106 +68,34 @@ ProviderProductEditionDefault.args = {
100
68
  images: "AA"
101
69
  }
102
70
  },
103
- checked: false,
104
- retailersAvailable: [{
105
- id: 12,
106
- name: "La Comer"
107
- }, {
108
- id: 29,
109
- name: "Farmacias del Ahorro"
110
- }, {
111
- id: 63,
112
- name: "DAX"
113
- }],
114
- categoryName: "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores",
115
- upc: "750955287656712",
116
- id_article: 39270,
117
- id_order: 15142
118
- },
71
+ checked: false
72
+ }, (0, _defineProperty2.default)(_productSelected, "retailersAvailable", [{
73
+ id: 12,
74
+ name: "La Comer"
75
+ }, {
76
+ id: 29,
77
+ name: "Farmacias del Ahorro"
78
+ }, {
79
+ id: 63,
80
+ name: "DAX"
81
+ }]), (0, _defineProperty2.default)(_productSelected, "categoryName", "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores"), (0, _defineProperty2.default)(_productSelected, "upc", "750955287656712"), (0, _defineProperty2.default)(_productSelected, "id_article", 39270), (0, _defineProperty2.default)(_productSelected, "id_order", 15142), _productSelected),
119
82
  productToEdit: {
120
- ArticleId: 39270,
121
- idCategory: "697",
122
- product: {
123
- orderId: 15142,
124
- status: "AA",
125
- datasheet_status: "AA",
126
- prio: "none",
127
- version: 3,
128
- description_status: "AA",
129
- images_status: "AA",
130
- brand: "Garnier",
131
- retailerOrder: 0,
132
- missing: {
133
- datasheet: null,
134
- descriptions: null,
135
- images: null
136
- },
137
- services: {
138
- datasheets: 1,
139
- descriptions: 1,
140
- images: 1
141
- },
142
- article: {
143
- category: "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores",
144
- company_name: "GRUPO BRAHMA",
145
- country: "México",
146
- id_category: "697",
147
- id_datasheet_especialist: 54,
148
- id_datasheet_facilitator: 52,
149
- id_description_especialist: 54,
150
- id_description_facilitator: 52,
151
- id_images_especialist: 55,
152
- id_images_facilitator: 53,
153
- id_order: 15142,
154
- id_article: 39270,
155
- id_auditor: 37,
156
- name: "Acondicionador Garnier Fructis 650 ml",
157
- timestamp: "2023-03-27T18:37:48.000Z",
158
- upc: "750955287656712"
159
- },
160
- retailers: [{
161
- id: 12,
162
- name: "La Comer"
163
- }, {
164
- id: 29,
165
- name: "Farmacias del Ahorro"
166
- }, {
167
- id: 63,
168
- name: "DAX"
169
- }],
170
- statusByRetailer: {
171
- 12: {
172
- datasheet: "AA",
173
- description: "AA",
174
- images: "AA"
175
- },
176
- 29: {
177
- datasheet: "AA",
178
- description: "AA",
179
- images: "AA"
180
- },
181
- 63: {
182
- datasheet: "AA",
183
- description: "AA",
184
- images: "AA"
185
- }
186
- },
187
- checked: false,
83
+ idCategory: 2126,
84
+ ArticleId: 43,
85
+ product: [{
86
+ id_article: 43,
87
+ id_category: 2126,
88
+ name: "LIMA CERRAJERO 6 PULGADAS ACERO BELLOTA",
89
+ upc: "137915",
90
+ timestamp: "2022-11-14T16:03:56.000Z",
91
+ categoryName: "Herramientas|Herramientas Manuales|Herramientas de Corte y Desbaste",
92
+ version: 1,
188
93
  retailersAvailable: [{
189
- id: 12,
190
- name: "La Comer"
191
- }, {
192
- id: 29,
193
- name: "Farmacias del Ahorro"
194
- }, {
195
- id: 63,
196
- name: "DAX"
197
- }],
198
- categoryName: "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores",
199
- upc: "750955287656712",
200
- id_article: 39270,
201
- id_order: 15142
202
- }
94
+ name: "The Home Depot Golden",
95
+ id: 58,
96
+ percentage: 2
97
+ }]
98
+ }]
203
99
  },
204
100
  location: {
205
101
  pathname: "/EditProducts",
@@ -244,7 +140,7 @@ ProviderProductEditionDefault.args = {
244
140
  products_limit: "5000",
245
141
  type: "Enterprise"
246
142
  },
247
- src: "https://content-management-profile.s3.amazonaws.com/id-28/28.png?1683926822779"
143
+ src: "https://content-management-profile.s3.amazonaws.com/id-28/28.png?1691179745418"
248
144
  },
249
145
  company: {
250
146
  id_company: 1,
@@ -259,11 +155,8 @@ ProviderProductEditionDefault.args = {
259
155
  email: null,
260
156
  social_link: "",
261
157
  is_retailer: 0,
262
- retailers: [{
263
- id: null,
264
- name: null,
265
- country: null
266
- }]
158
+ financedRetailers: [],
159
+ retailers: []
267
160
  },
268
161
  showSurvey: function showSurvey(v) {
269
162
  return v && alert("se muestra");
@@ -1178,29 +1178,30 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
1178
1178
  res = _context11.sent;
1179
1179
 
1180
1180
  if (!(res.data.statusCode === 200)) {
1181
- _context11.next = 11;
1181
+ _context11.next = 12;
1182
1182
  break;
1183
1183
  }
1184
1184
 
1185
+ setUpdatedDescriptions([]);
1185
1186
  setMessage("Descripciones guardadas con éxito");
1186
- _context11.next = 11;
1187
+ _context11.next = 12;
1187
1188
  return loadData();
1188
1189
 
1189
- case 11:
1190
- _context11.next = 16;
1190
+ case 12:
1191
+ _context11.next = 17;
1191
1192
  break;
1192
1193
 
1193
- case 13:
1194
- _context11.prev = 13;
1194
+ case 14:
1195
+ _context11.prev = 14;
1195
1196
  _context11.t0 = _context11["catch"](3);
1196
1197
  console.log(_context11.t0);
1197
1198
 
1198
- case 16:
1199
+ case 17:
1199
1200
  case "end":
1200
1201
  return _context11.stop();
1201
1202
  }
1202
1203
  }
1203
- }, _callee11, null, [[3, 13]]);
1204
+ }, _callee11, null, [[3, 14]]);
1204
1205
  }));
1205
1206
 
1206
1207
  return function saveDescriptions() {
@@ -1233,29 +1234,30 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
1233
1234
  res = _context12.sent;
1234
1235
 
1235
1236
  if (!(res.data.statusCode === 200)) {
1236
- _context12.next = 11;
1237
+ _context12.next = 12;
1237
1238
  break;
1238
1239
  }
1239
1240
 
1241
+ setUpdatedDatasheets([]);
1240
1242
  setMessage("Fichas técnicas guardadas");
1241
- _context12.next = 11;
1243
+ _context12.next = 12;
1242
1244
  return loadData();
1243
1245
 
1244
- case 11:
1245
- _context12.next = 16;
1246
+ case 12:
1247
+ _context12.next = 17;
1246
1248
  break;
1247
1249
 
1248
- case 13:
1249
- _context12.prev = 13;
1250
+ case 14:
1251
+ _context12.prev = 14;
1250
1252
  _context12.t0 = _context12["catch"](3);
1251
1253
  console.log(_context12.t0);
1252
1254
 
1253
- case 16:
1255
+ case 17:
1254
1256
  case "end":
1255
1257
  return _context12.stop();
1256
1258
  }
1257
1259
  }
1258
- }, _callee12, null, [[3, 13]]);
1260
+ }, _callee12, null, [[3, 14]]);
1259
1261
  }));
1260
1262
 
1261
1263
  return function saveDatasheets() {
@@ -1389,7 +1391,7 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
1389
1391
  switch (_context14.prev = _context14.next) {
1390
1392
  case 0:
1391
1393
  if (!imagesUploaded) {
1392
- _context14.next = 16;
1394
+ _context14.next = 17;
1393
1395
  break;
1394
1396
  }
1395
1397
 
@@ -1413,30 +1415,31 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
1413
1415
  res = _context14.sent;
1414
1416
 
1415
1417
  if (!(res.data.statusCode === 200)) {
1416
- _context14.next = 11;
1418
+ _context14.next = 12;
1417
1419
  break;
1418
1420
  }
1419
1421
 
1422
+ setImages({});
1420
1423
  setMessage("Imágenes guardadas con éxito");
1421
1424
  sessionStorage.removeItem("imagesList");
1422
- _context14.next = 11;
1425
+ _context14.next = 12;
1423
1426
  return loadData();
1424
1427
 
1425
- case 11:
1426
- _context14.next = 16;
1428
+ case 12:
1429
+ _context14.next = 17;
1427
1430
  break;
1428
1431
 
1429
- case 13:
1430
- _context14.prev = 13;
1432
+ case 14:
1433
+ _context14.prev = 14;
1431
1434
  _context14.t0 = _context14["catch"](2);
1432
1435
  console.log(_context14.t0);
1433
1436
 
1434
- case 16:
1437
+ case 17:
1435
1438
  case "end":
1436
1439
  return _context14.stop();
1437
1440
  }
1438
1441
  }
1439
- }, _callee14, null, [[2, 13]]);
1442
+ }, _callee14, null, [[2, 14]]);
1440
1443
  })), [dataImages, imagesUploaded]);
1441
1444
 
1442
1445
  var getConcept = function getConcept(tab) {
@@ -7,16 +7,12 @@ Object.defineProperty(exports, "__esModule", {
7
7
  });
8
8
  exports.default = exports.RetailerProductEditionDefault = void 0;
9
9
 
10
- var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
11
-
12
10
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
13
11
 
14
12
  var _index = require("./index");
15
13
 
16
14
  var _jsxRuntime = require("react/jsx-runtime");
17
15
 
18
- var _productSelected;
19
-
20
16
  var _default = {
21
17
  title: "Components/pages/RetailerProductEdition",
22
18
  component: _index.RetailerProductEdition
@@ -36,76 +32,59 @@ RetailerProductEditionDefault.args = {
36
32
  Imágenes: false
37
33
  },
38
34
  token: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiI5YTIxMzEyOC02NDgyLTRjMTYtYTRiNi02ZTY0ZjIyNWIxYmQiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6IjlhMjEzMTI4LTY0ODItNGMxNi1hNGI2LTZlNjRmMjI1YjFiZCIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiI5OGE0NzYxMy04ZGIyLTRlZjUtYjA0Mi01ZDU3MWRkZjIwMWIiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY4Mzg3NTIyNiwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY4Mzg3ODgyNiwiaWF0IjoxNjgzODc1MjI2LCJlbWFpbCI6ImlzbWFlbDk3bG9wZXpAZ21haWwuY29tIn0.EtgmT_THMx-Zy_zB5yZK4gz6TXNTVVJEKFt5X0JK2UkGVrp_q_92YCEuejS4n976fyTez0jkwOee6IkVHLV71uZWRBDFt-3Yw4ZxfsZYPNJWhoHXGNxhMU8MCkSntfu597esBTk-VsUpstT5R7L-WJfN8viE7R-qVo-42RlPTG0TFrWA9q0oTcqjv8vbxLpOBUjiEpjmqRhg4blJZwgkGNta6MOlw1vfmisOVbo9wMvqwnCZ9xx9KMKoH9U4uNObK_JomjbvPmTmkcUXsE-wGSD7XcoSwtuhBngLC7-jiu1u8MvL_ff5Z0Qp70sSpLdUglcSS8d1Xf7j_fcZuJ5jKA",
39
- productSelected: (_productSelected = {
40
- orderId: 14606,
41
- status: "RA",
42
- datasheet_status: "RA",
35
+ productSelected: {
36
+ services: {
37
+ datasheets: 1,
38
+ descriptions: 1,
39
+ images: 1
40
+ },
41
+ orderId: 15275,
42
+ status: "AC",
43
+ datasheet_status: "AC",
43
44
  prio: "none",
44
45
  version: 3,
45
- description_status: "RA",
46
- images_status: "RA",
46
+ description_status: "AC",
47
+ images_status: "AC",
47
48
  statusByRetailer: {
48
- 4: {
49
- datasheet: "RA/AC",
50
- description: "RA/AC",
51
- images: "RA/AC"
52
- },
53
- 5: {
54
- datasheet: "RA/AC",
55
- description: "RA/AC",
56
- images: "RA/AC"
57
- },
58
- 6: {
59
- description: "RA/AC",
60
- images: "RA/AC",
61
- datasheet: "RA/AC"
62
- },
63
- 12: {
64
- datasheet: "RA/AC",
65
- description: "RA/AC",
66
- images: "RA/AC"
67
- },
68
- 17: {
69
- datasheet: "RA/AC",
70
- description: "RA/AC",
71
- images: "RA/AC"
49
+ 34: {
50
+ datasheet: "AC",
51
+ description: "AC",
52
+ images: "AC"
72
53
  }
73
- }
74
- }, (0, _defineProperty2.default)(_productSelected, "orderId", 15209), (0, _defineProperty2.default)(_productSelected, "status", "ACA"), (0, _defineProperty2.default)(_productSelected, "datasheet_status", "ACA"), (0, _defineProperty2.default)(_productSelected, "prio", "none"), (0, _defineProperty2.default)(_productSelected, "version", 3), (0, _defineProperty2.default)(_productSelected, "description_status", "ACA"), (0, _defineProperty2.default)(_productSelected, "images_status", "ACA"), (0, _defineProperty2.default)(_productSelected, "statusByRetailer", {
75
- 70: {
76
- datasheet: "ACA",
77
- description: "ACA",
78
- images: "ACA"
79
- }
80
- }), (0, _defineProperty2.default)(_productSelected, "article", {
81
- id_article: 39390,
82
- id_category: "4311",
83
- name: "test demo 1",
84
- upc: "2312312313",
85
- timestamp: "2023-05-12T20:07:42.000Z",
86
- id_user: 133,
87
- status: "NULL",
88
- active: 1,
89
- company_id: 912,
90
- company_name: "GRUPO BRAHMA",
54
+ },
55
+ article: {
56
+ id_article: 39485,
57
+ id_category: "11",
58
+ name: "Mix de nueces",
59
+ upc: "7543453453",
60
+ timestamp: "2023-07-14T21:02:54.000Z",
61
+ id_user: 28,
62
+ status: "NULL",
63
+ active: 1,
64
+ company_id: 1,
65
+ company_name: "GRUPO BRAHMA",
66
+ country: "México",
67
+ id_order: 15275,
68
+ id_datasheet_especialist: 54,
69
+ id_datasheet_facilitator: 52,
70
+ id_description_especialist: 54,
71
+ id_description_facilitator: 52,
72
+ id_images_especialist: 55,
73
+ id_images_facilitator: 53,
74
+ id_auditor: 37,
75
+ id_recepcionist: null,
76
+ category: "Abarrotes|Abarrotes Secos|Frutos Secos",
77
+ missingAttributes: 0,
78
+ missingDescriptions: 0,
79
+ missingImages: 0
80
+ },
81
+ retailers: [{
82
+ id: 34,
83
+ name: "San Pablo"
84
+ }],
91
85
  country: "México",
92
- id_order: 15209,
93
- id_datasheet_especialist: 232,
94
- id_datasheet_facilitator: 52,
95
- id_description_especialist: 232,
96
- id_description_facilitator: 52,
97
- id_images_especialist: 196,
98
- id_images_facilitator: 53,
99
- id_auditor: 195,
100
- id_recepcionist: null,
101
- category: "Ropa Interior Dama|Ropa Interior|Ropa Interior",
102
- missingAttributes: 0,
103
- missingDescriptions: 0,
104
- missingImages: 0
105
- }), (0, _defineProperty2.default)(_productSelected, "retailers", [{
106
- id: 70,
107
- name: "Bodega Aurrera"
108
- }]), _productSelected),
86
+ upc: "7543453453"
87
+ },
109
88
  location: {
110
89
  product: {
111
90
  articleId: 354,
@@ -117,22 +96,22 @@ RetailerProductEditionDefault.args = {
117
96
  }
118
97
  },
119
98
  user: {
120
- id_user: 51,
121
- name: "ADMIN PRUEBA",
122
- last_name: "",
123
- email: "etc@contentoh.com",
124
- position: "",
99
+ id_user: 37,
100
+ name: "José",
101
+ last_name: "Castañeda",
102
+ email: "ismael97lopez@gmail.com",
103
+ position: "Auditor",
125
104
  telephone: "",
126
- country: "",
105
+ country: "México",
127
106
  id_company: 2,
128
- id_cognito: "a6c4d3d6-24a4-41d4-ad0f-d087438ab5b6",
107
+ id_cognito: "9a213128-6482-4c16-a4b6-6e64f225b1bd",
129
108
  birth_Date: null,
130
109
  about_me: "",
131
110
  zip_code: "",
132
111
  address: "",
133
112
  job: "",
134
113
  id_stripe: "",
135
- id_role: 1,
114
+ id_role: 6,
136
115
  active: 1,
137
116
  is_retailer: 0,
138
117
  email_notify: 1,
@@ -148,6 +127,6 @@ RetailerProductEditionDefault.args = {
148
127
  products_limit: "3",
149
128
  type: "PyMES"
150
129
  },
151
- src: "https://content-management-profile.s3.amazonaws.com/id-51/51.png?1682016291518"
130
+ src: "https://content-management-profile.s3.amazonaws.com/id-37/37.png?1691175586149"
152
131
  }
153
132
  };
@@ -891,7 +891,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
891
891
  });
892
892
 
893
893
  if (!(dataClean.length > 0)) {
894
- _context7.next = 25;
894
+ _context7.next = 26;
895
895
  break;
896
896
  }
897
897
 
@@ -915,7 +915,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
915
915
  res = _context7.sent;
916
916
 
917
917
  if (!(res.data.statusCode === 200)) {
918
- _context7.next = 20;
918
+ _context7.next = 21;
919
919
  break;
920
920
  }
921
921
 
@@ -924,25 +924,26 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
924
924
  if (newStatus) productTemp.description_status = newStatus;
925
925
  setProduct(productTemp);
926
926
  sessionStorage.setItem("productSelected", JSON.stringify(productTemp));
927
+ setUpdatedDescriptions([]);
927
928
  setMessage("Descripciones guardadas con éxito");
928
- _context7.next = 20;
929
+ _context7.next = 21;
929
930
  return loadData();
930
931
 
931
- case 20:
932
- _context7.next = 25;
932
+ case 21:
933
+ _context7.next = 26;
933
934
  break;
934
935
 
935
- case 22:
936
- _context7.prev = 22;
936
+ case 23:
937
+ _context7.prev = 23;
937
938
  _context7.t0 = _context7["catch"](7);
938
939
  console.log(_context7.t0);
939
940
 
940
- case 25:
941
+ case 26:
941
942
  case "end":
942
943
  return _context7.stop();
943
944
  }
944
945
  }
945
- }, _callee7, null, [[7, 22]]);
946
+ }, _callee7, null, [[7, 23]]);
946
947
  }));
947
948
 
948
949
  return function saveDescriptions() {
@@ -963,7 +964,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
963
964
  });
964
965
 
965
966
  if (!(dataClean.length > 0)) {
966
- _context8.next = 25;
967
+ _context8.next = 26;
967
968
  break;
968
969
  }
969
970
 
@@ -987,7 +988,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
987
988
  res = _context8.sent;
988
989
 
989
990
  if (!(res.data.statusCode === 200)) {
990
- _context8.next = 20;
991
+ _context8.next = 21;
991
992
  break;
992
993
  }
993
994
 
@@ -996,25 +997,26 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
996
997
  if (newStatus) productTemp.datasheet_status = newStatus;
997
998
  setProduct(productTemp);
998
999
  sessionStorage.setItem("productSelected", JSON.stringify(productTemp));
1000
+ setUpdatedDatasheets([]);
999
1001
  setMessage("Fichas técnicas guardadas");
1000
- _context8.next = 20;
1002
+ _context8.next = 21;
1001
1003
  return loadData();
1002
1004
 
1003
- case 20:
1004
- _context8.next = 25;
1005
+ case 21:
1006
+ _context8.next = 26;
1005
1007
  break;
1006
1008
 
1007
- case 22:
1008
- _context8.prev = 22;
1009
+ case 23:
1010
+ _context8.prev = 23;
1009
1011
  _context8.t0 = _context8["catch"](7);
1010
1012
  console.log(_context8.t0);
1011
1013
 
1012
- case 25:
1014
+ case 26:
1013
1015
  case "end":
1014
1016
  return _context8.stop();
1015
1017
  }
1016
1018
  }
1017
- }, _callee8, null, [[7, 22]]);
1019
+ }, _callee8, null, [[7, 23]]);
1018
1020
  }));
1019
1021
 
1020
1022
  return function saveDatasheets() {
@@ -1166,7 +1168,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1166
1168
  switch (_context10.prev = _context10.next) {
1167
1169
  case 0:
1168
1170
  if (!imagesUploaded) {
1169
- _context10.next = 22;
1171
+ _context10.next = 23;
1170
1172
  break;
1171
1173
  }
1172
1174
 
@@ -1190,7 +1192,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1190
1192
  res = _context10.sent;
1191
1193
 
1192
1194
  if (!(res.data.statusCode === 200)) {
1193
- _context10.next = 17;
1195
+ _context10.next = 18;
1194
1196
  break;
1195
1197
  }
1196
1198
 
@@ -1200,26 +1202,27 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1200
1202
  if (newStatus) productTemp.images_status = newStatus;
1201
1203
  setProduct(productTemp);
1202
1204
  sessionStorage.setItem("productSelected", JSON.stringify(productTemp));
1205
+ setImages({});
1203
1206
  setMessage("Imágenes guardadas con éxito");
1204
1207
  sessionStorage.removeItem("imagesList");
1205
- _context10.next = 17;
1208
+ _context10.next = 18;
1206
1209
  return loadData();
1207
1210
 
1208
- case 17:
1209
- _context10.next = 22;
1211
+ case 18:
1212
+ _context10.next = 23;
1210
1213
  break;
1211
1214
 
1212
- case 19:
1213
- _context10.prev = 19;
1215
+ case 20:
1216
+ _context10.prev = 20;
1214
1217
  _context10.t0 = _context10["catch"](2);
1215
1218
  console.log(_context10.t0);
1216
1219
 
1217
- case 22:
1220
+ case 23:
1218
1221
  case "end":
1219
1222
  return _context10.stop();
1220
1223
  }
1221
1224
  }
1222
- }, _callee10, null, [[2, 19]]);
1225
+ }, _callee10, null, [[2, 20]]);
1223
1226
  })), [dataImages, imagesUploaded]);
1224
1227
 
1225
1228
  var evaluationFinished = function evaluationFinished(userId, tab, statusArray) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "contentoh-components-library",
3
- "version": "21.4.7",
3
+ "version": "21.4.8",
4
4
  "dependencies": {
5
5
  "@aws-amplify/auth": "^4.5.3",
6
6
  "@aws-amplify/datastore": "^3.11.0",
@@ -21,56 +21,18 @@ ProviderProductEditionDefault.args = {
21
21
  category: 846,
22
22
  version: 2,
23
23
  productSelected: {
24
- orderId: 15142,
25
- status: "AA",
26
- datasheet_status: "AA",
27
- prio: "none",
28
- version: 3,
29
- description_status: "AA",
30
- images_status: "AA",
31
- brand: "Garnier",
32
- retailerOrder: 0,
33
- missing: {
34
- datasheet: null,
35
- descriptions: null,
36
- images: null,
37
- },
38
- services: {
39
- datasheets: 1,
40
- descriptions: 1,
41
- images: 1,
42
- },
43
- article: {
44
- category:
45
- "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores",
46
- company_name: "GRUPO BRAHMA",
47
- country: "México",
48
- id_category: "697",
49
- id_datasheet_especialist: 54,
50
- id_datasheet_facilitator: 52,
51
- id_description_especialist: 54,
52
- id_description_facilitator: 52,
53
- id_images_especialist: 55,
54
- id_images_facilitator: 53,
55
- id_order: 15142,
56
- id_article: 39270,
57
- id_auditor: 37,
58
- name: "Acondicionador Garnier Fructis 650 ml",
59
- timestamp: "2023-03-27T18:37:48.000Z",
60
- upc: "750955287656712",
61
- },
62
- retailers: [
63
- {
64
- id: 12,
65
- name: "La Comer",
66
- },
67
- {
68
- id: 29,
69
- name: "Farmacias del Ahorro",
70
- },
24
+ id_article: 43,
25
+ id_category: 2126,
26
+ name: "LIMA CERRAJERO 6 PULGADAS ACERO BELLOTA",
27
+ upc: "137915",
28
+ timestamp: "2022-11-14T16:03:56.000Z",
29
+ categoryName:
30
+ "Herramientas|Herramientas Manuales|Herramientas de Corte y Desbaste",
31
+ version: 1,
32
+ retailersAvailable: [
71
33
  {
72
- id: 63,
73
- name: "DAX",
34
+ name: "The Home Depot Golden",
35
+ id: 58,
74
36
  },
75
37
  ],
76
38
  statusByRetailer: {
@@ -112,99 +74,27 @@ ProviderProductEditionDefault.args = {
112
74
  id_order: 15142,
113
75
  },
114
76
  productToEdit: {
115
- ArticleId: 39270,
116
- idCategory: "697",
117
- product: {
118
- orderId: 15142,
119
- status: "AA",
120
- datasheet_status: "AA",
121
- prio: "none",
122
- version: 3,
123
- description_status: "AA",
124
- images_status: "AA",
125
- brand: "Garnier",
126
- retailerOrder: 0,
127
- missing: {
128
- datasheet: null,
129
- descriptions: null,
130
- images: null,
131
- },
132
- services: {
133
- datasheets: 1,
134
- descriptions: 1,
135
- images: 1,
136
- },
137
- article: {
138
- category:
139
- "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores",
140
- company_name: "GRUPO BRAHMA",
141
- country: "México",
142
- id_category: "697",
143
- id_datasheet_especialist: 54,
144
- id_datasheet_facilitator: 52,
145
- id_description_especialist: 54,
146
- id_description_facilitator: 52,
147
- id_images_especialist: 55,
148
- id_images_facilitator: 53,
149
- id_order: 15142,
150
- id_article: 39270,
151
- id_auditor: 37,
152
- name: "Acondicionador Garnier Fructis 650 ml",
153
- timestamp: "2023-03-27T18:37:48.000Z",
154
- upc: "750955287656712",
155
- },
156
- retailers: [
157
- {
158
- id: 12,
159
- name: "La Comer",
160
- },
161
- {
162
- id: 29,
163
- name: "Farmacias del Ahorro",
164
- },
165
- {
166
- id: 63,
167
- name: "DAX",
168
- },
169
- ],
170
- statusByRetailer: {
171
- 12: {
172
- datasheet: "AA",
173
- description: "AA",
174
- images: "AA",
175
- },
176
- 29: {
177
- datasheet: "AA",
178
- description: "AA",
179
- images: "AA",
180
- },
181
- 63: {
182
- datasheet: "AA",
183
- description: "AA",
184
- images: "AA",
185
- },
77
+ idCategory: 2126,
78
+ ArticleId: 43,
79
+ product: [
80
+ {
81
+ id_article: 43,
82
+ id_category: 2126,
83
+ name: "LIMA CERRAJERO 6 PULGADAS ACERO BELLOTA",
84
+ upc: "137915",
85
+ timestamp: "2022-11-14T16:03:56.000Z",
86
+ categoryName:
87
+ "Herramientas|Herramientas Manuales|Herramientas de Corte y Desbaste",
88
+ version: 1,
89
+ retailersAvailable: [
90
+ {
91
+ name: "The Home Depot Golden",
92
+ id: 58,
93
+ percentage: 2,
94
+ },
95
+ ],
186
96
  },
187
- checked: false,
188
- retailersAvailable: [
189
- {
190
- id: 12,
191
- name: "La Comer",
192
- },
193
- {
194
- id: 29,
195
- name: "Farmacias del Ahorro",
196
- },
197
- {
198
- id: 63,
199
- name: "DAX",
200
- },
201
- ],
202
- categoryName:
203
- "Salud y Belleza|Cuidado del Cabello|Shampoos y Acondicionadores",
204
- upc: "750955287656712",
205
- id_article: 39270,
206
- id_order: 15142,
207
- },
97
+ ],
208
98
  },
209
99
  location: {
210
100
  pathname: "/EditProducts",
@@ -249,7 +139,7 @@ ProviderProductEditionDefault.args = {
249
139
  products_limit: "5000",
250
140
  type: "Enterprise",
251
141
  },
252
- src: "https://content-management-profile.s3.amazonaws.com/id-28/28.png?1683926822779",
142
+ src: "https://content-management-profile.s3.amazonaws.com/id-28/28.png?1691179745418",
253
143
  },
254
144
  company: {
255
145
  id_company: 1,
@@ -264,13 +154,8 @@ ProviderProductEditionDefault.args = {
264
154
  email: null,
265
155
  social_link: "",
266
156
  is_retailer: 0,
267
- retailers: [
268
- {
269
- id: null,
270
- name: null,
271
- country: null,
272
- },
273
- ],
157
+ financedRetailers: [],
158
+ retailers: [],
274
159
  },
275
160
  showSurvey: (v) => v && alert("se muestra"),
276
161
  };
@@ -668,6 +668,7 @@ export const ProviderProductEdition = ({
668
668
  }
669
669
  );
670
670
  if (res.data.statusCode === 200) {
671
+ setUpdatedDescriptions([]);
671
672
  setMessage("Descripciones guardadas con éxito");
672
673
  await loadData();
673
674
  }
@@ -694,6 +695,7 @@ export const ProviderProductEdition = ({
694
695
  }
695
696
  );
696
697
  if (res.data.statusCode === 200) {
698
+ setUpdatedDatasheets([]);
697
699
  setMessage("Fichas técnicas guardadas");
698
700
  await loadData();
699
701
  }
@@ -804,6 +806,7 @@ export const ProviderProductEdition = ({
804
806
  }
805
807
  );
806
808
  if (res.data.statusCode === 200) {
809
+ setImages({});
807
810
  setMessage("Imágenes guardadas con éxito");
808
811
  sessionStorage.removeItem("imagesList");
809
812
  await loadData();
@@ -18,86 +18,59 @@ RetailerProductEditionDefault.args = {
18
18
  token:
19
19
  "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiI5YTIxMzEyOC02NDgyLTRjMTYtYTRiNi02ZTY0ZjIyNWIxYmQiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6IjlhMjEzMTI4LTY0ODItNGMxNi1hNGI2LTZlNjRmMjI1YjFiZCIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiI5OGE0NzYxMy04ZGIyLTRlZjUtYjA0Mi01ZDU3MWRkZjIwMWIiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY4Mzg3NTIyNiwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY4Mzg3ODgyNiwiaWF0IjoxNjgzODc1MjI2LCJlbWFpbCI6ImlzbWFlbDk3bG9wZXpAZ21haWwuY29tIn0.EtgmT_THMx-Zy_zB5yZK4gz6TXNTVVJEKFt5X0JK2UkGVrp_q_92YCEuejS4n976fyTez0jkwOee6IkVHLV71uZWRBDFt-3Yw4ZxfsZYPNJWhoHXGNxhMU8MCkSntfu597esBTk-VsUpstT5R7L-WJfN8viE7R-qVo-42RlPTG0TFrWA9q0oTcqjv8vbxLpOBUjiEpjmqRhg4blJZwgkGNta6MOlw1vfmisOVbo9wMvqwnCZ9xx9KMKoH9U4uNObK_JomjbvPmTmkcUXsE-wGSD7XcoSwtuhBngLC7-jiu1u8MvL_ff5Z0Qp70sSpLdUglcSS8d1Xf7j_fcZuJ5jKA",
20
20
  productSelected: {
21
- orderId: 14606,
22
- status: "RA",
23
- datasheet_status: "RA",
24
- prio: "none",
25
- version: 3,
26
- description_status: "RA",
27
- images_status: "RA",
28
- statusByRetailer: {
29
- 4: {
30
- datasheet: "RA/AC",
31
- description: "RA/AC",
32
- images: "RA/AC",
33
- },
34
- 5: {
35
- datasheet: "RA/AC",
36
- description: "RA/AC",
37
- images: "RA/AC",
38
- },
39
- 6: {
40
- description: "RA/AC",
41
- images: "RA/AC",
42
- datasheet: "RA/AC",
43
- },
44
- 12: {
45
- datasheet: "RA/AC",
46
- description: "RA/AC",
47
- images: "RA/AC",
48
- },
49
- 17: {
50
- datasheet: "RA/AC",
51
- description: "RA/AC",
52
- images: "RA/AC",
53
- },
21
+ services: {
22
+ datasheets: 1,
23
+ descriptions: 1,
24
+ images: 1,
54
25
  },
55
- orderId: 15209,
56
- status: "ACA",
57
- datasheet_status: "ACA",
26
+ orderId: 15275,
27
+ status: "AC",
28
+ datasheet_status: "AC",
58
29
  prio: "none",
59
30
  version: 3,
60
- description_status: "ACA",
61
- images_status: "ACA",
31
+ description_status: "AC",
32
+ images_status: "AC",
62
33
  statusByRetailer: {
63
- 70: {
64
- datasheet: "ACA",
65
- description: "ACA",
66
- images: "ACA",
34
+ 34: {
35
+ datasheet: "AC",
36
+ description: "AC",
37
+ images: "AC",
67
38
  },
68
39
  },
69
40
  article: {
70
- id_article: 39390,
71
- id_category: "4311",
72
- name: "test demo 1",
73
- upc: "2312312313",
74
- timestamp: "2023-05-12T20:07:42.000Z",
75
- id_user: 133,
41
+ id_article: 39485,
42
+ id_category: "11",
43
+ name: "Mix de nueces",
44
+ upc: "7543453453",
45
+ timestamp: "2023-07-14T21:02:54.000Z",
46
+ id_user: 28,
76
47
  status: "NULL",
77
48
  active: 1,
78
- company_id: 912,
49
+ company_id: 1,
79
50
  company_name: "GRUPO BRAHMA",
80
51
  country: "México",
81
- id_order: 15209,
82
- id_datasheet_especialist: 232,
52
+ id_order: 15275,
53
+ id_datasheet_especialist: 54,
83
54
  id_datasheet_facilitator: 52,
84
- id_description_especialist: 232,
55
+ id_description_especialist: 54,
85
56
  id_description_facilitator: 52,
86
- id_images_especialist: 196,
57
+ id_images_especialist: 55,
87
58
  id_images_facilitator: 53,
88
- id_auditor: 195,
59
+ id_auditor: 37,
89
60
  id_recepcionist: null,
90
- category: "Ropa Interior Dama|Ropa Interior|Ropa Interior",
61
+ category: "Abarrotes|Abarrotes Secos|Frutos Secos",
91
62
  missingAttributes: 0,
92
63
  missingDescriptions: 0,
93
64
  missingImages: 0,
94
65
  },
95
66
  retailers: [
96
67
  {
97
- id: 70,
98
- name: "Bodega Aurrera",
68
+ id: 34,
69
+ name: "San Pablo",
99
70
  },
100
71
  ],
72
+ country: "México",
73
+ upc: "7543453453",
101
74
  },
102
75
  location: {
103
76
  product: { articleId: 354, versionId: 3 },
@@ -107,22 +80,22 @@ RetailerProductEditionDefault.args = {
107
80
  },
108
81
  },
109
82
  user: {
110
- id_user: 51,
111
- name: "ADMIN PRUEBA",
112
- last_name: "",
113
- email: "etc@contentoh.com",
114
- position: "",
83
+ id_user: 37,
84
+ name: "José",
85
+ last_name: "Castañeda",
86
+ email: "ismael97lopez@gmail.com",
87
+ position: "Auditor",
115
88
  telephone: "",
116
- country: "",
89
+ country: "México",
117
90
  id_company: 2,
118
- id_cognito: "a6c4d3d6-24a4-41d4-ad0f-d087438ab5b6",
91
+ id_cognito: "9a213128-6482-4c16-a4b6-6e64f225b1bd",
119
92
  birth_Date: null,
120
93
  about_me: "",
121
94
  zip_code: "",
122
95
  address: "",
123
96
  job: "",
124
97
  id_stripe: "",
125
- id_role: 1,
98
+ id_role: 6,
126
99
  active: 1,
127
100
  is_retailer: 0,
128
101
  email_notify: 1,
@@ -138,6 +111,6 @@ RetailerProductEditionDefault.args = {
138
111
  products_limit: "3",
139
112
  type: "PyMES",
140
113
  },
141
- src: "https://content-management-profile.s3.amazonaws.com/id-51/51.png?1682016291518",
114
+ src: "https://content-management-profile.s3.amazonaws.com/id-37/37.png?1691175586149",
142
115
  },
143
116
  };
@@ -513,6 +513,7 @@ export const RetailerProductEdition = ({
513
513
  JSON.stringify(productTemp)
514
514
  );
515
515
 
516
+ setUpdatedDescriptions([]);
516
517
  setMessage("Descripciones guardadas con éxito");
517
518
  await loadData();
518
519
  }
@@ -553,7 +554,7 @@ export const RetailerProductEdition = ({
553
554
  "productSelected",
554
555
  JSON.stringify(productTemp)
555
556
  );
556
-
557
+ setUpdatedDatasheets([]);
557
558
  setMessage("Fichas técnicas guardadas");
558
559
  await loadData();
559
560
  }
@@ -685,6 +686,7 @@ export const RetailerProductEdition = ({
685
686
  "productSelected",
686
687
  JSON.stringify(productTemp)
687
688
  );
689
+ setImages({});
688
690
  setMessage("Imágenes guardadas con éxito");
689
691
  sessionStorage.removeItem("imagesList");
690
692
  await loadData();