contentoh-components-library 21.2.8 → 21.2.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/pages/ProviderProductEdition/index.js +30 -27
- package/dist/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +55 -49
- package/dist/components/pages/RetailerProductEdition/index.js +3 -3
- package/package.json +1 -1
- package/src/components/pages/ProviderProductEdition/index.js +12 -16
- package/src/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +59 -52
- package/src/components/pages/RetailerProductEdition/index.js +5 -5
|
@@ -1509,7 +1509,7 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
1509
1509
|
|
|
1510
1510
|
var validateAll = /*#__PURE__*/function () {
|
|
1511
1511
|
var _ref14 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee13(result) {
|
|
1512
|
-
var _product$id_order2, evaluationArray,
|
|
1512
|
+
var _product$id_order2, evaluationArray, conceptArray, dataGeneral, evalResponse, userType, productTemp, retailerStatusCopy;
|
|
1513
1513
|
|
|
1514
1514
|
return _regenerator.default.wrap(function _callee13$(_context13) {
|
|
1515
1515
|
while (1) {
|
|
@@ -1518,17 +1518,18 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
1518
1518
|
_context13.prev = 0;
|
|
1519
1519
|
setLoading(true);
|
|
1520
1520
|
evaluationArray = [];
|
|
1521
|
-
sendAll = [];
|
|
1522
1521
|
conceptArray = ["description", "datasheet", "images"];
|
|
1523
1522
|
dataGeneral = {
|
|
1524
1523
|
articleId: product.id_article,
|
|
1525
1524
|
orderId: (_product$id_order2 = product.id_order) !== null && _product$id_order2 !== void 0 ? _product$id_order2 : product.orderId,
|
|
1526
|
-
result: result
|
|
1525
|
+
result: result,
|
|
1526
|
+
isAproved: result === "A"
|
|
1527
1527
|
};
|
|
1528
1528
|
servicesData === null || servicesData === void 0 ? void 0 : servicesData.forEach(function (ret) {
|
|
1529
1529
|
var service = ret.service,
|
|
1530
1530
|
id_retailer = ret.id_retailer;
|
|
1531
|
-
var data =
|
|
1531
|
+
var data = {};
|
|
1532
|
+
data = (0, _objectSpread3.default)((0, _objectSpread3.default)({}, dataGeneral), {}, {
|
|
1532
1533
|
concept: service,
|
|
1533
1534
|
retailerId: id_retailer,
|
|
1534
1535
|
evalStatus: retailerStatus[id_retailer][service]
|
|
@@ -1538,26 +1539,27 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
1538
1539
|
Authorization: token
|
|
1539
1540
|
}
|
|
1540
1541
|
}));
|
|
1541
|
-
sendAll.push(_axios.default.put("".concat(process.env.REACT_APP_SEND_EVAL), data, {
|
|
1542
|
-
headers: {
|
|
1543
|
-
Authorization: token
|
|
1544
|
-
}
|
|
1545
|
-
}));
|
|
1546
1542
|
});
|
|
1547
|
-
_context13.next =
|
|
1548
|
-
return Promise.all(
|
|
1543
|
+
_context13.next = 8;
|
|
1544
|
+
return Promise.all(evaluationArray);
|
|
1549
1545
|
|
|
1550
|
-
case
|
|
1546
|
+
case 8:
|
|
1547
|
+
evalResponse = _context13.sent;
|
|
1548
|
+
console.log(evalResponse.map(function (_ref15) {
|
|
1549
|
+
var data = _ref15.data;
|
|
1550
|
+
return JSON.parse(data.body);
|
|
1551
|
+
}));
|
|
1552
|
+
userType = user.is_retailer === 1 ? "CA" : "P";
|
|
1551
1553
|
productTemp = product;
|
|
1552
|
-
productTemp.article_status = "".concat(result
|
|
1553
|
-
productTemp.datasheet_status = productTemp.datasheet_status === "NA" ? "NA" : "".concat(result
|
|
1554
|
-
productTemp.description_status = productTemp.description_status === "NA" ? "NA" : "".concat(result
|
|
1555
|
-
productTemp.images_status = productTemp.images_status === "NA" ? "NA" : "".concat(result
|
|
1554
|
+
productTemp.article_status = "".concat(result).concat(userType);
|
|
1555
|
+
productTemp.datasheet_status = productTemp.datasheet_status === "NA" ? "NA" : "".concat(result).concat(userType);
|
|
1556
|
+
productTemp.description_status = productTemp.description_status === "NA" ? "NA" : "".concat(result).concat(userType);
|
|
1557
|
+
productTemp.images_status = productTemp.images_status === "NA" ? "NA" : "".concat(result).concat(userType);
|
|
1556
1558
|
retailerStatusCopy = (0, _objectSpread3.default)({}, retailerStatus);
|
|
1557
1559
|
Object.keys(retailerStatusCopy).forEach(function (key) {
|
|
1558
1560
|
conceptArray.forEach(function (concept) {
|
|
1559
1561
|
if (retailerStatusCopy[key][concept]) {
|
|
1560
|
-
retailerStatusCopy[key][concept] = "".concat(result
|
|
1562
|
+
retailerStatusCopy[key][concept] = "".concat(result).concat(userType);
|
|
1561
1563
|
}
|
|
1562
1564
|
});
|
|
1563
1565
|
});
|
|
@@ -1575,24 +1577,24 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
1575
1577
|
idCategory: productTemp.article.id_category,
|
|
1576
1578
|
product: productTemp
|
|
1577
1579
|
}));
|
|
1578
|
-
_context13.next =
|
|
1580
|
+
_context13.next = 26;
|
|
1579
1581
|
return loadData();
|
|
1580
1582
|
|
|
1581
|
-
case
|
|
1582
|
-
_context13.next =
|
|
1583
|
+
case 26:
|
|
1584
|
+
_context13.next = 31;
|
|
1583
1585
|
break;
|
|
1584
1586
|
|
|
1585
|
-
case
|
|
1586
|
-
_context13.prev =
|
|
1587
|
+
case 28:
|
|
1588
|
+
_context13.prev = 28;
|
|
1587
1589
|
_context13.t0 = _context13["catch"](0);
|
|
1588
1590
|
console.log(_context13.t0);
|
|
1589
1591
|
|
|
1590
|
-
case
|
|
1592
|
+
case 31:
|
|
1591
1593
|
case "end":
|
|
1592
1594
|
return _context13.stop();
|
|
1593
1595
|
}
|
|
1594
1596
|
}
|
|
1595
|
-
}, _callee13, null, [[0,
|
|
1597
|
+
}, _callee13, null, [[0, 28]]);
|
|
1596
1598
|
}));
|
|
1597
1599
|
|
|
1598
1600
|
return function validateAll(_x8) {
|
|
@@ -1601,7 +1603,7 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
1601
1603
|
}();
|
|
1602
1604
|
|
|
1603
1605
|
var evaluationToRetailer = /*#__PURE__*/function () {
|
|
1604
|
-
var
|
|
1606
|
+
var _ref16 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee14(result) {
|
|
1605
1607
|
var data, prod, statusComplete;
|
|
1606
1608
|
return _regenerator.default.wrap(function _callee14$(_context14) {
|
|
1607
1609
|
while (1) {
|
|
@@ -1643,7 +1645,7 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
1643
1645
|
}));
|
|
1644
1646
|
|
|
1645
1647
|
return function evaluationToRetailer(_x9) {
|
|
1646
|
-
return
|
|
1648
|
+
return _ref16.apply(this, arguments);
|
|
1647
1649
|
};
|
|
1648
1650
|
}();
|
|
1649
1651
|
|
|
@@ -2069,7 +2071,8 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
2069
2071
|
setVersion: setVersion,
|
|
2070
2072
|
companyName: company.company_name,
|
|
2071
2073
|
currentVersion: version,
|
|
2072
|
-
setShowCreateVersion: setShowCreateVersion
|
|
2074
|
+
setShowCreateVersion: setShowCreateVersion,
|
|
2075
|
+
setShowVersionSelector: setShowVersionSelector
|
|
2073
2076
|
}), showCreateVersion && /*#__PURE__*/(0, _jsxRuntime.jsx)(_CreateVersion.CreateVersion, {
|
|
2074
2077
|
idArticle: product.id_article,
|
|
2075
2078
|
version: version,
|
|
@@ -33,57 +33,63 @@ RetailerProductEditionDefault.args = {
|
|
|
33
33
|
},
|
|
34
34
|
token: "eyJraWQiOiJEV3owZnNieXg2MXNFcVduN3RCXC81bVhod3ZNbFZIOTgwUnZcL3RjT0lKdEk9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIwYjY2YTRhOS03NzkwLTQwMzQtYTMwYS1jMDA4MDg5NjI4NjciLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfbFN6UVo0WjdSIiwiY29nbml0bzp1c2VybmFtZSI6IjBiNjZhNGE5LTc3OTAtNDAzNC1hMzBhLWMwMDgwODk2Mjg2NyIsImF1ZCI6IjUyZDlza2tkY2c4cWpwODhvb2sxdXNlNm1rIiwiZXZlbnRfaWQiOiIzNmIxMmUwMy0xOWJhLTRiMDktYWJiYS1kZjk3ZTFkNThjZTQiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY2MDE4MjgzNywibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY2MDE4NjQzNywiaWF0IjoxNjYwMTgyODM3LCJlbWFpbCI6ImJheWFkaTE1MzhAbW5xbG0uY29tIn0.MM9nIHkrRIS2o8_s4BR6VTLgyw3ryvPrr-mf6RtnQ4smng2Q3fmtK07zInNcvcrv8EXO5J9z47_NZ5MOJDo1Pz1CV2cOYM7PT5tEn3F-W4SitqDbBw3KxfkqSMxdZUIHLWECGL-u2ATCYU2J4KRVQi8XSP1qbfv1hu9dh-vID8Fq641ccQwEqUDC13pshDPlR08legg7AAPJqoilV7wuvxqTYAK6fGqMS5jcdW2iDmU0ti9gkydXkYRIC-jg446VOmRCpwzKsk4UAPwlrGeodQ0LV1bfWn_-KVspWCRQd6U5WbFxHn0umYe3CvvPpyVmHzD3F_EMxaVyqV5aW5IoIQ",
|
|
35
35
|
productSelected: {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
36
|
+
services: {
|
|
37
|
+
datasheets: 1,
|
|
38
|
+
descriptions: 1,
|
|
39
|
+
images: 1
|
|
40
40
|
},
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
41
|
+
orderId: 2611,
|
|
42
|
+
status: "CA",
|
|
43
|
+
datasheet_status: "CA",
|
|
44
|
+
prio: "none",
|
|
45
|
+
version: 2,
|
|
46
|
+
description_status: "CA",
|
|
47
|
+
images_status: "IE",
|
|
48
|
+
article: {
|
|
49
|
+
id_article: 79722,
|
|
50
|
+
id_category: "165",
|
|
51
|
+
name: "FS SUAVITEL Utra 8L CLB",
|
|
52
|
+
upc: "7509546684116",
|
|
53
|
+
timestamp: "2022-08-22T18:59:35.000Z",
|
|
54
|
+
id_user: 1258,
|
|
55
|
+
status: "NULL",
|
|
56
|
+
active: 1,
|
|
57
|
+
company_id: 226,
|
|
58
|
+
SKU: null,
|
|
59
|
+
Descripcion: null,
|
|
60
|
+
Proveedor: null,
|
|
61
|
+
id_proveedor: 0,
|
|
62
|
+
company_name: "COLGATE PALMOLIVE S.A. DE C.V.",
|
|
63
|
+
country: null,
|
|
64
|
+
id_order: 2611,
|
|
65
|
+
id_datasheet_especialist: 334,
|
|
66
|
+
id_datasheet_facilitator: 158,
|
|
67
|
+
id_description_especialist: 334,
|
|
68
|
+
id_description_facilitator: 158,
|
|
69
|
+
id_images_especialist: 366,
|
|
70
|
+
id_images_facilitator: 160,
|
|
71
|
+
id_auditor: 9,
|
|
72
|
+
id_recepcionist: null,
|
|
73
|
+
category: "Consumibles|Productos de Limpieza y Lavandería|Suavizantes",
|
|
74
|
+
missingAttributes: -44,
|
|
75
|
+
missingDescriptions: 0,
|
|
76
|
+
missingImages: 8
|
|
77
77
|
},
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
78
|
+
retailers: [{
|
|
79
|
+
id: 3,
|
|
80
|
+
name: "Sam´s Club",
|
|
81
|
+
country: "México",
|
|
82
|
+
id_region: 1,
|
|
83
|
+
active: 1
|
|
84
|
+
}, {
|
|
85
|
+
id: 43,
|
|
86
|
+
name: "City Club",
|
|
87
|
+
country: "México",
|
|
88
|
+
id_region: 1,
|
|
89
|
+
active: 1
|
|
84
90
|
}],
|
|
85
|
-
|
|
86
|
-
|
|
91
|
+
country: null,
|
|
92
|
+
upc: "7509546684116"
|
|
87
93
|
},
|
|
88
94
|
location: {
|
|
89
95
|
product: {
|
|
@@ -92,7 +98,7 @@ RetailerProductEditionDefault.args = {
|
|
|
92
98
|
}
|
|
93
99
|
},
|
|
94
100
|
user: {
|
|
95
|
-
id_user:
|
|
101
|
+
id_user: 334,
|
|
96
102
|
name: "Facilitador Textos",
|
|
97
103
|
last_name: " ",
|
|
98
104
|
email: "bayadi1538@mnqlm.com",
|
|
@@ -1098,11 +1098,11 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
|
|
|
1098
1098
|
switch (userId) {
|
|
1099
1099
|
case 7:
|
|
1100
1100
|
case 8:
|
|
1101
|
-
return statusArray.includes(srvActive) &&
|
|
1101
|
+
return statusArray.includes(srvActive) && statusArray.includes(product === null || product === void 0 ? void 0 : product.status) || srv.filter(function (serv) {
|
|
1102
1102
|
var _serv$status;
|
|
1103
1103
|
|
|
1104
|
-
return
|
|
1105
|
-
}).length === srv.length
|
|
1104
|
+
return statusArray.includes((_serv$status = serv.status) === null || _serv$status === void 0 ? void 0 : _serv$status.replace(/.*\//, ""));
|
|
1105
|
+
}).length === srv.length;
|
|
1106
1106
|
|
|
1107
1107
|
case 4:
|
|
1108
1108
|
case 5:
|
package/package.json
CHANGED
|
@@ -913,16 +913,17 @@ export const ProviderProductEdition = ({
|
|
|
913
913
|
try {
|
|
914
914
|
setLoading(true);
|
|
915
915
|
const evaluationArray = [];
|
|
916
|
-
const sendAll = [];
|
|
917
916
|
const conceptArray = ["description", "datasheet", "images"];
|
|
918
917
|
const dataGeneral = {
|
|
919
918
|
articleId: product.id_article,
|
|
920
919
|
orderId: product.id_order ?? product.orderId,
|
|
921
920
|
result,
|
|
921
|
+
isAproved: result === "A",
|
|
922
922
|
};
|
|
923
923
|
servicesData?.forEach((ret) => {
|
|
924
924
|
const { service, id_retailer } = ret;
|
|
925
|
-
|
|
925
|
+
let data = {};
|
|
926
|
+
data = {
|
|
926
927
|
...dataGeneral,
|
|
927
928
|
concept: service,
|
|
928
929
|
retailerId: id_retailer,
|
|
@@ -935,31 +936,25 @@ export const ProviderProductEdition = ({
|
|
|
935
936
|
},
|
|
936
937
|
})
|
|
937
938
|
);
|
|
938
|
-
sendAll.push(
|
|
939
|
-
axios.put(`${process.env.REACT_APP_SEND_EVAL}`, data, {
|
|
940
|
-
headers: {
|
|
941
|
-
Authorization: token,
|
|
942
|
-
},
|
|
943
|
-
})
|
|
944
|
-
);
|
|
945
939
|
});
|
|
946
|
-
|
|
947
|
-
|
|
940
|
+
const evalResponse = await Promise.all(evaluationArray);
|
|
941
|
+
console.log(evalResponse.map(({ data }) => JSON.parse(data.body)));
|
|
942
|
+
const userType = user.is_retailer === 1 ? "CA" : "P";
|
|
948
943
|
|
|
949
944
|
const productTemp = product;
|
|
950
|
-
productTemp.article_status = `${result}
|
|
945
|
+
productTemp.article_status = `${result}${userType}`;
|
|
951
946
|
productTemp.datasheet_status =
|
|
952
|
-
productTemp.datasheet_status === "NA" ? "NA" : `${result}
|
|
947
|
+
productTemp.datasheet_status === "NA" ? "NA" : `${result}${userType}`;
|
|
953
948
|
productTemp.description_status =
|
|
954
|
-
productTemp.description_status === "NA" ? "NA" : `${result}
|
|
949
|
+
productTemp.description_status === "NA" ? "NA" : `${result}${userType}`;
|
|
955
950
|
productTemp.images_status =
|
|
956
|
-
productTemp.images_status === "NA" ? "NA" : `${result}
|
|
951
|
+
productTemp.images_status === "NA" ? "NA" : `${result}${userType}`;
|
|
957
952
|
|
|
958
953
|
const retailerStatusCopy = { ...retailerStatus };
|
|
959
954
|
Object.keys(retailerStatusCopy).forEach((key) => {
|
|
960
955
|
conceptArray.forEach((concept) => {
|
|
961
956
|
if (retailerStatusCopy[key][concept]) {
|
|
962
|
-
retailerStatusCopy[key][concept] = `${result}
|
|
957
|
+
retailerStatusCopy[key][concept] = `${result}${userType}`;
|
|
963
958
|
}
|
|
964
959
|
});
|
|
965
960
|
});
|
|
@@ -1494,6 +1489,7 @@ export const ProviderProductEdition = ({
|
|
|
1494
1489
|
companyName={company.company_name}
|
|
1495
1490
|
currentVersion={version}
|
|
1496
1491
|
setShowCreateVersion={setShowCreateVersion}
|
|
1492
|
+
setShowVersionSelector={setShowVersionSelector}
|
|
1497
1493
|
/>
|
|
1498
1494
|
)}
|
|
1499
1495
|
{showCreateVersion && (
|
|
@@ -18,65 +18,72 @@ RetailerProductEditionDefault.args = {
|
|
|
18
18
|
token:
|
|
19
19
|
"eyJraWQiOiJEV3owZnNieXg2MXNFcVduN3RCXC81bVhod3ZNbFZIOTgwUnZcL3RjT0lKdEk9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIwYjY2YTRhOS03NzkwLTQwMzQtYTMwYS1jMDA4MDg5NjI4NjciLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfbFN6UVo0WjdSIiwiY29nbml0bzp1c2VybmFtZSI6IjBiNjZhNGE5LTc3OTAtNDAzNC1hMzBhLWMwMDgwODk2Mjg2NyIsImF1ZCI6IjUyZDlza2tkY2c4cWpwODhvb2sxdXNlNm1rIiwiZXZlbnRfaWQiOiIzNmIxMmUwMy0xOWJhLTRiMDktYWJiYS1kZjk3ZTFkNThjZTQiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY2MDE4MjgzNywibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY2MDE4NjQzNywiaWF0IjoxNjYwMTgyODM3LCJlbWFpbCI6ImJheWFkaTE1MzhAbW5xbG0uY29tIn0.MM9nIHkrRIS2o8_s4BR6VTLgyw3ryvPrr-mf6RtnQ4smng2Q3fmtK07zInNcvcrv8EXO5J9z47_NZ5MOJDo1Pz1CV2cOYM7PT5tEn3F-W4SitqDbBw3KxfkqSMxdZUIHLWECGL-u2ATCYU2J4KRVQi8XSP1qbfv1hu9dh-vID8Fq641ccQwEqUDC13pshDPlR08legg7AAPJqoilV7wuvxqTYAK6fGqMS5jcdW2iDmU0ti9gkydXkYRIC-jg446VOmRCpwzKsk4UAPwlrGeodQ0LV1bfWn_-KVspWCRQd6U5WbFxHn0umYe3CvvPpyVmHzD3F_EMxaVyqV5aW5IoIQ",
|
|
20
20
|
productSelected: {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
services: {
|
|
22
|
+
datasheets: 1,
|
|
23
|
+
descriptions: 1,
|
|
24
|
+
images: 1,
|
|
25
25
|
},
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
26
|
+
orderId: 2611,
|
|
27
|
+
status: "CA",
|
|
28
|
+
datasheet_status: "CA",
|
|
29
|
+
prio: "none",
|
|
30
|
+
version: 2,
|
|
31
|
+
description_status: "CA",
|
|
32
|
+
images_status: "IE",
|
|
33
|
+
article: {
|
|
34
|
+
id_article: 79722,
|
|
35
|
+
id_category: "165",
|
|
36
|
+
name: "FS SUAVITEL Utra 8L CLB",
|
|
37
|
+
upc: "7509546684116",
|
|
38
|
+
timestamp: "2022-08-22T18:59:35.000Z",
|
|
39
|
+
id_user: 1258,
|
|
40
|
+
status: "NULL",
|
|
41
|
+
active: 1,
|
|
42
|
+
company_id: 226,
|
|
43
|
+
SKU: null,
|
|
44
|
+
Descripcion: null,
|
|
45
|
+
Proveedor: null,
|
|
46
|
+
id_proveedor: 0,
|
|
47
|
+
company_name: "COLGATE PALMOLIVE S.A. DE C.V.",
|
|
48
|
+
country: null,
|
|
49
|
+
id_order: 2611,
|
|
50
|
+
id_datasheet_especialist: 334,
|
|
51
|
+
id_datasheet_facilitator: 158,
|
|
52
|
+
id_description_especialist: 334,
|
|
53
|
+
id_description_facilitator: 158,
|
|
54
|
+
id_images_especialist: 366,
|
|
55
|
+
id_images_facilitator: 160,
|
|
56
|
+
id_auditor: 9,
|
|
57
|
+
id_recepcionist: null,
|
|
58
|
+
category: "Consumibles|Productos de Limpieza y Lavandería|Suavizantes",
|
|
59
|
+
missingAttributes: -44,
|
|
60
|
+
missingDescriptions: 0,
|
|
61
|
+
missingImages: 8,
|
|
62
62
|
},
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
63
|
+
retailers: [
|
|
64
|
+
{
|
|
65
|
+
id: 3,
|
|
66
|
+
name: "Sam´s Club",
|
|
67
|
+
country: "México",
|
|
68
|
+
id_region: 1,
|
|
69
|
+
active: 1,
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
id: 43,
|
|
73
|
+
name: "City Club",
|
|
74
|
+
country: "México",
|
|
75
|
+
id_region: 1,
|
|
76
|
+
active: 1,
|
|
77
|
+
},
|
|
71
78
|
],
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
},
|
|
79
|
+
country: null,
|
|
80
|
+
upc: "7509546684116",
|
|
81
|
+
},
|
|
75
82
|
location: {
|
|
76
83
|
product: { articleId: 109485, versionId: 3 },
|
|
77
84
|
},
|
|
78
85
|
user: {
|
|
79
|
-
id_user:
|
|
86
|
+
id_user: 334,
|
|
80
87
|
name: "Facilitador Textos",
|
|
81
88
|
last_name: " ",
|
|
82
89
|
email: "bayadi1538@mnqlm.com",
|
|
@@ -645,11 +645,11 @@ export const RetailerProductEdition = ({
|
|
|
645
645
|
case 7:
|
|
646
646
|
case 8:
|
|
647
647
|
return (
|
|
648
|
-
statusArray.includes(srvActive) &&
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
648
|
+
(statusArray.includes(srvActive) &&
|
|
649
|
+
statusArray.includes(product?.status)) ||
|
|
650
|
+
srv.filter((serv) =>
|
|
651
|
+
statusArray.includes(serv.status?.replace(/.*\//, ""))
|
|
652
|
+
).length === srv.length
|
|
653
653
|
);
|
|
654
654
|
case 4:
|
|
655
655
|
case 5:
|