contentoh-components-library 21.2.13 → 21.2.14

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.
Files changed (28) hide show
  1. package/dist/components/atoms/ListCommercialRetailers/ListCommercialRetailers.stories.js +36 -0
  2. package/dist/components/atoms/ListCommercialRetailers/index.js +64 -0
  3. package/dist/components/atoms/ListCommercialRetailers/styles.js +20 -0
  4. package/dist/components/atoms/MenuCommercialRetailers/MenuCommercialRetailers.stories.js +37 -0
  5. package/dist/components/atoms/MenuCommercialRetailers/index.js +25 -0
  6. package/dist/components/atoms/MenuCommercialRetailers/styles.js +20 -0
  7. package/dist/components/atoms/MenuProductImage/MenuProductImage.stories.js +28 -0
  8. package/dist/components/atoms/MenuProductImage/index.js +88 -0
  9. package/dist/components/atoms/MenuProductImage/styles.js +20 -0
  10. package/dist/components/atoms/StatusTag/StatusTag.stories.js +48 -0
  11. package/dist/components/atoms/StatusTag/index.js +58 -0
  12. package/dist/components/atoms/StatusTag/styles.js +20 -0
  13. package/dist/components/molecules/ApproveRejetPanel/ApproveRejetPanel.stories.js +25 -0
  14. package/dist/components/molecules/ApproveRejetPanel/index.js +49 -0
  15. package/dist/components/molecules/ApproveRejetPanel/styles.js +18 -0
  16. package/dist/components/molecules/SignInLoginCreationApp/SignInLogin.stories.js +28 -0
  17. package/dist/components/molecules/SignInLoginCreationApp/index.js +270 -0
  18. package/dist/components/molecules/SignInLoginCreationApp/styles.js +20 -0
  19. package/dist/components/pages/ProviderProductEdition/index.js +13 -9
  20. package/dist/components/pages/RegistrationLoginFirstStep/RegistrationLoginFirstStep.stories.js +37 -0
  21. package/dist/components/pages/RegistrationLoginFirstStep/index.js +269 -0
  22. package/dist/components/pages/RegistrationLoginFirstStep/styles.js +20 -0
  23. package/dist/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +44 -48
  24. package/dist/components/pages/RetailerProductEdition/index.js +1 -1
  25. package/package.json +1 -1
  26. package/src/components/pages/ProviderProductEdition/index.js +1 -0
  27. package/src/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +47 -51
  28. package/src/components/pages/RetailerProductEdition/index.js +1 -0
@@ -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)(["\n display: flex;\n width: 100%;\n height: 100vh;\n .user {\n .name-registration-user {\n display: flex;\n justify-content: space-between;\n input {\n width: 160px;\n }\n }\n .input-name-header {\n margin-bottom: 4px;\n margin-top: 12px;\n }\n .phone-registration-user {\n display: flex;\n justify-content: space-between;\n .phone-options {\n width: 80px;\n }\n input {\n width: 100%;\n }\n & + * {\n margin-top: 10px;\n }\n }\n .country-options,\n .phone-options {\n width: 100%;\n border: 1px solid ", ";\n font-family: ", ";\n color: ", ";\n font-weight: normal;\n font-size: 12px;\n line-height: 15px;\n padding: 10px;\n outline: none;\n border-radius: 2px;\n resize: none;\n &:focus {\n border: 1px solid ", ";\n }\n }\n }\n .button-end {\n text-align: end;\n .general-default-button {\n width: 160px;\n }\n & + * {\n margin-top: 10px;\n }\n }\n .progress-bar {\n width: 100%;\n height: 8px;\n display: flex;\n justify-content: space-between;\n .progress-bar-first-step {\n width: 33.33%;\n background-color: rgb(196, 196, 196);\n }\n .progress-bar-registration {\n background-color: rgb(226, 226, 226);\n width: 66.66%;\n }\n }\n .date-header {\n .new-login {\n & + * {\n margin-top: 20px;\n }\n }\n }\n .home-login-retailer,\n .home-retailer {\n width: 50%;\n }\n"])), _variables.GlobalColors.s2, _variables.FontFamily.AvenirNext, _variables.GlobalColors.s4, _variables.GlobalColors.magenta_s2);
19
+
20
+ exports.Container = Container;
@@ -33,57 +33,53 @@ RetailerProductEditionDefault.args = {
33
33
  },
34
34
  token: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiI3MTNhNzQ1Ny1mOTQzLTRiYzktOGViMC04NmI0MWY1YmQ0ZjgiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6IjcxM2E3NDU3LWY5NDMtNGJjOS04ZWIwLTg2YjQxZjViZDRmOCIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiJlM2ExZmQ2OC02OTAwLTRjNWYtYjM5MC1jNjY0MDZhZjkyMGYiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY2MTU0ODI4NSwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY2MTU1MTg4NSwiaWF0IjoxNjYxNTQ4Mjg1LCJlbWFpbCI6ImhjYXJyaWxsb0Bjb250ZW50b2guY29tIn0.GUmPbOrd8-llRODdaidjReKHBwrVbGV5LP37aD_o14BQ67VSmH2pxLvrZRBNsZhvP0vZuetXt19pyiFgCr1-SF5CMHD3dcnPq2Ka0PUEf8raNEoseCPGaDUugu-waz1qPadZN1OrlhQTm9mOWoGj4u0gQv5FGAbC6xMcRernAo4QX41-Pfjvp2u7p62BYkp6rafzTjazUHZiG-ueqPI9QQQ-2zkbTo46l7TFYz6ATNSiZEvezc52L1nzWDhI5Q8xbNA546WC-leLr30SV9vrXBTGdvLdCKeqEYPrVG1L3nXXZ9CvtHJjdkb60irWZjXT1LbpulfL3IqO2_PKHTUpHQ",
35
35
  productSelected: {
36
- "services": {
37
- "datasheets": 1,
38
- "descriptions": 1,
39
- "images": 1
36
+ services: {
37
+ datasheets: 1,
38
+ descriptions: 1,
39
+ images: 1
40
40
  },
41
- "orderId": 2674,
42
- "status": "PA",
43
- "datasheet_status": "PA",
44
- "prio": "none",
45
- "version": 2,
46
- "description_status": "PA",
47
- "images_status": "PA",
48
- "article": {
49
- "id_article": 80969,
50
- "id_category": "2044",
51
- "name": "CABLE IUSA THWLS/THHWLS 10 AWG COLOR VERDE EN CARRETE DE 100 M",
52
- "upc": "168594",
53
- "timestamp": "2022-08-26T21:11:06.000Z",
54
- "id_user": 651,
55
- "status": "NULL",
56
- "active": 1,
57
- "company_id": 388,
58
- "SKU": null,
59
- "Descripcion": null,
60
- "Proveedor": null,
61
- "id_proveedor": 0,
62
- "company_name": "",
63
- "country": null,
64
- "id_order": 2674,
65
- "id_datasheet_especialist": null,
66
- "id_datasheet_facilitator": null,
67
- "id_description_especialist": null,
68
- "id_description_facilitator": null,
69
- "id_images_especialist": null,
70
- "id_images_facilitator": null,
71
- "id_auditor": null,
72
- "id_recepcionist": null,
73
- "category": "Eléctrico|Cables Eléctricos|Cables Eléctricos",
74
- "missingAttributes": null,
75
- "missingDescriptions": null,
76
- "missingImages": null
41
+ orderId: 127,
42
+ status: "AS",
43
+ datasheet_status: "AS",
44
+ prio: "none",
45
+ version: 2,
46
+ description_status: "AS",
47
+ images_status: "AS",
48
+ article: {
49
+ id_article: 76186,
50
+ id_category: "399",
51
+ name: "Croquetas Dog Chow",
52
+ upc: "4535354",
53
+ timestamp: "2022-07-21T15:20:25.000Z",
54
+ id_user: 28,
55
+ status: "NULL",
56
+ active: 1,
57
+ company_id: 1,
58
+ company_name: "COMPANY DEV",
59
+ country: "México",
60
+ id_order: 127,
61
+ id_datasheet_especialist: 54,
62
+ id_datasheet_facilitator: 52,
63
+ id_description_especialist: 54,
64
+ id_description_facilitator: 52,
65
+ id_images_especialist: 55,
66
+ id_images_facilitator: 53,
67
+ id_auditor: 30,
68
+ id_recepcionist: null,
69
+ category: "Mascotas|Alimentos y Premios|Alimento para Perros",
70
+ missingAttributes: null,
71
+ missingDescriptions: null,
72
+ missingImages: null
77
73
  },
78
- "retailers": [{
79
- "id": 58,
80
- "name": "The Home Depot Golden",
81
- "country": "México",
82
- "id_region": 1,
83
- "active": 1
74
+ retailers: [{
75
+ id: 2,
76
+ name: "Walmart Mercancías Generales",
77
+ country: "México",
78
+ id_region: 1,
79
+ active: 1
84
80
  }],
85
- "country": null,
86
- "upc": "168594"
81
+ country: "México",
82
+ upc: "4535354"
87
83
  },
88
84
  location: {
89
85
  product: {
@@ -1914,7 +1914,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1914
1914
  headerType: "input-name-header"
1915
1915
  }))]
1916
1916
  })
1917
- }), (userAssigned(activeTab) || auditorAssigned()) && product["".concat(getConcept(activeTab), "_status")] !== "NS" && /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
1917
+ }), console.log(userAssigned(activeTab), auditorAssigned()), (userAssigned(activeTab) || auditorAssigned()) && product["".concat(getConcept(activeTab), "_status")] !== "NS" && /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
1918
1918
  className: "commentary-box",
1919
1919
  children: [!comment ? /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
1920
1920
  className: "commentary",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "contentoh-components-library",
3
- "version": "21.2.13",
3
+ "version": "21.2.14",
4
4
  "dependencies": {
5
5
  "@aws-amplify/auth": "^4.5.3",
6
6
  "@aws-amplify/datastore": "^3.11.0",
@@ -938,6 +938,7 @@ export const ProviderProductEdition = ({
938
938
  );
939
939
  });
940
940
  const evalResponse = await Promise.all(evaluationArray);
941
+ console.log(evalResponse.map(({ data }) => JSON.parse(data.body)));
941
942
  const userType = user.is_retailer === 1 ? "CA" : "P";
942
943
 
943
944
  const productTemp = product;
@@ -18,60 +18,56 @@ RetailerProductEditionDefault.args = {
18
18
  token:
19
19
  "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiI3MTNhNzQ1Ny1mOTQzLTRiYzktOGViMC04NmI0MWY1YmQ0ZjgiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6IjcxM2E3NDU3LWY5NDMtNGJjOS04ZWIwLTg2YjQxZjViZDRmOCIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiJlM2ExZmQ2OC02OTAwLTRjNWYtYjM5MC1jNjY0MDZhZjkyMGYiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY2MTU0ODI4NSwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY2MTU1MTg4NSwiaWF0IjoxNjYxNTQ4Mjg1LCJlbWFpbCI6ImhjYXJyaWxsb0Bjb250ZW50b2guY29tIn0.GUmPbOrd8-llRODdaidjReKHBwrVbGV5LP37aD_o14BQ67VSmH2pxLvrZRBNsZhvP0vZuetXt19pyiFgCr1-SF5CMHD3dcnPq2Ka0PUEf8raNEoseCPGaDUugu-waz1qPadZN1OrlhQTm9mOWoGj4u0gQv5FGAbC6xMcRernAo4QX41-Pfjvp2u7p62BYkp6rafzTjazUHZiG-ueqPI9QQQ-2zkbTo46l7TFYz6ATNSiZEvezc52L1nzWDhI5Q8xbNA546WC-leLr30SV9vrXBTGdvLdCKeqEYPrVG1L3nXXZ9CvtHJjdkb60irWZjXT1LbpulfL3IqO2_PKHTUpHQ",
20
20
  productSelected: {
21
- "services": {
22
- "datasheets": 1,
23
- "descriptions": 1,
24
- "images": 1
21
+ services: {
22
+ datasheets: 1,
23
+ descriptions: 1,
24
+ images: 1,
25
25
  },
26
- "orderId": 2674,
27
- "status": "PA",
28
- "datasheet_status": "PA",
29
- "prio": "none",
30
- "version": 2,
31
- "description_status": "PA",
32
- "images_status": "PA",
33
- "article": {
34
- "id_article": 80969,
35
- "id_category": "2044",
36
- "name": "CABLE IUSA THWLS/THHWLS 10 AWG COLOR VERDE EN CARRETE DE 100 M",
37
- "upc": "168594",
38
- "timestamp": "2022-08-26T21:11:06.000Z",
39
- "id_user": 651,
40
- "status": "NULL",
41
- "active": 1,
42
- "company_id": 388,
43
- "SKU": null,
44
- "Descripcion": null,
45
- "Proveedor": null,
46
- "id_proveedor": 0,
47
- "company_name": "",
48
- "country": null,
49
- "id_order": 2674,
50
- "id_datasheet_especialist": null,
51
- "id_datasheet_facilitator": null,
52
- "id_description_especialist": null,
53
- "id_description_facilitator": null,
54
- "id_images_especialist": null,
55
- "id_images_facilitator": null,
56
- "id_auditor": null,
57
- "id_recepcionist": null,
58
- "category": "Eléctrico|Cables Eléctricos|Cables Eléctricos",
59
- "missingAttributes": null,
60
- "missingDescriptions": null,
61
- "missingImages": null
26
+ orderId: 127,
27
+ status: "AS",
28
+ datasheet_status: "AS",
29
+ prio: "none",
30
+ version: 2,
31
+ description_status: "AS",
32
+ images_status: "AS",
33
+ article: {
34
+ id_article: 76186,
35
+ id_category: "399",
36
+ name: "Croquetas Dog Chow",
37
+ upc: "4535354",
38
+ timestamp: "2022-07-21T15:20:25.000Z",
39
+ id_user: 28,
40
+ status: "NULL",
41
+ active: 1,
42
+ company_id: 1,
43
+ company_name: "COMPANY DEV",
44
+ country: "México",
45
+ id_order: 127,
46
+ id_datasheet_especialist: 54,
47
+ id_datasheet_facilitator: 52,
48
+ id_description_especialist: 54,
49
+ id_description_facilitator: 52,
50
+ id_images_especialist: 55,
51
+ id_images_facilitator: 53,
52
+ id_auditor: 30,
53
+ id_recepcionist: null,
54
+ category: "Mascotas|Alimentos y Premios|Alimento para Perros",
55
+ missingAttributes: null,
56
+ missingDescriptions: null,
57
+ missingImages: null,
62
58
  },
63
- "retailers": [
64
- {
65
- "id": 58,
66
- "name": "The Home Depot Golden",
67
- "country": "México",
68
- "id_region": 1,
69
- "active": 1
70
- }
59
+ retailers: [
60
+ {
61
+ id: 2,
62
+ name: "Walmart Mercancías Generales",
63
+ country: "México",
64
+ id_region: 1,
65
+ active: 1,
66
+ },
71
67
  ],
72
- "country": null,
73
- "upc": "168594"
74
- },
68
+ country: "México",
69
+ upc: "4535354",
70
+ },
75
71
  location: {
76
72
  product: { articleId: 109485, versionId: 3 },
77
73
  },
@@ -1400,6 +1400,7 @@ export const RetailerProductEdition = ({
1400
1400
  </>
1401
1401
  )}
1402
1402
  </div>
1403
+ {console.log(userAssigned(activeTab), auditorAssigned())}
1403
1404
  {(userAssigned(activeTab) || auditorAssigned()) &&
1404
1405
  product[`${getConcept(activeTab)}_status`] !== "NS" && (
1405
1406
  <div className="commentary-box">