contentoh-components-library 21.5.27 → 21.5.29
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/assets/images/Icons/DownloadIcon copy.svg +4 -0
- package/dist/assets/images/Icons/Spinner copy.gif +0 -0
- package/dist/assets/images/Icons/info copy.svg +8 -0
- package/dist/components/organisms/InputGroup/index.js +39 -37
- package/dist/components/organisms/InputGroup/styles.js +1 -1
- package/dist/components/organisms/ServiceDataValidator/ServiceDataValidator.stories.js +99 -0
- package/dist/components/organisms/ServiceDataValidator/index.js +57 -0
- package/dist/components/organisms/ServiceDataValidator/styles.js +20 -0
- package/dist/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +60 -157
- package/package.json +1 -1
- package/src/components/organisms/InputGroup/index.js +18 -15
- package/src/components/organisms/InputGroup/styles.js +19 -3
- package/src/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +63 -164
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<circle cx="15" cy="15" r="14.6316" stroke="#F0EEF2" stroke-width="0.736842"/>
|
|
3
|
+
<path d="M20.7063 13.1113C20.2246 10.6676 18.0783 8.83301 15.5 8.83301C13.4529 8.83301 11.675 9.99467 10.7896 11.6947C8.6575 11.9213 7 13.7276 7 15.9163C7 18.2609 8.90542 20.1663 11.25 20.1663H20.4583C22.4133 20.1663 24 18.5797 24 16.6247C24 14.7547 22.5479 13.2388 20.7063 13.1113ZM19.0417 15.208L15.5 18.7497L11.9583 15.208H14.0833V12.3747H16.9167V15.208H19.0417Z" fill="#817393"/>
|
|
4
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
<svg width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<mask id="mask0_37_379" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="8" height="8">
|
|
3
|
+
<rect width="8" height="8" fill="#D9D9D9"/>
|
|
4
|
+
</mask>
|
|
5
|
+
<g mask="url(#mask0_37_379)">
|
|
6
|
+
<path d="M3.63807 5.98825H4.40893V3.62867H3.63807V5.98825ZM3.99596 3.07403C4.124 3.07403 4.2311 3.03169 4.31727 2.947C4.40345 2.86232 4.44653 2.75738 4.44653 2.6322C4.44653 2.49463 4.40331 2.38347 4.31685 2.29871C4.2304 2.21394 4.12327 2.17156 3.99547 2.17156C3.86061 2.17156 3.75166 2.21394 3.66863 2.29871C3.58559 2.38347 3.54407 2.49307 3.54407 2.6275C3.54407 2.7566 3.58737 2.8633 3.67398 2.94759C3.7606 3.03188 3.86792 3.07403 3.99596 3.07403ZM3.9991 8C3.44212 8 2.92156 7.89633 2.43741 7.68899C1.95324 7.48165 1.52964 7.19646 1.16659 6.83341C0.803541 6.47036 0.518349 6.04696 0.311013 5.5632C0.103671 5.07943 0 4.5588 0 4.0013C0 3.44379 0.103671 2.92273 0.311013 2.4381C0.518349 1.95348 0.803049 1.53104 1.16511 1.1708C1.52718 0.810554 1.95032 0.525358 2.43455 0.315215C2.91877 0.105072 3.43989 0 3.99792 0C4.55595 0 5.07764 0.10483 5.56301 0.314491C6.04837 0.524146 6.47094 0.80868 6.83072 1.16809C7.1905 1.52751 7.47533 1.95015 7.6852 2.43603C7.89507 2.92191 8 3.44396 8 4.0022C8 4.56004 7.89493 5.08098 7.68479 5.56504C7.47464 6.04909 7.18945 6.47169 6.8292 6.83282C6.46896 7.19395 6.04646 7.47876 5.56169 7.68726C5.07694 7.89575 4.55607 8 3.9991 8ZM4 7.11633C4.86173 7.11633 5.59499 6.81435 6.19977 6.21037C6.80454 5.60639 7.10693 4.8696 7.10693 4C7.10693 3.13827 6.80513 2.40501 6.20153 1.80024C5.59793 1.19546 4.86095 0.893067 3.9906 0.893067C3.12887 0.893067 2.39561 1.19487 1.79083 1.79847C1.18606 2.40207 0.883666 3.13905 0.883666 4.0094C0.883666 4.87113 1.18565 5.60439 1.78963 6.20917C2.39361 6.81394 3.1304 7.11633 4 7.11633Z" fill="#ECDD1D"/>
|
|
7
|
+
</g>
|
|
8
|
+
</svg>
|
|
@@ -70,7 +70,8 @@ var InputGroup = function InputGroup(_ref) {
|
|
|
70
70
|
imageStates = _ref2.imageStates;
|
|
71
71
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
72
72
|
style: {
|
|
73
|
-
|
|
73
|
+
display: 'flex',
|
|
74
|
+
alignItems: 'center'
|
|
74
75
|
},
|
|
75
76
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_Tooltip.Tooltip, {
|
|
76
77
|
componentTooltip: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
@@ -189,36 +190,37 @@ var InputGroup = function InputGroup(_ref) {
|
|
|
189
190
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
190
191
|
className: "inputs-container",
|
|
191
192
|
children: inputGroup === null || inputGroup === void 0 ? void 0 : (_inputGroup$inputs = inputGroup.inputs) === null || _inputGroup$inputs === void 0 ? void 0 : _inputGroup$inputs.map(function (input, index) {
|
|
192
|
-
var _dataInputs$input, _dataInputs$input2, _dataInputs$input3, _dataInputs$input4, _dataInputs$input5, _dataInputs$input6, _dataInputs$input7, _dataInputs$input8, _dataInputs$input9, _dataInputs$input10,
|
|
193
|
-
|
|
194
|
-
return activeSection === "Ficha técnica" ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(
|
|
195
|
-
|
|
193
|
+
var _dataInputs$input, _dataInputs$input2, _dataInputs$input3, _dataInputs$input4, _dataInputs$input5, _dataInputs$input6, _dataInputs$input7, _dataInputs$input8, _dataInputs$input9, _dataInputs$input10, _dataInputs$input11, _dataInputs$input12, _dataInputs$input13, _dataInputs$input14, _dataInputs$input15, _dataInputs$input16, _auditInputs$input, _dataInputs$input17, _dataInputs$input18, _dataInputs$input19, _dataInputs$input20, _dataInputs$input21, _dataInputs$input22, _auditInputGroup$inpu, _auditInputGroup$inpu2;
|
|
194
|
+
|
|
195
|
+
return activeSection === "Ficha técnica" ? /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
196
|
+
className: ((_dataInputs$input = dataInputs[input]) === null || _dataInputs$input === void 0 ? void 0 : _dataInputs$input.id) === 6700 || ((_dataInputs$input2 = dataInputs[input]) === null || _dataInputs$input2 === void 0 ? void 0 : _dataInputs$input2.id) === 6701 ? "inputs-validation-onboarding" : "",
|
|
197
|
+
children: [((_dataInputs$input3 = dataInputs[input]) === null || _dataInputs$input3 === void 0 ? void 0 : _dataInputs$input3.isApproved) === false && /*#__PURE__*/(0, _jsxRuntime.jsx)(InputReviewSection, {
|
|
198
|
+
inputId: (_dataInputs$input4 = dataInputs[input]) === null || _dataInputs$input4 === void 0 ? void 0 : _dataInputs$input4.id,
|
|
199
|
+
isApproved: (_dataInputs$input5 = dataInputs[input]) === null || _dataInputs$input5 === void 0 ? void 0 : _dataInputs$input5.isApproved,
|
|
200
|
+
comment: (_dataInputs$input6 = dataInputs[input]) === null || _dataInputs$input6 === void 0 ? void 0 : _dataInputs$input6.comment,
|
|
201
|
+
handleImgClick: handleImgClick,
|
|
202
|
+
changeImageBtn: changeImageBtn,
|
|
203
|
+
showDivState: showDivStates,
|
|
204
|
+
imageStates: imageStates
|
|
205
|
+
}), (((_dataInputs$input7 = dataInputs[input]) === null || _dataInputs$input7 === void 0 ? void 0 : _dataInputs$input7.id) != 6700 && ((_dataInputs$input8 = dataInputs[input]) === null || _dataInputs$input8 === void 0 ? void 0 : _dataInputs$input8.id) != 6701 || ((_dataInputs$input9 = dataInputs[input]) === null || _dataInputs$input9 === void 0 ? void 0 : _dataInputs$input9.isApproved) != undefined) && /*#__PURE__*/(0, _jsxRuntime.jsx)(_TagAndInput.TagAndInput, {
|
|
196
206
|
//disabled={input === 40001}
|
|
197
|
-
disabled: (_dataInputs$
|
|
198
|
-
inputId: (_dataInputs$
|
|
207
|
+
disabled: (_dataInputs$input12 = dataInputs[input]) === null || _dataInputs$input12 === void 0 ? void 0 : _dataInputs$input12.isApproved,
|
|
208
|
+
inputId: (_dataInputs$input13 = dataInputs[input]) === null || _dataInputs$input13 === void 0 ? void 0 : _dataInputs$input13.id,
|
|
199
209
|
version: version,
|
|
200
|
-
inputType: inputTypeValue((_dataInputs$
|
|
201
|
-
label: ((_dataInputs$
|
|
202
|
-
value: compare ? (_auditInputs$input = auditInputs[input]) === null || _auditInputs$input === void 0 ? void 0 : _auditInputs$input.value : (_dataInputs$
|
|
210
|
+
inputType: inputTypeValue((_dataInputs$input14 = dataInputs[input]) === null || _dataInputs$input14 === void 0 ? void 0 : _dataInputs$input14.type),
|
|
211
|
+
label: ((_dataInputs$input15 = dataInputs[input]) === null || _dataInputs$input15 === void 0 ? void 0 : _dataInputs$input15.name) + ((_dataInputs$input16 = dataInputs[input]) !== null && _dataInputs$input16 !== void 0 && _dataInputs$input16.required ? "*" : ""),
|
|
212
|
+
value: compare ? (_auditInputs$input = auditInputs[input]) === null || _auditInputs$input === void 0 ? void 0 : _auditInputs$input.value : (_dataInputs$input17 = dataInputs[input]) === null || _dataInputs$input17 === void 0 ? void 0 : _dataInputs$input17.value,
|
|
203
213
|
inputPlaceHolder: input === null || input === void 0 ? void 0 : input.placeholder,
|
|
204
214
|
articleId: articleId,
|
|
205
|
-
isRequired: (_dataInputs$
|
|
215
|
+
isRequired: (_dataInputs$input18 = dataInputs[input]) === null || _dataInputs$input18 === void 0 ? void 0 : _dataInputs$input18.required,
|
|
206
216
|
updatedDatasheets: updatedDatasheets,
|
|
207
217
|
setUpdatedDatasheets: setUpdatedDatasheets,
|
|
208
|
-
maxChar: (_dataInputs$
|
|
209
|
-
optionList: (_dataInputs$
|
|
210
|
-
description: (_dataInputs$
|
|
218
|
+
maxChar: (_dataInputs$input19 = dataInputs[input]) !== null && _dataInputs$input19 !== void 0 && _dataInputs$input19.max_chars ? (_dataInputs$input20 = dataInputs[input]) === null || _dataInputs$input20 === void 0 ? void 0 : _dataInputs$input20.max_chars : 999,
|
|
219
|
+
optionList: (_dataInputs$input21 = dataInputs[input]) === null || _dataInputs$input21 === void 0 ? void 0 : _dataInputs$input21.option_list,
|
|
220
|
+
description: (_dataInputs$input22 = dataInputs[input]) === null || _dataInputs$input22 === void 0 ? void 0 : _dataInputs$input22.description,
|
|
211
221
|
showTooltip: true,
|
|
212
222
|
auditClass: compare && !isEquals(dataInputs[input].value, auditInputs[input].value) ? "audit-class" : ""
|
|
213
|
-
}, index + "-" + ((_dataInputs$
|
|
214
|
-
inputId: (_dataInputs$input18 = dataInputs[input]) === null || _dataInputs$input18 === void 0 ? void 0 : _dataInputs$input18.id,
|
|
215
|
-
isApproved: (_dataInputs$input19 = dataInputs[input]) === null || _dataInputs$input19 === void 0 ? void 0 : _dataInputs$input19.isApproved,
|
|
216
|
-
comment: (_dataInputs$input20 = dataInputs[input]) === null || _dataInputs$input20 === void 0 ? void 0 : _dataInputs$input20.comment,
|
|
217
|
-
handleImgClick: handleImgClick,
|
|
218
|
-
changeImageBtn: changeImageBtn,
|
|
219
|
-
showDivState: showDivStates,
|
|
220
|
-
imageStates: imageStates
|
|
221
|
-
})]
|
|
223
|
+
}, index + "-" + ((_dataInputs$input10 = dataInputs[input]) === null || _dataInputs$input10 === void 0 ? void 0 : _dataInputs$input10.value) + "-" + ((_dataInputs$input11 = dataInputs[input]) === null || _dataInputs$input11 === void 0 ? void 0 : _dataInputs$input11.id) + "-" + compare)]
|
|
222
224
|
}) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
223
225
|
children: [(input === null || input === void 0 ? void 0 : input.isApproved) === false && /*#__PURE__*/(0, _jsxRuntime.jsx)(InputReviewSection, {
|
|
224
226
|
inputId: input === null || input === void 0 ? void 0 : input.id,
|
|
@@ -258,34 +260,34 @@ var InputGroup = function InputGroup(_ref) {
|
|
|
258
260
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
259
261
|
className: "inputs-container",
|
|
260
262
|
children: inputGroup === null || inputGroup === void 0 ? void 0 : (_inputGroup$inputs2 = inputGroup.inputs) === null || _inputGroup$inputs2 === void 0 ? void 0 : _inputGroup$inputs2.map(function (input, index) {
|
|
261
|
-
var _dataInputs$
|
|
263
|
+
var _dataInputs$input23, _dataInputs$input24, _dataInputs$input25, _dataInputs$input26, _dataInputs$input27, _dataInputs$input28, _dataInputs$input29, _auditInputs$input2, _dataInputs$input30, _dataInputs$input31, _dataInputs$input32, _dataInputs$input33, _dataInputs$input34, _dataInputs$input35, _dataInputs$input36, _dataInputs$input37, _dataInputs$input38, _dataInputs$input39, _auditInputGroup$inpu3, _auditInputGroup$inpu4;
|
|
262
264
|
|
|
263
265
|
return activeSection === "Ficha técnica" ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
264
266
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_TagAndInput.TagAndInput, {
|
|
265
267
|
//disabled={input === 40001}
|
|
266
|
-
disabled: (_dataInputs$
|
|
267
|
-
inputId: (_dataInputs$
|
|
268
|
+
disabled: (_dataInputs$input25 = dataInputs[input]) === null || _dataInputs$input25 === void 0 ? void 0 : _dataInputs$input25.isApproved,
|
|
269
|
+
inputId: (_dataInputs$input26 = dataInputs[input]) === null || _dataInputs$input26 === void 0 ? void 0 : _dataInputs$input26.id,
|
|
268
270
|
version: version,
|
|
269
|
-
inputType: inputTypeValue((_dataInputs$
|
|
270
|
-
label: ((_dataInputs$
|
|
271
|
-
value: compare ? (_auditInputs$input2 = auditInputs[input]) === null || _auditInputs$input2 === void 0 ? void 0 : _auditInputs$input2.value : (_dataInputs$
|
|
271
|
+
inputType: inputTypeValue((_dataInputs$input27 = dataInputs[input]) === null || _dataInputs$input27 === void 0 ? void 0 : _dataInputs$input27.type),
|
|
272
|
+
label: ((_dataInputs$input28 = dataInputs[input]) === null || _dataInputs$input28 === void 0 ? void 0 : _dataInputs$input28.name) + ((_dataInputs$input29 = dataInputs[input]) !== null && _dataInputs$input29 !== void 0 && _dataInputs$input29.required ? "*" : ""),
|
|
273
|
+
value: compare ? (_auditInputs$input2 = auditInputs[input]) === null || _auditInputs$input2 === void 0 ? void 0 : _auditInputs$input2.value : (_dataInputs$input30 = dataInputs[input]) === null || _dataInputs$input30 === void 0 ? void 0 : _dataInputs$input30.value,
|
|
272
274
|
inputPlaceHolder: input === null || input === void 0 ? void 0 : input.placeholder,
|
|
273
275
|
articleId: articleId,
|
|
274
|
-
isRequired: (_dataInputs$
|
|
276
|
+
isRequired: (_dataInputs$input31 = dataInputs[input]) === null || _dataInputs$input31 === void 0 ? void 0 : _dataInputs$input31.required,
|
|
275
277
|
updatedDatasheets: updatedDatasheets,
|
|
276
278
|
setUpdatedDatasheets: setUpdatedDatasheets,
|
|
277
|
-
maxChar: (_dataInputs$
|
|
278
|
-
optionList: (_dataInputs$
|
|
279
|
-
description: (_dataInputs$
|
|
279
|
+
maxChar: (_dataInputs$input32 = dataInputs[input]) !== null && _dataInputs$input32 !== void 0 && _dataInputs$input32.max_chars ? (_dataInputs$input33 = dataInputs[input]) === null || _dataInputs$input33 === void 0 ? void 0 : _dataInputs$input33.max_chars : 999,
|
|
280
|
+
optionList: (_dataInputs$input34 = dataInputs[input]) === null || _dataInputs$input34 === void 0 ? void 0 : _dataInputs$input34.option_list,
|
|
281
|
+
description: (_dataInputs$input35 = dataInputs[input]) === null || _dataInputs$input35 === void 0 ? void 0 : _dataInputs$input35.description,
|
|
280
282
|
showTooltip: true,
|
|
281
283
|
inputGroup: inputGroup,
|
|
282
284
|
dataInputs: dataInputs,
|
|
283
285
|
onChange: setUpdatedBoxData,
|
|
284
286
|
auditClass: compare && !isEquals(dataInputs[input].value, auditInputs[input].value) ? "audit-class" : ""
|
|
285
|
-
}, index + "-" + ((_dataInputs$
|
|
286
|
-
inputId: (_dataInputs$
|
|
287
|
-
isApproved: (_dataInputs$
|
|
288
|
-
comment: (_dataInputs$
|
|
287
|
+
}, index + "-" + ((_dataInputs$input23 = dataInputs[input]) === null || _dataInputs$input23 === void 0 ? void 0 : _dataInputs$input23.value) + "-" + ((_dataInputs$input24 = dataInputs[input]) === null || _dataInputs$input24 === void 0 ? void 0 : _dataInputs$input24.id) + "-" + compare), ((_dataInputs$input36 = dataInputs[input]) === null || _dataInputs$input36 === void 0 ? void 0 : _dataInputs$input36.isApproved) === false && /*#__PURE__*/(0, _jsxRuntime.jsx)(InputReviewSection, {
|
|
288
|
+
inputId: (_dataInputs$input37 = dataInputs[input]) === null || _dataInputs$input37 === void 0 ? void 0 : _dataInputs$input37.id,
|
|
289
|
+
isApproved: (_dataInputs$input38 = dataInputs[input]) === null || _dataInputs$input38 === void 0 ? void 0 : _dataInputs$input38.isApproved,
|
|
290
|
+
comment: (_dataInputs$input39 = dataInputs[input]) === null || _dataInputs$input39 === void 0 ? void 0 : _dataInputs$input39.comment,
|
|
289
291
|
handleImgClick: handleImgClick,
|
|
290
292
|
changeImageBtn: changeImageBtn,
|
|
291
293
|
showDivState: showDivStates,
|
|
@@ -15,6 +15,6 @@ var _variables = require("../../../global-files/variables");
|
|
|
15
15
|
|
|
16
16
|
var _templateObject;
|
|
17
17
|
|
|
18
|
-
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n border: 1px solid ", ";\n border-radius: 6px;\n padding: 10px;\n width: 100%;\n\n .retailer-name-header {\n & + * {\n margin-top: 10px;\n }\n }\n &.datasheets-layout {\n padding-right: 0;\n\n .inputs-container {\n display: flex;\n flex-wrap: wrap;\n width: 100%;\n gap: 5px;\n\n .input-container {\n flex: 1 1 20%;\n min-width: 227px;\n display: flex;\n flex-direction: column;\n }\n }\n }\n\n & + * {\n margin-top: 15px;\n }\n\n .btnReviewState {\n display:
|
|
18
|
+
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n border: 1px solid ", ";\n border-radius: 6px;\n padding: 10px;\n width: 100%;\n\n .retailer-name-header {\n & + * {\n margin-top: 10px;\n }\n }\n &.datasheets-layout {\n padding-right: 0;\n\n .inputs-container {\n display: flex;\n flex-wrap: wrap;\n width: 100%;\n gap: 5px;\n\n .input-container {\n flex: 1 1 20%;\n min-width: 227px;\n display: flex;\n flex-direction: column;\n }\n }\n\n .inputs-validation-onboarding{\n display: flex;\n align-items: center;\n gap:5px;\n padding: 0px 5px;\n //border: 1px solid #e33aa9;\n // border-left: 1px solid #e33aa9;\n // border-bottom: 1px solid #e33aa9;\n border-radius: 6px;\n position:relative;\n }\n }\n\n & + * {\n margin-top: 15px;\n }\n\n .btnReviewState {\n display: flex;\n flex-direction: column;\n border: 1px solid lightgray;\n border-radius: 3px;\n z-index: 1000;\n position: absolute;\n transform: translate(35%, 0);\n }\n\n .btnReviewState button {\n display: flex;\n align-items: center;\n border: none;\n background: white;\n border-radius: 3px;\n box-shadow: 2px 2px 2px lightgray;\n }\n .btnReviewState button:hover {\n background: lightgray;\n }\n /* #divBtnsReviewdown {\n border-left: 1px solid black;\n border-right: 1px solid black;\n border-bottom: 1px solid black;\n }\n #aceptbtn {\n background: white;\n border: none;\n }\n #rejectbtn {\n background: white;\n border: none;\n } */\n"])), _variables.GlobalColors.s2);
|
|
19
19
|
|
|
20
20
|
exports.Container = Container;
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = exports.ServiceDataValidatorDefault = void 0;
|
|
9
|
+
|
|
10
|
+
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
|
|
11
|
+
|
|
12
|
+
var _index = require("./index");
|
|
13
|
+
|
|
14
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
15
|
+
|
|
16
|
+
var _default = {
|
|
17
|
+
title: "Components/molecules/ServiceDataValidator",
|
|
18
|
+
component: _index.ServiceDataValidator
|
|
19
|
+
};
|
|
20
|
+
exports.default = _default;
|
|
21
|
+
|
|
22
|
+
var Template = function Template(args) {
|
|
23
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.ServiceDataValidator, (0, _objectSpread2.default)({}, args));
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
var ServiceDataValidatorDefault = Template.bind({});
|
|
27
|
+
exports.ServiceDataValidatorDefault = ServiceDataValidatorDefault;
|
|
28
|
+
ServiceDataValidatorDefault.args = {
|
|
29
|
+
activeRetailer: {
|
|
30
|
+
id: 34,
|
|
31
|
+
image: "https://content-management-images.s3.amazonaws.com/retailers/34.png",
|
|
32
|
+
name: "San Pablo",
|
|
33
|
+
services: ["AA", "AP", "AA"]
|
|
34
|
+
},
|
|
35
|
+
headerData: {
|
|
36
|
+
"orderId": 15275,
|
|
37
|
+
"status": "AA",
|
|
38
|
+
"datasheet_status": "AA",
|
|
39
|
+
"prio": "none",
|
|
40
|
+
"version": 3,
|
|
41
|
+
"description_status": "AA",
|
|
42
|
+
"images_status": "AA",
|
|
43
|
+
"brand": null,
|
|
44
|
+
"retailerOrder": 0,
|
|
45
|
+
"missing": {
|
|
46
|
+
"datasheet": null,
|
|
47
|
+
"descriptions": null,
|
|
48
|
+
"images": null
|
|
49
|
+
},
|
|
50
|
+
"services": {
|
|
51
|
+
"datasheets": 1,
|
|
52
|
+
"descriptions": 1,
|
|
53
|
+
"images": 1
|
|
54
|
+
},
|
|
55
|
+
"article": {
|
|
56
|
+
"category": "Abarrotes|Abarrotes Secos|Frutos Secos",
|
|
57
|
+
"company_name": "GRUPO BRAHMA",
|
|
58
|
+
"country": "México",
|
|
59
|
+
"id_category": "11",
|
|
60
|
+
"id_datasheet_especialist": 54,
|
|
61
|
+
"id_datasheet_facilitator": 52,
|
|
62
|
+
"id_description_especialist": 54,
|
|
63
|
+
"id_description_facilitator": 52,
|
|
64
|
+
"id_images_especialist": 55,
|
|
65
|
+
"id_images_facilitator": 53,
|
|
66
|
+
"id_order": 15275,
|
|
67
|
+
"id_article": 39485,
|
|
68
|
+
"id_auditor": 37,
|
|
69
|
+
"name": "Mix de nueces",
|
|
70
|
+
"timestamp": "2023-07-14T21:03:19.000Z",
|
|
71
|
+
"upc": "7543453453"
|
|
72
|
+
},
|
|
73
|
+
"retailers": [{
|
|
74
|
+
"id": 34,
|
|
75
|
+
"name": "San Pablo",
|
|
76
|
+
"services": ["AA", "AP", "AA"],
|
|
77
|
+
"image": "https://content-management-images.s3.amazonaws.com/retailers/34.png"
|
|
78
|
+
}],
|
|
79
|
+
"statusByRetailer": {
|
|
80
|
+
"34": {
|
|
81
|
+
"datasheet": "AA",
|
|
82
|
+
"description": "AA",
|
|
83
|
+
"images": "AA"
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
"retailersAvailable": [{
|
|
87
|
+
"id": 34,
|
|
88
|
+
"name": "San Pablo"
|
|
89
|
+
}],
|
|
90
|
+
"categoryName": "Abarrotes|Abarrotes Secos|Frutos Secos",
|
|
91
|
+
"upc": "7543453453",
|
|
92
|
+
"id_article": 39485,
|
|
93
|
+
"id_order": 15275
|
|
94
|
+
},
|
|
95
|
+
showApproveRejectAll: true,
|
|
96
|
+
showValidationButtons: true,
|
|
97
|
+
text: "Descripción",
|
|
98
|
+
missingData: 1
|
|
99
|
+
};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ServiceDataValidator = void 0;
|
|
7
|
+
|
|
8
|
+
var _styles = require("./styles");
|
|
9
|
+
|
|
10
|
+
var _variables = require("../../../global-files/variables");
|
|
11
|
+
|
|
12
|
+
var _react = require("react");
|
|
13
|
+
|
|
14
|
+
var _Validation = require("../Validation");
|
|
15
|
+
|
|
16
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
17
|
+
|
|
18
|
+
var ServiceDataValidator = function ServiceDataValidator(_ref) {
|
|
19
|
+
var headerData = _ref.headerData,
|
|
20
|
+
activeRetailer = _ref.activeRetailer,
|
|
21
|
+
setActiveRetailer = _ref.setActiveRetailer,
|
|
22
|
+
showValidationButtons = _ref.showValidationButtons,
|
|
23
|
+
showApproveRejectAll = _ref.showApproveRejectAll,
|
|
24
|
+
approveAll = _ref.approveAll,
|
|
25
|
+
rejectAll = _ref.rejectAll,
|
|
26
|
+
approve = _ref.approve,
|
|
27
|
+
reject = _ref.reject,
|
|
28
|
+
text = _ref.text,
|
|
29
|
+
complete = _ref.complete,
|
|
30
|
+
showValidation = _ref.showValidation,
|
|
31
|
+
missingData = _ref.missingData;
|
|
32
|
+
var headerTop = (0, _react.useRef)();
|
|
33
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.Container, {
|
|
34
|
+
fontFamily: _variables.FontFamily.Raleway,
|
|
35
|
+
color: _variables.GlobalColors.original_magenta,
|
|
36
|
+
ref: headerTop,
|
|
37
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("span", {
|
|
38
|
+
className: "service-text",
|
|
39
|
+
children: [text, ":", " ", /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
40
|
+
className: "service-complete",
|
|
41
|
+
children: complete ? "Completado" : "".concat(missingData, " ").concat(missingData > 1 ? 'Faltantes' : 'Faltante')
|
|
42
|
+
})]
|
|
43
|
+
}), showValidation && /*#__PURE__*/(0, _jsxRuntime.jsx)(_Validation.Validation, {
|
|
44
|
+
headerData: headerData,
|
|
45
|
+
activeRetailer: activeRetailer,
|
|
46
|
+
setActiveRetailer: setActiveRetailer,
|
|
47
|
+
showValidationButtons: showValidationButtons,
|
|
48
|
+
showApproveRejectAll: showApproveRejectAll,
|
|
49
|
+
approveAll: approveAll,
|
|
50
|
+
rejectAll: rejectAll,
|
|
51
|
+
approve: approve,
|
|
52
|
+
reject: reject
|
|
53
|
+
})]
|
|
54
|
+
});
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
exports.ServiceDataValidator = ServiceDataValidator;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.Container = void 0;
|
|
9
|
+
|
|
10
|
+
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/taggedTemplateLiteral"));
|
|
11
|
+
|
|
12
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
13
|
+
|
|
14
|
+
var _variables = require("../../../global-files/variables");
|
|
15
|
+
|
|
16
|
+
var _templateObject;
|
|
17
|
+
|
|
18
|
+
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\ndisplay:flex;\npadding:7px 15px;\njustify-content: space-between;\nbackground:", ";\nwidth: auto;\nheight:34px;\nalign-items: center;\nmax-width:300px;\nborder-radius:5px;\n\n\n * + * {\n margin-left: 10px;\n }\n\n .btn-gral{\n min-width: 34px;\n min-height:34px;\n }\n .images-buttons{\n display:flex;\n }\n .service-text{\n font-family:", ", sans-serif;\n font-size:12px;\n font-weight: 500;\n color:", ";\n }\n .service-complete{\n color:", ";\n }\n"])), _variables.GlobalColors.blue_light, _variables.FontFamily.RobotoMedium, _variables.GlobalColors.gray, _variables.GlobalColors.black);
|
|
19
|
+
|
|
20
|
+
exports.Container = Container;
|
|
@@ -27,129 +27,48 @@ var ProviderProductEditionDefault = Template.bind({});
|
|
|
27
27
|
exports.ProviderProductEditionDefault = ProviderProductEditionDefault;
|
|
28
28
|
ProviderProductEditionDefault.args = {
|
|
29
29
|
tabsSections: {
|
|
30
|
-
Descripción:
|
|
30
|
+
Descripción: false,
|
|
31
31
|
"Ficha técnica": true,
|
|
32
|
-
Imágenes:
|
|
32
|
+
Imágenes: false
|
|
33
33
|
},
|
|
34
|
-
token: "eyJraWQiOiJEV3owZnNieXg2MXNFcVduN3RCXC81bVhod3ZNbFZIOTgwUnZcL3RjT0lKdEk9IiwiYWxnIjoiUlMyNTYifQ.
|
|
35
|
-
articleId:
|
|
36
|
-
category: "
|
|
37
|
-
version:
|
|
34
|
+
token: "eyJraWQiOiJEV3owZnNieXg2MXNFcVduN3RCXC81bVhod3ZNbFZIOTgwUnZcL3RjT0lKdEk9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIwYmJjMWJjYi0yODJkLTRjYzYtYjcwZS0wNWNhY2JiYjU1NjMiLCJjb2duaXRvOmdyb3VwcyI6WyJ1c3VhcmlvX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfbFN6UVo0WjdSIiwicGhvbmVfbnVtYmVyX3ZlcmlmaWVkIjpmYWxzZSwiY29nbml0bzp1c2VybmFtZSI6IjBiYmMxYmNiLTI4MmQtNGNjNi1iNzBlLTA1Y2FjYmJiNTU2MyIsImF1ZCI6IjUyZDlza2tkY2c4cWpwODhvb2sxdXNlNm1rIiwiZXZlbnRfaWQiOiJmMTdlYTVlOS0wZmE2LTQ1YmUtYjE5MS1iNTViZjgxYWRiNzkiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTcxOTUwNDg0OSwibmFtZSI6IlByb3ZlZWRvciBSYWRpb3NoYWNrIiwicGhvbmVfbnVtYmVyIjoiKzUyMTIzNDU2Nzg5NzgiLCJleHAiOjE3MTk1MDg0NDksImlhdCI6MTcxOTUwNDg0OSwiZW1haWwiOiJwcm92ZWVkb3JyYWRpb3NoYWNrQGFsbGZyZWVtYWlsLm5ldCJ9.M0Pm70YhdG1JARzamruJKSzJPjGl_tXAYCwQHGiIRYLHo4X05B95VgCLXVvetadrH7dsp6PviJ3MuF2JPzBVXMAP_N26zSeJFIx1ywqVp-nehwE3TUiF8L0P_MTLCBJzHcHf41HzTDHr546nBBgF64W3bZNd_J-jSFW3xZxgu6dq_RZ5fywVlzs6sZgDAenOtzcB9-Ig97mpdTil8ag8wgbf2LlcypaWGsEESbHhus-_hx58tosjwQ_a0rvsz47X9HI9YMe6rD0xFR9cQCub6WG7d65fMyqaCl-X4DsFE1a4z2AnWcmgXmAdwZTqCjvo8TPKJjxMBvptlShL753UaQ",
|
|
35
|
+
articleId: 128483,
|
|
36
|
+
category: "1139",
|
|
37
|
+
version: 1,
|
|
38
38
|
productSelected: {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
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: "Navidad|Decoración Interior|Mallas y Listones",
|
|
60
|
-
company_name: "THD IMPORTACIONES",
|
|
61
|
-
country: null,
|
|
62
|
-
id_category: "2902",
|
|
63
|
-
id_datasheet_especialist: 2757,
|
|
64
|
-
id_datasheet_facilitator: null,
|
|
65
|
-
id_description_especialist: 2757,
|
|
66
|
-
id_description_facilitator: null,
|
|
67
|
-
id_images_especialist: 1259,
|
|
68
|
-
id_images_facilitator: null,
|
|
69
|
-
id_order: 8086,
|
|
70
|
-
id_article: 127595,
|
|
71
|
-
id_auditor: 514,
|
|
72
|
-
name: "LISTON DECORATIVO DISNEY 5M 2 ESTILOS",
|
|
73
|
-
timestamp: "2024-06-05T14:30:33.000Z",
|
|
74
|
-
upc: "214715"
|
|
75
|
-
},
|
|
76
|
-
retailers: [{
|
|
77
|
-
id: 58
|
|
78
|
-
}],
|
|
79
|
-
statusByRetailer: {
|
|
80
|
-
"58": {
|
|
81
|
-
datasheet: "AA",
|
|
82
|
-
description: "AA",
|
|
83
|
-
images: "AA"
|
|
84
|
-
}
|
|
85
|
-
},
|
|
39
|
+
id_article: 128483,
|
|
40
|
+
upc: "1010101010122",
|
|
41
|
+
name: "Prueba 26-jun-24",
|
|
42
|
+
timestamp: "2024-06-26T17:06:17.000Z",
|
|
43
|
+
categoryName: "Audio|Audífonos|In Ear",
|
|
44
|
+
id_category: 1139,
|
|
45
|
+
version: 1,
|
|
46
|
+
reviewState: "rejected_to_provider",
|
|
86
47
|
retailersAvailable: [{
|
|
87
|
-
|
|
48
|
+
name: "Radioshack",
|
|
49
|
+
id: 74
|
|
88
50
|
}],
|
|
89
|
-
|
|
90
|
-
upc: "214715",
|
|
91
|
-
id_article: 127595,
|
|
92
|
-
id_order: 8086
|
|
51
|
+
percentage: 100
|
|
93
52
|
},
|
|
94
53
|
productToEdit: {
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
product: {
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
retailerOrder: 0,
|
|
107
|
-
missing: {
|
|
108
|
-
datasheet: null,
|
|
109
|
-
descriptions: null,
|
|
110
|
-
images: null
|
|
111
|
-
},
|
|
112
|
-
services: {
|
|
113
|
-
datasheets: 1,
|
|
114
|
-
descriptions: 1,
|
|
115
|
-
images: 1
|
|
116
|
-
},
|
|
117
|
-
article: {
|
|
118
|
-
category: "Navidad|Decoración Interior|Mallas y Listones",
|
|
119
|
-
company_name: "THD IMPORTACIONES",
|
|
120
|
-
country: null,
|
|
121
|
-
id_category: "2902",
|
|
122
|
-
id_datasheet_especialist: 2757,
|
|
123
|
-
id_datasheet_facilitator: null,
|
|
124
|
-
id_description_especialist: 2757,
|
|
125
|
-
id_description_facilitator: null,
|
|
126
|
-
id_images_especialist: 1259,
|
|
127
|
-
id_images_facilitator: null,
|
|
128
|
-
id_order: 8086,
|
|
129
|
-
id_article: 127595,
|
|
130
|
-
id_auditor: 514,
|
|
131
|
-
name: "LISTON DECORATIVO DISNEY 5M 2 ESTILOS",
|
|
132
|
-
timestamp: "2024-06-05T14:30:33.000Z",
|
|
133
|
-
upc: "214715"
|
|
134
|
-
},
|
|
135
|
-
retailers: [{
|
|
136
|
-
id: 58
|
|
137
|
-
}],
|
|
138
|
-
statusByRetailer: {
|
|
139
|
-
"58": {
|
|
140
|
-
datasheet: "AA",
|
|
141
|
-
description: "AA",
|
|
142
|
-
images: "AA"
|
|
143
|
-
}
|
|
144
|
-
},
|
|
54
|
+
idCategory: 1139,
|
|
55
|
+
ArticleId: 128483,
|
|
56
|
+
product: [{
|
|
57
|
+
id_article: 128483,
|
|
58
|
+
upc: "1010101010122",
|
|
59
|
+
name: "Prueba 26-jun-24",
|
|
60
|
+
timestamp: "2024-06-26T17:06:17.000Z",
|
|
61
|
+
categoryName: "Audio|Audífonos|In Ear",
|
|
62
|
+
id_category: 1139,
|
|
63
|
+
version: 1,
|
|
64
|
+
reviewState: "rejected_to_provider",
|
|
145
65
|
retailersAvailable: [{
|
|
146
|
-
|
|
66
|
+
name: "Radioshack",
|
|
67
|
+
id: 74,
|
|
68
|
+
percentage: 100
|
|
147
69
|
}],
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
id_article: 127595,
|
|
151
|
-
id_order: 8086
|
|
152
|
-
}
|
|
70
|
+
percentage: 100
|
|
71
|
+
}]
|
|
153
72
|
},
|
|
154
73
|
location: {
|
|
155
74
|
pathname: "/EditProducts",
|
|
@@ -163,21 +82,21 @@ ProviderProductEditionDefault.args = {
|
|
|
163
82
|
key: "24vwut"
|
|
164
83
|
},
|
|
165
84
|
user: {
|
|
166
|
-
id_user:
|
|
85
|
+
id_user: 2130,
|
|
167
86
|
name: "Proveedor",
|
|
168
|
-
last_name: "
|
|
169
|
-
email: "
|
|
170
|
-
position: "
|
|
171
|
-
telephone: "
|
|
87
|
+
last_name: "Radioshack",
|
|
88
|
+
email: "proveedorradioshack@allfreemail.net",
|
|
89
|
+
position: "Onboarding",
|
|
90
|
+
telephone: "+5212345678978",
|
|
172
91
|
country: "México",
|
|
173
|
-
id_company:
|
|
174
|
-
id_cognito: "
|
|
175
|
-
birth_Date:
|
|
92
|
+
id_company: 1169,
|
|
93
|
+
id_cognito: "0bbc1bcb-282d-4cc6-b70e-05cacbbb5563",
|
|
94
|
+
birth_Date: null,
|
|
176
95
|
about_me: null,
|
|
177
|
-
zip_code:
|
|
178
|
-
address:
|
|
96
|
+
zip_code: null,
|
|
97
|
+
address: null,
|
|
179
98
|
job: null,
|
|
180
|
-
id_stripe:
|
|
99
|
+
id_stripe: null,
|
|
181
100
|
id_role: 0,
|
|
182
101
|
active: 1,
|
|
183
102
|
is_retailer: 0,
|
|
@@ -185,9 +104,9 @@ ProviderProductEditionDefault.args = {
|
|
|
185
104
|
is_user_tech: null,
|
|
186
105
|
is_onboarding: 0,
|
|
187
106
|
membership: {
|
|
188
|
-
id:
|
|
189
|
-
start_date: "
|
|
190
|
-
end_date: "
|
|
107
|
+
id: 1649,
|
|
108
|
+
start_date: "2023-11-09T19:57:43.000Z",
|
|
109
|
+
end_date: "2024-11-09T19:57:43.000Z",
|
|
191
110
|
planID: 8,
|
|
192
111
|
plan: "prod_KvGeJs0E9cSO4y",
|
|
193
112
|
name: "Plan Pro",
|
|
@@ -195,46 +114,30 @@ ProviderProductEditionDefault.args = {
|
|
|
195
114
|
products_limit: "5000",
|
|
196
115
|
type: "Enterprise"
|
|
197
116
|
},
|
|
198
|
-
src: "https://content-management-profile-prod.s3.amazonaws.com/id-
|
|
117
|
+
src: "https://content-management-profile-prod.s3.amazonaws.com/id-2130/2130.png?1719504850190"
|
|
199
118
|
},
|
|
200
119
|
company: {
|
|
201
|
-
id_company:
|
|
202
|
-
trade_name: "
|
|
203
|
-
company_name: "
|
|
204
|
-
rfc:
|
|
205
|
-
adress:
|
|
120
|
+
id_company: 1169,
|
|
121
|
+
trade_name: "Radioshack Onboarding",
|
|
122
|
+
company_name: "Onboarding",
|
|
123
|
+
rfc: "ASDASD",
|
|
124
|
+
adress: "CDMX",
|
|
206
125
|
about_company: null,
|
|
207
126
|
telephone: null,
|
|
208
127
|
web_site: null,
|
|
209
128
|
zip_code: null,
|
|
210
129
|
email: null,
|
|
211
130
|
social_link: null,
|
|
212
|
-
is_retailer:
|
|
131
|
+
is_retailer: 1,
|
|
213
132
|
financedRetailers: [{
|
|
214
|
-
id:
|
|
215
|
-
name: "
|
|
216
|
-
country: "México"
|
|
217
|
-
id_region: 1,
|
|
218
|
-
active: 1
|
|
219
|
-
}, {
|
|
220
|
-
id: 59,
|
|
221
|
-
name: "The Home Depot Platinum",
|
|
222
|
-
country: "México",
|
|
223
|
-
id_region: 1,
|
|
224
|
-
active: 1
|
|
133
|
+
id: 74,
|
|
134
|
+
name: "Radioshack",
|
|
135
|
+
country: "México"
|
|
225
136
|
}],
|
|
226
137
|
retailers: [{
|
|
227
|
-
id:
|
|
228
|
-
name: "
|
|
229
|
-
country: "México"
|
|
230
|
-
id_region: 1,
|
|
231
|
-
active: 1
|
|
232
|
-
}, {
|
|
233
|
-
id: 59,
|
|
234
|
-
name: "The Home Depot Platinum",
|
|
235
|
-
country: "México",
|
|
236
|
-
id_region: 1,
|
|
237
|
-
active: 1
|
|
138
|
+
id: 74,
|
|
139
|
+
name: "Radioshack",
|
|
140
|
+
country: "México"
|
|
238
141
|
}]
|
|
239
142
|
},
|
|
240
143
|
showSurvey: function showSurvey(v) {
|
package/package.json
CHANGED
|
@@ -37,7 +37,7 @@ export const InputGroup = ({
|
|
|
37
37
|
showDivState,
|
|
38
38
|
imageStates,
|
|
39
39
|
}) => (
|
|
40
|
-
<div style={{
|
|
40
|
+
<div style={{ display:'flex', alignItems:'center' }}>
|
|
41
41
|
<Tooltip
|
|
42
42
|
componentTooltip={
|
|
43
43
|
<>
|
|
@@ -174,7 +174,22 @@ export const InputGroup = ({
|
|
|
174
174
|
<div className="inputs-container">
|
|
175
175
|
{inputGroup?.inputs?.map((input, index) =>
|
|
176
176
|
activeSection === "Ficha técnica" ? (
|
|
177
|
-
|
|
177
|
+
<div className={
|
|
178
|
+
dataInputs[input]?.id === 6700 || dataInputs[input]?.id === 6701
|
|
179
|
+
? "inputs-validation-onboarding"
|
|
180
|
+
: ""
|
|
181
|
+
}>
|
|
182
|
+
{dataInputs[input]?.isApproved === false && (
|
|
183
|
+
<InputReviewSection
|
|
184
|
+
inputId={dataInputs[input]?.id}
|
|
185
|
+
isApproved={dataInputs[input]?.isApproved}
|
|
186
|
+
comment={dataInputs[input]?.comment}
|
|
187
|
+
handleImgClick={handleImgClick}
|
|
188
|
+
changeImageBtn={changeImageBtn}
|
|
189
|
+
showDivState={showDivStates}
|
|
190
|
+
imageStates={imageStates}
|
|
191
|
+
/>
|
|
192
|
+
)}
|
|
178
193
|
{((dataInputs[input]?.id!=6700 && dataInputs[input]?.id!=6701)
|
|
179
194
|
|| dataInputs[input]?.isApproved!=undefined) && (
|
|
180
195
|
<TagAndInput
|
|
@@ -225,19 +240,7 @@ export const InputGroup = ({
|
|
|
225
240
|
}
|
|
226
241
|
/>
|
|
227
242
|
)}
|
|
228
|
-
|
|
229
|
-
{dataInputs[input]?.isApproved === false && (
|
|
230
|
-
<InputReviewSection
|
|
231
|
-
inputId={dataInputs[input]?.id}
|
|
232
|
-
isApproved={dataInputs[input]?.isApproved}
|
|
233
|
-
comment={dataInputs[input]?.comment}
|
|
234
|
-
handleImgClick={handleImgClick}
|
|
235
|
-
changeImageBtn={changeImageBtn}
|
|
236
|
-
showDivState={showDivStates}
|
|
237
|
-
imageStates={imageStates}
|
|
238
|
-
/>
|
|
239
|
-
)}
|
|
240
|
-
</>
|
|
243
|
+
</div>
|
|
241
244
|
) : (
|
|
242
245
|
<>
|
|
243
246
|
{input?.isApproved === false && (
|
|
@@ -28,6 +28,18 @@ export const Container = styled.div`
|
|
|
28
28
|
flex-direction: column;
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
+
|
|
32
|
+
.inputs-validation-onboarding{
|
|
33
|
+
display: flex;
|
|
34
|
+
align-items: center;
|
|
35
|
+
gap:5px;
|
|
36
|
+
padding: 0px 5px;
|
|
37
|
+
//border: 1px solid #e33aa9;
|
|
38
|
+
// border-left: 1px solid #e33aa9;
|
|
39
|
+
// border-bottom: 1px solid #e33aa9;
|
|
40
|
+
border-radius: 6px;
|
|
41
|
+
position:relative;
|
|
42
|
+
}
|
|
31
43
|
}
|
|
32
44
|
|
|
33
45
|
& + * {
|
|
@@ -35,18 +47,22 @@ export const Container = styled.div`
|
|
|
35
47
|
}
|
|
36
48
|
|
|
37
49
|
.btnReviewState {
|
|
38
|
-
display:
|
|
39
|
-
flex-direction:
|
|
50
|
+
display: flex;
|
|
51
|
+
flex-direction: column;
|
|
40
52
|
border: 1px solid lightgray;
|
|
41
53
|
border-radius: 3px;
|
|
42
54
|
z-index: 1000;
|
|
43
|
-
|
|
55
|
+
position: absolute;
|
|
56
|
+
transform: translate(35%, 0);
|
|
44
57
|
}
|
|
45
58
|
|
|
46
59
|
.btnReviewState button {
|
|
60
|
+
display: flex;
|
|
61
|
+
align-items: center;
|
|
47
62
|
border: none;
|
|
48
63
|
background: white;
|
|
49
64
|
border-radius: 3px;
|
|
65
|
+
box-shadow: 2px 2px 2px lightgray;
|
|
50
66
|
}
|
|
51
67
|
.btnReviewState button:hover {
|
|
52
68
|
background: lightgray;
|
|
@@ -11,138 +11,55 @@ export const ProviderProductEditionDefault = Template.bind({});
|
|
|
11
11
|
|
|
12
12
|
ProviderProductEditionDefault.args = {
|
|
13
13
|
tabsSections: {
|
|
14
|
-
Descripción:
|
|
14
|
+
Descripción: false,
|
|
15
15
|
"Ficha técnica": true,
|
|
16
|
-
Imágenes:
|
|
16
|
+
Imágenes: false,
|
|
17
17
|
},
|
|
18
18
|
token:
|
|
19
|
-
"eyJraWQiOiJEV3owZnNieXg2MXNFcVduN3RCXC81bVhod3ZNbFZIOTgwUnZcL3RjT0lKdEk9IiwiYWxnIjoiUlMyNTYifQ.
|
|
20
|
-
articleId:
|
|
21
|
-
category: "
|
|
22
|
-
version:
|
|
19
|
+
"eyJraWQiOiJEV3owZnNieXg2MXNFcVduN3RCXC81bVhod3ZNbFZIOTgwUnZcL3RjT0lKdEk9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIwYmJjMWJjYi0yODJkLTRjYzYtYjcwZS0wNWNhY2JiYjU1NjMiLCJjb2duaXRvOmdyb3VwcyI6WyJ1c3VhcmlvX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfbFN6UVo0WjdSIiwicGhvbmVfbnVtYmVyX3ZlcmlmaWVkIjpmYWxzZSwiY29nbml0bzp1c2VybmFtZSI6IjBiYmMxYmNiLTI4MmQtNGNjNi1iNzBlLTA1Y2FjYmJiNTU2MyIsImF1ZCI6IjUyZDlza2tkY2c4cWpwODhvb2sxdXNlNm1rIiwiZXZlbnRfaWQiOiJmMTdlYTVlOS0wZmE2LTQ1YmUtYjE5MS1iNTViZjgxYWRiNzkiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTcxOTUwNDg0OSwibmFtZSI6IlByb3ZlZWRvciBSYWRpb3NoYWNrIiwicGhvbmVfbnVtYmVyIjoiKzUyMTIzNDU2Nzg5NzgiLCJleHAiOjE3MTk1MDg0NDksImlhdCI6MTcxOTUwNDg0OSwiZW1haWwiOiJwcm92ZWVkb3JyYWRpb3NoYWNrQGFsbGZyZWVtYWlsLm5ldCJ9.M0Pm70YhdG1JARzamruJKSzJPjGl_tXAYCwQHGiIRYLHo4X05B95VgCLXVvetadrH7dsp6PviJ3MuF2JPzBVXMAP_N26zSeJFIx1ywqVp-nehwE3TUiF8L0P_MTLCBJzHcHf41HzTDHr546nBBgF64W3bZNd_J-jSFW3xZxgu6dq_RZ5fywVlzs6sZgDAenOtzcB9-Ig97mpdTil8ag8wgbf2LlcypaWGsEESbHhus-_hx58tosjwQ_a0rvsz47X9HI9YMe6rD0xFR9cQCub6WG7d65fMyqaCl-X4DsFE1a4z2AnWcmgXmAdwZTqCjvo8TPKJjxMBvptlShL753UaQ",
|
|
20
|
+
articleId: 128483,
|
|
21
|
+
category: "1139",
|
|
22
|
+
version: 1,
|
|
23
23
|
productSelected: {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
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: "Navidad|Decoración Interior|Mallas y Listones",
|
|
45
|
-
company_name: "THD IMPORTACIONES",
|
|
46
|
-
country: null,
|
|
47
|
-
id_category: "2902",
|
|
48
|
-
id_datasheet_especialist: 2757,
|
|
49
|
-
id_datasheet_facilitator: null,
|
|
50
|
-
id_description_especialist: 2757,
|
|
51
|
-
id_description_facilitator: null,
|
|
52
|
-
id_images_especialist: 1259,
|
|
53
|
-
id_images_facilitator: null,
|
|
54
|
-
id_order: 8086,
|
|
55
|
-
id_article: 127595,
|
|
56
|
-
id_auditor: 514,
|
|
57
|
-
name: "LISTON DECORATIVO DISNEY 5M 2 ESTILOS",
|
|
58
|
-
timestamp: "2024-06-05T14:30:33.000Z",
|
|
59
|
-
upc: "214715",
|
|
60
|
-
},
|
|
61
|
-
retailers: [
|
|
62
|
-
{
|
|
63
|
-
id: 58,
|
|
64
|
-
},
|
|
65
|
-
],
|
|
66
|
-
statusByRetailer: {
|
|
67
|
-
"58": {
|
|
68
|
-
datasheet: "AA",
|
|
69
|
-
description: "AA",
|
|
70
|
-
images: "AA",
|
|
71
|
-
},
|
|
72
|
-
},
|
|
24
|
+
id_article: 128483,
|
|
25
|
+
upc: "1010101010122",
|
|
26
|
+
name: "Prueba 26-jun-24",
|
|
27
|
+
timestamp: "2024-06-26T17:06:17.000Z",
|
|
28
|
+
categoryName: "Audio|Audífonos|In Ear",
|
|
29
|
+
id_category: 1139,
|
|
30
|
+
version: 1,
|
|
31
|
+
reviewState: "rejected_to_provider",
|
|
73
32
|
retailersAvailable: [
|
|
74
33
|
{
|
|
75
|
-
|
|
34
|
+
name: "Radioshack",
|
|
35
|
+
id: 74,
|
|
76
36
|
},
|
|
77
37
|
],
|
|
78
|
-
|
|
79
|
-
upc: "214715",
|
|
80
|
-
id_article: 127595,
|
|
81
|
-
id_order: 8086,
|
|
38
|
+
percentage: 100,
|
|
82
39
|
},
|
|
83
40
|
productToEdit: {
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
product:
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
images: 1,
|
|
105
|
-
},
|
|
106
|
-
article: {
|
|
107
|
-
category: "Navidad|Decoración Interior|Mallas y Listones",
|
|
108
|
-
company_name: "THD IMPORTACIONES",
|
|
109
|
-
country: null,
|
|
110
|
-
id_category: "2902",
|
|
111
|
-
id_datasheet_especialist: 2757,
|
|
112
|
-
id_datasheet_facilitator: null,
|
|
113
|
-
id_description_especialist: 2757,
|
|
114
|
-
id_description_facilitator: null,
|
|
115
|
-
id_images_especialist: 1259,
|
|
116
|
-
id_images_facilitator: null,
|
|
117
|
-
id_order: 8086,
|
|
118
|
-
id_article: 127595,
|
|
119
|
-
id_auditor: 514,
|
|
120
|
-
name: "LISTON DECORATIVO DISNEY 5M 2 ESTILOS",
|
|
121
|
-
timestamp: "2024-06-05T14:30:33.000Z",
|
|
122
|
-
upc: "214715",
|
|
123
|
-
},
|
|
124
|
-
retailers: [
|
|
125
|
-
{
|
|
126
|
-
id: 58,
|
|
127
|
-
},
|
|
128
|
-
],
|
|
129
|
-
statusByRetailer: {
|
|
130
|
-
"58": {
|
|
131
|
-
datasheet: "AA",
|
|
132
|
-
description: "AA",
|
|
133
|
-
images: "AA",
|
|
134
|
-
},
|
|
41
|
+
idCategory: 1139,
|
|
42
|
+
ArticleId: 128483,
|
|
43
|
+
product: [
|
|
44
|
+
{
|
|
45
|
+
id_article: 128483,
|
|
46
|
+
upc: "1010101010122",
|
|
47
|
+
name: "Prueba 26-jun-24",
|
|
48
|
+
timestamp: "2024-06-26T17:06:17.000Z",
|
|
49
|
+
categoryName: "Audio|Audífonos|In Ear",
|
|
50
|
+
id_category: 1139,
|
|
51
|
+
version: 1,
|
|
52
|
+
reviewState: "rejected_to_provider",
|
|
53
|
+
retailersAvailable: [
|
|
54
|
+
{
|
|
55
|
+
name: "Radioshack",
|
|
56
|
+
id: 74,
|
|
57
|
+
percentage: 100,
|
|
58
|
+
},
|
|
59
|
+
],
|
|
60
|
+
percentage: 100,
|
|
135
61
|
},
|
|
136
|
-
|
|
137
|
-
{
|
|
138
|
-
id: 58,
|
|
139
|
-
},
|
|
140
|
-
],
|
|
141
|
-
categoryName: "Navidad|Decoración Interior|Mallas y Listones",
|
|
142
|
-
upc: "214715",
|
|
143
|
-
id_article: 127595,
|
|
144
|
-
id_order: 8086,
|
|
145
|
-
},
|
|
62
|
+
],
|
|
146
63
|
},
|
|
147
64
|
location: {
|
|
148
65
|
pathname: "/EditProducts",
|
|
@@ -156,21 +73,21 @@ ProviderProductEditionDefault.args = {
|
|
|
156
73
|
key: "24vwut",
|
|
157
74
|
},
|
|
158
75
|
user: {
|
|
159
|
-
id_user:
|
|
76
|
+
id_user: 2130,
|
|
160
77
|
name: "Proveedor",
|
|
161
|
-
last_name: "
|
|
162
|
-
email: "
|
|
163
|
-
position: "
|
|
164
|
-
telephone: "
|
|
78
|
+
last_name: "Radioshack",
|
|
79
|
+
email: "proveedorradioshack@allfreemail.net",
|
|
80
|
+
position: "Onboarding",
|
|
81
|
+
telephone: "+5212345678978",
|
|
165
82
|
country: "México",
|
|
166
|
-
id_company:
|
|
167
|
-
id_cognito: "
|
|
168
|
-
birth_Date:
|
|
83
|
+
id_company: 1169,
|
|
84
|
+
id_cognito: "0bbc1bcb-282d-4cc6-b70e-05cacbbb5563",
|
|
85
|
+
birth_Date: null,
|
|
169
86
|
about_me: null,
|
|
170
|
-
zip_code:
|
|
171
|
-
address:
|
|
87
|
+
zip_code: null,
|
|
88
|
+
address: null,
|
|
172
89
|
job: null,
|
|
173
|
-
id_stripe:
|
|
90
|
+
id_stripe: null,
|
|
174
91
|
id_role: 0,
|
|
175
92
|
active: 1,
|
|
176
93
|
is_retailer: 0,
|
|
@@ -178,9 +95,9 @@ ProviderProductEditionDefault.args = {
|
|
|
178
95
|
is_user_tech: null,
|
|
179
96
|
is_onboarding: 0,
|
|
180
97
|
membership: {
|
|
181
|
-
id:
|
|
182
|
-
start_date: "
|
|
183
|
-
end_date: "
|
|
98
|
+
id: 1649,
|
|
99
|
+
start_date: "2023-11-09T19:57:43.000Z",
|
|
100
|
+
end_date: "2024-11-09T19:57:43.000Z",
|
|
184
101
|
planID: 8,
|
|
185
102
|
plan: "prod_KvGeJs0E9cSO4y",
|
|
186
103
|
name: "Plan Pro",
|
|
@@ -188,51 +105,33 @@ ProviderProductEditionDefault.args = {
|
|
|
188
105
|
products_limit: "5000",
|
|
189
106
|
type: "Enterprise",
|
|
190
107
|
},
|
|
191
|
-
src: "https://content-management-profile-prod.s3.amazonaws.com/id-
|
|
108
|
+
src: "https://content-management-profile-prod.s3.amazonaws.com/id-2130/2130.png?1719504850190",
|
|
192
109
|
},
|
|
193
110
|
company: {
|
|
194
|
-
id_company:
|
|
195
|
-
trade_name: "
|
|
196
|
-
company_name: "
|
|
197
|
-
rfc:
|
|
198
|
-
adress:
|
|
111
|
+
id_company: 1169,
|
|
112
|
+
trade_name: "Radioshack Onboarding",
|
|
113
|
+
company_name: "Onboarding",
|
|
114
|
+
rfc: "ASDASD",
|
|
115
|
+
adress: "CDMX",
|
|
199
116
|
about_company: null,
|
|
200
117
|
telephone: null,
|
|
201
118
|
web_site: null,
|
|
202
119
|
zip_code: null,
|
|
203
120
|
email: null,
|
|
204
121
|
social_link: null,
|
|
205
|
-
is_retailer:
|
|
122
|
+
is_retailer: 1,
|
|
206
123
|
financedRetailers: [
|
|
207
124
|
{
|
|
208
|
-
id:
|
|
209
|
-
name: "
|
|
125
|
+
id: 74,
|
|
126
|
+
name: "Radioshack",
|
|
210
127
|
country: "México",
|
|
211
|
-
id_region: 1,
|
|
212
|
-
active: 1,
|
|
213
|
-
},
|
|
214
|
-
{
|
|
215
|
-
id: 59,
|
|
216
|
-
name: "The Home Depot Platinum",
|
|
217
|
-
country: "México",
|
|
218
|
-
id_region: 1,
|
|
219
|
-
active: 1,
|
|
220
128
|
},
|
|
221
129
|
],
|
|
222
130
|
retailers: [
|
|
223
131
|
{
|
|
224
|
-
id:
|
|
225
|
-
name: "
|
|
226
|
-
country: "México",
|
|
227
|
-
id_region: 1,
|
|
228
|
-
active: 1,
|
|
229
|
-
},
|
|
230
|
-
{
|
|
231
|
-
id: 59,
|
|
232
|
-
name: "The Home Depot Platinum",
|
|
132
|
+
id: 74,
|
|
133
|
+
name: "Radioshack",
|
|
233
134
|
country: "México",
|
|
234
|
-
id_region: 1,
|
|
235
|
-
active: 1,
|
|
236
135
|
},
|
|
237
136
|
],
|
|
238
137
|
},
|