contentoh-components-library 21.4.67 → 21.4.68
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/atoms/Avatar/index.js +2 -3
- package/dist/components/atoms/CheckBox/styles.js +1 -1
- package/dist/components/atoms/InputFormatter/styles.js +1 -1
- package/dist/components/atoms/SliderToolTip/styles.js +1 -1
- package/dist/components/molecules/BoxAttribute/index.js +3 -3
- package/dist/components/molecules/BoxAttribute/styles.js +1 -1
- package/dist/components/molecules/BoxButtons/index.js +1 -0
- package/dist/components/molecules/CarouselImagesLogin/index.js +1 -1
- package/dist/components/molecules/HeaderTop/index.js +11 -68
- package/dist/components/molecules/SignInLogin/index.js +28 -36
- package/dist/components/molecules/StripeCardSelector/CardSelector.stories.js +2 -1
- package/dist/components/organisms/Chat/Chat.stories.js +8 -27
- package/dist/components/organisms/Chat/ContainerItems/index.js +3 -19
- package/dist/components/organisms/Chat/ContainerItems/styles.js +1 -1
- package/dist/components/organisms/Chat/ContentChat/index.js +197 -350
- package/dist/components/organisms/Chat/Footer/index.js +39 -48
- package/dist/components/organisms/Chat/index.js +4 -49
- package/dist/components/organisms/Chat/styles.js +1 -1
- package/dist/components/organisms/DashboardMetric/index.js +6 -12
- package/dist/components/organisms/FullProductNameHeader/index.js +2 -2
- package/dist/components/organisms/InputGroup/index.js +10 -1
- package/dist/components/organisms/Modal/styles.js +1 -1
- package/dist/components/pages/Dashboard/Dashboard.stories.js +36 -33
- package/dist/components/pages/Dashboard/index.js +18 -67
- package/dist/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +3 -3
- package/dist/components/pages/ProviderProductEdition/index.js +144 -120
- package/dist/components/pages/ProviderProductEdition/styles.js +1 -1
- package/dist/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +3 -7
- package/dist/components/pages/RetailerProductEdition/index.js +433 -312
- package/dist/components/pages/RetailerProductEdition/styles.js +1 -1
- package/dist/components/pages/RetailerProductEdition/utils.js +2 -61
- package/dist/global-files/data.js +3 -11
- package/dist/global-files/variables.js +1 -5
- package/dist/index.js +58 -201
- package/package.json +1 -2
- package/src/components/atoms/Avatar/index.js +2 -8
- package/src/components/atoms/CheckBox/styles.js +0 -2
- package/src/components/atoms/InputFormatter/styles.js +1 -2
- package/src/components/atoms/SliderToolTip/styles.js +1 -1
- package/src/components/atoms/TabSection/styles.js +1 -1
- package/src/components/molecules/BoxAttribute/index.js +25 -32
- package/src/components/molecules/BoxAttribute/styles.js +1 -1
- package/src/components/molecules/BoxButtons/index.js +22 -23
- package/src/components/molecules/CarouselImagesLogin/index.js +1 -1
- package/src/components/molecules/HeaderTop/index.js +6 -52
- package/src/components/molecules/SignInLogin/index.js +11 -11
- package/src/components/molecules/StripeCardSelector/CardSelector.stories.js +2 -1
- package/src/components/molecules/TagAndInput/index.js +5 -6
- package/src/components/organisms/Chat/Chat.stories.js +7 -27
- package/src/components/organisms/Chat/ContainerItems/index.js +2 -18
- package/src/components/organisms/Chat/ContainerItems/styles.js +2 -14
- package/src/components/organisms/Chat/ContentChat/index.js +12 -88
- package/src/components/organisms/Chat/Footer/index.js +0 -11
- package/src/components/organisms/Chat/index.js +4 -46
- package/src/components/organisms/Chat/styles.js +0 -4
- package/src/components/organisms/DashboardMetric/index.js +3 -6
- package/src/components/organisms/FullProductNameHeader/index.js +1 -1
- package/src/components/organisms/InputGroup/index.js +119 -131
- package/src/components/organisms/Modal/styles.js +1 -4
- package/src/components/organisms/OrderDetail/utils/Table/utils.js +16 -6
- package/src/components/pages/Dashboard/Dashboard.stories.js +38 -33
- package/src/components/pages/Dashboard/index.js +39 -80
- package/src/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +83 -100
- package/src/components/pages/ProviderProductEdition/index.js +131 -100
- package/src/components/pages/ProviderProductEdition/styles.js +1 -5
- package/src/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +2 -6
- package/src/components/pages/RetailerProductEdition/index.js +309 -147
- package/src/components/pages/RetailerProductEdition/styles.js +0 -4
- package/src/components/pages/RetailerProductEdition/utils.js +0 -37
- package/src/global-files/data.js +13 -7
- package/src/global-files/variables.js +0 -4
- package/src/index.js +0 -11
- package/dist/assets/fonts/roboto/LICENSE.txt +0 -202
- package/dist/components/atoms/ImageCarousel/ImgeSlider.stories.js +0 -90
- package/dist/components/atoms/ImageCarousel/index.js +0 -120
- package/dist/components/atoms/ImageCarousel/styles.js +0 -18
- package/dist/components/atoms/PercentTag/PercentTag.stories.js +0 -31
- package/dist/components/atoms/PercentTag/index.js +0 -23
- package/dist/components/atoms/PercentTag/styles.js +0 -22
- package/dist/components/atoms/RatingStars/RatingStars.stories.js +0 -30
- package/dist/components/atoms/RatingStars/index.js +0 -53
- package/dist/components/atoms/RatingStars/styles.js +0 -18
- package/dist/components/atoms/RetailerCatalog/RetailerCatalog.stories.js +0 -48
- package/dist/components/atoms/RetailerCatalog/index.js +0 -69
- package/dist/components/atoms/RetailerCatalog/styles.js +0 -20
- package/dist/components/atoms/RetailerOption/RetailerOption.stories.js +0 -33
- package/dist/components/atoms/RetailerOption/index.js +0 -62
- package/dist/components/atoms/RetailerOption/styles.js +0 -20
- package/dist/components/atoms/RetailersList/RetailersList.stories.js +0 -45
- package/dist/components/atoms/RetailersList/index.js +0 -46
- package/dist/components/atoms/RetailersList/styles.js +0 -18
- package/dist/components/atoms/UserCatalog/UserCatalog.stories.js +0 -73
- package/dist/components/atoms/UserCatalog/index.js +0 -101
- package/dist/components/atoms/UserCatalog/styles.js +0 -18
- package/dist/components/atoms/UserOption/UserOption.stories.js +0 -40
- package/dist/components/atoms/UserOption/index.js +0 -130
- package/dist/components/atoms/UserOption/styles.js +0 -20
- package/dist/components/atoms/UserSelector/UserSelector.stories.js +0 -40
- package/dist/components/atoms/UserSelector/index.js +0 -98
- package/dist/components/atoms/UserSelector/styles.js +0 -32
- package/dist/components/molecules/GridItem/GridItem.stories.js +0 -123
- package/dist/components/molecules/GridItem/index.js +0 -152
- package/dist/components/molecules/GridItem/styles.js +0 -20
- package/dist/components/molecules/HeaderItem/ColumnItem.js +0 -23
- package/dist/components/molecules/HeaderItem/HeaderItem.stories.js +0 -70
- package/dist/components/molecules/HeaderItem/index.js +0 -42
- package/dist/components/molecules/HeaderItem/styles.js +0 -30
- package/dist/components/molecules/RowItem/ColumnItem.js +0 -23
- package/dist/components/molecules/RowItem/RowItem.stories.js +0 -5242
- package/dist/components/molecules/RowItem/index.js +0 -58
- package/dist/components/molecules/RowItem/styles.js +0 -30
- package/dist/components/organisms/GridProducts/GridProducts.stories.js +0 -5097
- package/dist/components/organisms/GridProducts/index.js +0 -63
- package/dist/components/organisms/GridProducts/styles.js +0 -18
- package/dist/components/organisms/GridProducts/utils.js +0 -149
- package/src/components/atoms/ImageCarousel/ImgeSlider.stories.js +0 -76
- package/src/components/atoms/ImageCarousel/index.js +0 -103
- package/src/components/atoms/ImageCarousel/styles.js +0 -79
- package/src/components/atoms/PercentTag/PercentTag.stories.js +0 -7
- package/src/components/atoms/PercentTag/index.js +0 -9
- package/src/components/atoms/PercentTag/styles.js +0 -69
- package/src/components/atoms/RatingStars/RatingStars.stories.js +0 -10
- package/src/components/atoms/RatingStars/index.js +0 -31
- package/src/components/atoms/RatingStars/styles.js +0 -28
- package/src/components/atoms/RetailerCatalog/RetailerCatalog.stories.js +0 -36
- package/src/components/atoms/RetailerCatalog/index.js +0 -49
- package/src/components/atoms/RetailerCatalog/styles.js +0 -30
- package/src/components/atoms/RetailerOption/RetailerOption.stories.js +0 -15
- package/src/components/atoms/RetailerOption/index.js +0 -53
- package/src/components/atoms/RetailerOption/styles.js +0 -41
- package/src/components/atoms/RetailersList/RetailersList.stories.js +0 -33
- package/src/components/atoms/RetailersList/index.js +0 -20
- package/src/components/atoms/RetailersList/styles.js +0 -19
- package/src/components/atoms/UserCatalog/UserCatalog.stories.js +0 -67
- package/src/components/atoms/UserCatalog/index.js +0 -100
- package/src/components/atoms/UserCatalog/styles.js +0 -24
- package/src/components/atoms/UserOption/UserOption.stories.js +0 -25
- package/src/components/atoms/UserOption/index.js +0 -95
- package/src/components/atoms/UserOption/styles.js +0 -61
- package/src/components/atoms/UserSelector/UserSelector.stories.js +0 -25
- package/src/components/atoms/UserSelector/index.js +0 -86
- package/src/components/atoms/UserSelector/styles.js +0 -55
- package/src/components/molecules/GridItem/GridItem.stories.js +0 -126
- package/src/components/molecules/GridItem/index.js +0 -105
- package/src/components/molecules/GridItem/styles.js +0 -104
- package/src/components/molecules/HeaderItem/ColumnItem.js +0 -9
- package/src/components/molecules/HeaderItem/HeaderItem.stories.js +0 -24
- package/src/components/molecules/HeaderItem/index.js +0 -26
- package/src/components/molecules/HeaderItem/styles.js +0 -27
- package/src/components/molecules/RowItem/ColumnItem.js +0 -9
- package/src/components/molecules/RowItem/RowItem.stories.js +0 -5660
- package/src/components/molecules/RowItem/index.js +0 -45
- package/src/components/molecules/RowItem/styles.js +0 -40
- package/src/components/organisms/GridProducts/GridProducts.stories.js +0 -5485
- package/src/components/organisms/GridProducts/index.js +0 -50
- package/src/components/organisms/GridProducts/styles.js +0 -14
- package/src/components/organisms/GridProducts/utils.js +0 -111
|
@@ -39,10 +39,6 @@ import Slide1_4 from "../../../assets/images/sliderToolTip/slide4.svg";
|
|
|
39
39
|
import Slide1_5 from "../../../assets/images/sliderToolTip/slide5.svg";
|
|
40
40
|
import { VersionSelector } from "../../organisms/VersionSelector";
|
|
41
41
|
import { useCloseModal } from "../../../global-files/customHooks";
|
|
42
|
-
import { createMessage, sendMessage } from "../RetailerProductEdition/utils";
|
|
43
|
-
import { Modal } from "../../organisms/Modal";
|
|
44
|
-
import { ButtonV2 } from "../../atoms/ButtonV2";
|
|
45
|
-
import { Box } from "../../organisms/Box";
|
|
46
42
|
|
|
47
43
|
const reducerImages = (state, action) => {
|
|
48
44
|
let { values, attrForImgs, inputsByRetailer } = state;
|
|
@@ -219,7 +215,6 @@ export const ProviderProductEdition = ({
|
|
|
219
215
|
const isRetailer = user?.is_retailer;
|
|
220
216
|
const [loading, setLoading] = useState(true);
|
|
221
217
|
const [validatedAll, setValidatedAll] = useState(false);
|
|
222
|
-
const [showRejectModal, setShowRejectModal] = useState(false);
|
|
223
218
|
|
|
224
219
|
const [origin, setOrigin] = useState({
|
|
225
220
|
"Ficha técnica": null,
|
|
@@ -349,6 +344,28 @@ export const ProviderProductEdition = ({
|
|
|
349
344
|
(type) => {
|
|
350
345
|
const formatter = new Intl.ListFormat("es", { type: "conjunction" });
|
|
351
346
|
switch (type) {
|
|
347
|
+
case "error":
|
|
348
|
+
setGlobalModal({
|
|
349
|
+
message: `${activeTab} rechazada`,
|
|
350
|
+
detail: "Agrega tu comentarios para enviar el rechazo",
|
|
351
|
+
img: errorModal,
|
|
352
|
+
textArea: true,
|
|
353
|
+
button1: {
|
|
354
|
+
name: "Enviar",
|
|
355
|
+
action: (e) => {
|
|
356
|
+
const textArea = document.querySelector("#area");
|
|
357
|
+
if (textArea.value) {
|
|
358
|
+
textArea.style.border = "none";
|
|
359
|
+
createComment(e, textArea.value);
|
|
360
|
+
showGlobalModal("commentsSent");
|
|
361
|
+
validatedAll ? validateAll("R") : sendEvaluation("R");
|
|
362
|
+
} else {
|
|
363
|
+
textArea.style.border = "2px solid red";
|
|
364
|
+
}
|
|
365
|
+
},
|
|
366
|
+
},
|
|
367
|
+
});
|
|
368
|
+
break;
|
|
352
369
|
case "generic":
|
|
353
370
|
setGlobalModal(dataGenericModal);
|
|
354
371
|
break;
|
|
@@ -509,9 +526,7 @@ export const ProviderProductEdition = ({
|
|
|
509
526
|
);
|
|
510
527
|
setServicesData(parsedResponse);
|
|
511
528
|
}
|
|
512
|
-
|
|
513
|
-
!activeRetailer.id &&
|
|
514
|
-
setActiveRetailer(active ? active : retailers[0]);
|
|
529
|
+
!activeRetailer.id && setActiveRetailer(active ? active : retailers[0]);
|
|
515
530
|
};
|
|
516
531
|
|
|
517
532
|
const isRevision = () => {
|
|
@@ -587,7 +602,7 @@ export const ProviderProductEdition = ({
|
|
|
587
602
|
});
|
|
588
603
|
}
|
|
589
604
|
setProduct(productTemp);
|
|
590
|
-
|
|
605
|
+
setActivePercentage(retailers[0]?.percentage);
|
|
591
606
|
}, [percentages]);
|
|
592
607
|
|
|
593
608
|
const loadInputs = () => {
|
|
@@ -847,21 +862,33 @@ export const ProviderProductEdition = ({
|
|
|
847
862
|
return "images";
|
|
848
863
|
}
|
|
849
864
|
};
|
|
850
|
-
|
|
851
865
|
|
|
852
|
-
const createComment = async (
|
|
866
|
+
const createComment = async (e, body, tab) => {
|
|
867
|
+
let concept = "";
|
|
868
|
+
switch (activeTab) {
|
|
869
|
+
case "Ficha técnica":
|
|
870
|
+
concept = "datasheet";
|
|
871
|
+
break;
|
|
872
|
+
case "Imágenes":
|
|
873
|
+
concept = "images";
|
|
874
|
+
break;
|
|
875
|
+
|
|
876
|
+
default:
|
|
877
|
+
concept = "description";
|
|
878
|
+
break;
|
|
879
|
+
}
|
|
853
880
|
const data = {
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
status: product.status || productEdit.product.status,
|
|
860
|
-
},
|
|
861
|
-
paramsHeader: { Authorization: token },
|
|
881
|
+
articleId: product?.id_article,
|
|
882
|
+
orderId: product?.orderId,
|
|
883
|
+
message: body,
|
|
884
|
+
concept: concept,
|
|
885
|
+
version: version,
|
|
862
886
|
};
|
|
863
|
-
|
|
864
|
-
|
|
887
|
+
await axios.post(`${process.env.REACT_APP_COMMENTS_ENDPOINT}`, data, {
|
|
888
|
+
headers: {
|
|
889
|
+
Authorization: token,
|
|
890
|
+
},
|
|
891
|
+
});
|
|
865
892
|
};
|
|
866
893
|
|
|
867
894
|
useEffect(() => {
|
|
@@ -1197,6 +1224,8 @@ export const ProviderProductEdition = ({
|
|
|
1197
1224
|
|
|
1198
1225
|
const enableActions = (versionStatus) => {
|
|
1199
1226
|
try {
|
|
1227
|
+
if (user.is_retailer) return false;
|
|
1228
|
+
|
|
1200
1229
|
if (versionStatus) {
|
|
1201
1230
|
return ["AP", "ACA", "RCA", null].includes(versionStatus);
|
|
1202
1231
|
}
|
|
@@ -1280,7 +1309,8 @@ export const ProviderProductEdition = ({
|
|
|
1280
1309
|
return;
|
|
1281
1310
|
} else if (user.is_retailer) {
|
|
1282
1311
|
if (product.id_order || product.orderId) {
|
|
1283
|
-
|
|
1312
|
+
setValidatedAll(true);
|
|
1313
|
+
showGlobalModal("error");
|
|
1284
1314
|
} else {
|
|
1285
1315
|
setDataGenericModal((prev) => ({
|
|
1286
1316
|
...prev,
|
|
@@ -1292,7 +1322,8 @@ export const ProviderProductEdition = ({
|
|
|
1292
1322
|
showGlobalModal("generic");
|
|
1293
1323
|
}
|
|
1294
1324
|
} else {
|
|
1295
|
-
|
|
1325
|
+
setValidatedAll(true);
|
|
1326
|
+
showGlobalModal("error");
|
|
1296
1327
|
}
|
|
1297
1328
|
}
|
|
1298
1329
|
};
|
|
@@ -1302,7 +1333,6 @@ export const ProviderProductEdition = ({
|
|
|
1302
1333
|
<HeaderTop
|
|
1303
1334
|
setHeaderTop={setHeaderTop}
|
|
1304
1335
|
withChat={location?.state?.withChat}
|
|
1305
|
-
chatType={location?.state?.chatType}
|
|
1306
1336
|
productSelected={productSelected}
|
|
1307
1337
|
token={token}
|
|
1308
1338
|
activeRetailer={activeRetailer}
|
|
@@ -1381,7 +1411,7 @@ export const ProviderProductEdition = ({
|
|
|
1381
1411
|
} else if (user.is_retailer) {
|
|
1382
1412
|
if (product.id_order || product.orderId) {
|
|
1383
1413
|
setValidatedAll(true);
|
|
1384
|
-
|
|
1414
|
+
showGlobalModal("error");
|
|
1385
1415
|
} else {
|
|
1386
1416
|
setDataGenericModal((prev) => ({
|
|
1387
1417
|
...prev,
|
|
@@ -1393,14 +1423,12 @@ export const ProviderProductEdition = ({
|
|
|
1393
1423
|
showGlobalModal("generic");
|
|
1394
1424
|
}
|
|
1395
1425
|
} else {
|
|
1396
|
-
setShowRejectModal(true);
|
|
1397
1426
|
setValidatedAll(true);
|
|
1427
|
+
showGlobalModal("error");
|
|
1398
1428
|
}
|
|
1399
1429
|
}}
|
|
1400
1430
|
approve={() => sendToEvaluation("A")}
|
|
1401
|
-
reject={() =>
|
|
1402
|
-
setShowRejectModal(true);
|
|
1403
|
-
}}
|
|
1431
|
+
reject={() => sendToEvaluation("R")}
|
|
1404
1432
|
/>
|
|
1405
1433
|
<FullTabsMenu
|
|
1406
1434
|
tabsSections={tabsSections}
|
|
@@ -1503,7 +1531,6 @@ export const ProviderProductEdition = ({
|
|
|
1503
1531
|
setUpdatedDescriptions={setUpdatedDescriptions}
|
|
1504
1532
|
articleId={product?.id_article}
|
|
1505
1533
|
version={version}
|
|
1506
|
-
isShowbox={false}
|
|
1507
1534
|
dinamicHeight={true}
|
|
1508
1535
|
/>
|
|
1509
1536
|
) : (
|
|
@@ -1530,41 +1557,87 @@ export const ProviderProductEdition = ({
|
|
|
1530
1557
|
</>
|
|
1531
1558
|
)}
|
|
1532
1559
|
</div>
|
|
1533
|
-
{
|
|
1534
|
-
<div className="
|
|
1535
|
-
|
|
1536
|
-
<
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
<
|
|
1547
|
-
|
|
1548
|
-
|
|
1560
|
+
{isRevision() && getSectionStatus() ? (
|
|
1561
|
+
<div className="commentary-box">
|
|
1562
|
+
{!comment ? (
|
|
1563
|
+
<div className="commentary">
|
|
1564
|
+
<TagAndInput
|
|
1565
|
+
label={"Caja de Comentario"}
|
|
1566
|
+
inputType={"textarea"}
|
|
1567
|
+
inputCols={80}
|
|
1568
|
+
inputRows={4}
|
|
1569
|
+
inputId={"commentary-box"}
|
|
1570
|
+
index={0}
|
|
1571
|
+
/>
|
|
1572
|
+
<div className="buttons-box">
|
|
1573
|
+
<Button
|
|
1574
|
+
buttonType={"general-transparent-button"}
|
|
1575
|
+
label={"Enviar comentario"}
|
|
1576
|
+
onClick={(e) =>
|
|
1577
|
+
createComment(
|
|
1578
|
+
e,
|
|
1579
|
+
document.querySelector(
|
|
1580
|
+
"#description-commentary-box-0 .ql-container .ql-editor > p"
|
|
1581
|
+
).innerHTML,
|
|
1582
|
+
activeTab
|
|
1583
|
+
)
|
|
1584
|
+
}
|
|
1585
|
+
/>
|
|
1586
|
+
</div>
|
|
1587
|
+
</div>
|
|
1549
1588
|
) : (
|
|
1550
|
-
|
|
1551
|
-
<
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
iconSize={"big-image"}
|
|
1555
|
-
slidePosition={"top-slide"}
|
|
1589
|
+
<div className="feedback-box">
|
|
1590
|
+
<Commentary
|
|
1591
|
+
comment={comment.message}
|
|
1592
|
+
reviewed={crossComment}
|
|
1556
1593
|
/>
|
|
1557
1594
|
<Button
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1595
|
+
buttonType={"circular-button accept-button"}
|
|
1596
|
+
onClick={async () => {
|
|
1597
|
+
setCrossComment(true);
|
|
1598
|
+
commentRevised();
|
|
1561
1599
|
}}
|
|
1562
|
-
buttonType="general-default-button"
|
|
1563
|
-
label="Enviar a Content-oh!"
|
|
1564
1600
|
/>
|
|
1565
|
-
|
|
1601
|
+
</div>
|
|
1566
1602
|
)}
|
|
1567
1603
|
</div>
|
|
1604
|
+
) : (
|
|
1605
|
+
!revision && (
|
|
1606
|
+
<div className="required-inputs-message">
|
|
1607
|
+
<div>
|
|
1608
|
+
<p>
|
|
1609
|
+
Los atributos son requeridos por las plataformas de las
|
|
1610
|
+
cadenas, es muy importante completar los campos requeridos
|
|
1611
|
+
ya que pueden rechazar el producto por falta de información.
|
|
1612
|
+
</p>
|
|
1613
|
+
</div>
|
|
1614
|
+
{inCart ? (
|
|
1615
|
+
<button type="button">
|
|
1616
|
+
<Link to="/checkout">
|
|
1617
|
+
<p>Articulo en carrito</p>
|
|
1618
|
+
<p>Ir a checkout</p>
|
|
1619
|
+
</Link>
|
|
1620
|
+
</button>
|
|
1621
|
+
) : (
|
|
1622
|
+
<>
|
|
1623
|
+
<SliderToolTip
|
|
1624
|
+
infoIcon={InfoIcon}
|
|
1625
|
+
slidefront={slidefront}
|
|
1626
|
+
iconSize={"big-image"}
|
|
1627
|
+
slidePosition={"top-slide"}
|
|
1628
|
+
/>
|
|
1629
|
+
<Button
|
|
1630
|
+
onClick={() => {
|
|
1631
|
+
setShowContentohRequestModal &&
|
|
1632
|
+
setShowContentohRequestModal(true);
|
|
1633
|
+
}}
|
|
1634
|
+
buttonType="general-default-button"
|
|
1635
|
+
label="Enviar a Content-oh!"
|
|
1636
|
+
/>
|
|
1637
|
+
</>
|
|
1638
|
+
)}
|
|
1639
|
+
</div>
|
|
1640
|
+
)
|
|
1568
1641
|
)}
|
|
1569
1642
|
</div>
|
|
1570
1643
|
</div>
|
|
@@ -1607,48 +1680,6 @@ export const ProviderProductEdition = ({
|
|
|
1607
1680
|
jwt={token}
|
|
1608
1681
|
/>
|
|
1609
1682
|
)}
|
|
1610
|
-
{showRejectModal && (
|
|
1611
|
-
<Modal
|
|
1612
|
-
title={"Agregar mensaje de rechazo"}
|
|
1613
|
-
show={showRejectModal}
|
|
1614
|
-
customComponent={
|
|
1615
|
-
<TagAndInput
|
|
1616
|
-
inputType={"textarea"}
|
|
1617
|
-
inputId={"modal-message-box"}
|
|
1618
|
-
index={0}
|
|
1619
|
-
color={"white"}
|
|
1620
|
-
/>
|
|
1621
|
-
}
|
|
1622
|
-
buttons={[
|
|
1623
|
-
<ButtonV2
|
|
1624
|
-
key={"btn-Cancelar"}
|
|
1625
|
-
type={"white"}
|
|
1626
|
-
label={"Cancelar"}
|
|
1627
|
-
size={12}
|
|
1628
|
-
onClick={() => {
|
|
1629
|
-
setShowRejectModal(false);
|
|
1630
|
-
}}
|
|
1631
|
-
/>,
|
|
1632
|
-
<ButtonV2
|
|
1633
|
-
key={"btn-Aceptar"}
|
|
1634
|
-
type={"pink"}
|
|
1635
|
-
label={"Aceptar"}
|
|
1636
|
-
size={12}
|
|
1637
|
-
onClick={async () => {
|
|
1638
|
-
const body = document.querySelector(
|
|
1639
|
-
"#modal-message-box .ql-container .ql-editor > p"
|
|
1640
|
-
).innerHTML;
|
|
1641
|
-
const messages = [
|
|
1642
|
-
{ type: "message", value: body?.replace(/<.*?\/?>/gm, "") },
|
|
1643
|
-
];
|
|
1644
|
-
await createComment(messages, activeRetailer.id);
|
|
1645
|
-
validatedAll ? validateAll("R") : sendToEvaluation("R");
|
|
1646
|
-
setShowRejectModal(false);
|
|
1647
|
-
}}
|
|
1648
|
-
/>,
|
|
1649
|
-
]}
|
|
1650
|
-
/>
|
|
1651
|
-
)}
|
|
1652
1683
|
</Container>
|
|
1653
1684
|
);
|
|
1654
1685
|
};
|
|
@@ -107,10 +107,6 @@ export const Container = styled.div`
|
|
|
107
107
|
}
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
|
-
#modal-message-box {
|
|
111
|
-
width: 400px;
|
|
112
|
-
height: 100px;
|
|
113
|
-
}
|
|
114
110
|
.container {
|
|
115
111
|
width: 100%;
|
|
116
112
|
height: 100%;
|
|
@@ -119,4 +115,4 @@ export const Container = styled.div`
|
|
|
119
115
|
width: 100%;
|
|
120
116
|
}
|
|
121
117
|
}
|
|
122
|
-
`;
|
|
118
|
+
`;
|
|
@@ -16,7 +16,7 @@ RetailerProductEditionDefault.args = {
|
|
|
16
16
|
Imágenes: false,
|
|
17
17
|
},
|
|
18
18
|
token:
|
|
19
|
-
"eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.
|
|
19
|
+
"eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiI5YTIxMzEyOC02NDgyLTRjMTYtYTRiNi02ZTY0ZjIyNWIxYmQiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6IjlhMjEzMTI4LTY0ODItNGMxNi1hNGI2LTZlNjRmMjI1YjFiZCIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiI0OTMyY2JhZC1lYzcyLTRjYWItODgyNS0wMzY2M2RkNmE2ODIiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY5Mjc1MDY0NywibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY5Mjc1NDI0NywiaWF0IjoxNjkyNzUwNjQ3LCJlbWFpbCI6ImlzbWFlbDk3bG9wZXpAZ21haWwuY29tIn0.eqOY-gcS-W99WcEC632Ewckcg3WJzKoV9fIGcn1AkEE44_odGTcEk8fhVs-6_evIJkfShQOP0RFX0d2Dn31F-xFh5Lez6LvbT9F41_rAmMb3ELyRvdcz42V4eMw2IBH-FGrpGhSsJOHKV2T3WuUyZxPJu-C04ZAadfFSoNBBWnxX6SFk_eefcp9KghNmnELSSnWDh6DD1XDrWqEaLOVlQ5H7q4ARJqBo07KcXHIQo056anVud-inUMiX9KDTaorXdBCD0doWgv8NkYWSEpUS_Ctj-NG6vAled9g-6oLnC6DLR_ay6PRnAKGVNCv8bRZJL0GqF8ZnWk02svDHfUPJ0Q",
|
|
20
20
|
productSelected: {
|
|
21
21
|
services: {
|
|
22
22
|
datasheets: 1,
|
|
@@ -73,11 +73,7 @@ RetailerProductEditionDefault.args = {
|
|
|
73
73
|
upc: "7543453453",
|
|
74
74
|
},
|
|
75
75
|
location: {
|
|
76
|
-
product: { articleId:
|
|
77
|
-
state: {
|
|
78
|
-
withChat: true,
|
|
79
|
-
chatType: "product_status",
|
|
80
|
-
},
|
|
76
|
+
product: { articleId: 39290, versionId: 7 },
|
|
81
77
|
},
|
|
82
78
|
user: {
|
|
83
79
|
id_user: 37,
|