contentoh-components-library 21.3.3 → 21.3.5
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/.env.development +2 -5
- package/.env.production +25 -25
- package/dist/components/atoms/GeneralButton/index.js +6 -2
- package/dist/components/atoms/Select/VersionSelect.js +2 -1
- package/dist/components/molecules/CustomSelect/CustomSelect.stories.js +22 -21
- package/dist/components/molecules/CustomSelect/SelectItem.js +1 -10
- package/dist/components/molecules/HeaderTop/index.js +5 -10
- package/dist/components/molecules/HeaderTop/styles.js +1 -1
- package/dist/components/organisms/CreateVersion/RenderChilds.js +11 -11
- package/dist/components/organisms/CreateVersion/index.js +30 -89
- package/dist/components/organisms/OrderDetail/OrderDetail.stories.js +1 -1
- package/dist/components/organisms/OrderDetail/index.js +20 -11
- package/dist/components/organisms/OrderDetail/styles.js +1 -1
- package/dist/components/organisms/OrderDetail/utils/Table/styles.js +1 -1
- package/dist/components/organisms/OrderDetail/utils/Table/utils.js +45 -15
- package/dist/components/organisms/VersionSelector/index.js +28 -2
- package/dist/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +69 -147
- package/dist/components/pages/ProviderProductEdition/index.js +19 -39
- package/dist/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +77 -67
- package/dist/components/pages/RetailerProductEdition/index.js +5 -24
- package/dist/global-files/fonts.css +3 -15
- package/dist/global-files/variables.js +0 -2
- package/dist/index.js +46 -267
- package/package.json +1 -12
- package/src/components/atoms/GeneralButton/index.js +4 -1
- package/src/components/atoms/Select/VersionSelect.js +4 -2
- package/src/components/molecules/CustomSelect/CustomSelect.stories.js +12 -20
- package/src/components/molecules/CustomSelect/SelectItem.js +0 -7
- package/src/components/molecules/HeaderTop/index.js +6 -11
- package/src/components/molecules/HeaderTop/styles.js +0 -4
- package/src/components/organisms/CreateVersion/RenderChilds.js +28 -34
- package/src/components/organisms/CreateVersion/index.js +16 -36
- package/src/components/organisms/OrderDetail/OrderDetail.stories.js +1 -1
- package/src/components/organisms/OrderDetail/index.js +19 -12
- package/src/components/organisms/OrderDetail/styles.js +1 -0
- package/src/components/organisms/OrderDetail/utils/Table/styles.js +26 -0
- package/src/components/organisms/OrderDetail/utils/Table/utils.js +30 -15
- package/src/components/organisms/VersionSelector/index.js +18 -3
- package/src/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +75 -166
- package/src/components/pages/ProviderProductEdition/index.js +3 -22
- package/src/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +79 -67
- package/src/components/pages/RetailerProductEdition/index.js +2 -14
- package/src/global-files/customHooks.js +2 -2
- package/src/global-files/fonts.css +3 -15
- package/src/global-files/variables.js +0 -2
- package/src/index.js +0 -17
- package/dist/assets/images/customSelect/starIcon.svg +0 -14
- package/dist/assets/images/defaultImages/Spinner.gif +0 -0
- package/dist/assets/images/defaultImages/notFound.svg +0 -124
- package/dist/components/atoms/ButtonFileChooser/ButtonFileChooser.stories.js +0 -72
- package/dist/components/atoms/ButtonFileChooser/index.js +0 -118
- package/dist/components/atoms/ButtonFileChooser/styles.js +0 -20
- package/dist/components/atoms/ButtonV2/ButtonV2.stories.js +0 -66
- package/dist/components/atoms/ButtonV2/index.js +0 -110
- package/dist/components/atoms/ButtonV2/styles.js +0 -53
- package/dist/components/atoms/CustomIcon/CustomIcon.stories.js +0 -50
- package/dist/components/atoms/CustomIcon/index.js +0 -40
- package/dist/components/atoms/CustomIcon/styles.js +0 -33
- package/dist/components/atoms/IconFile/IconFile.stories.js +0 -48
- package/dist/components/atoms/IconFile/index.js +0 -249
- package/dist/components/atoms/IconFile/styles.js +0 -23
- package/dist/components/atoms/Image/Image.stories.js +0 -73
- package/dist/components/atoms/Image/index.js +0 -76
- package/dist/components/atoms/Image/styles.js +0 -43
- package/dist/components/atoms/ImageLink/ImageLink.stories.js +0 -63
- package/dist/components/atoms/ImageLink/index.js +0 -77
- package/dist/components/atoms/ImageLink/styles.js +0 -40
- package/dist/components/atoms/ImagePreview/ImagePreview.stories.js +0 -70
- package/dist/components/atoms/ImagePreview/index.js +0 -222
- package/dist/components/atoms/ImagePreview/styles.js +0 -44
- package/dist/components/atoms/InputText/InputText.stories.js +0 -60
- package/dist/components/atoms/InputText/index.js +0 -66
- package/dist/components/atoms/InputText/styles.js +0 -32
- package/dist/components/atoms/NotFound/NotFound.stories.js +0 -36
- package/dist/components/atoms/NotFound/index.js +0 -75
- package/dist/components/atoms/NotFound/styles.js +0 -20
- package/dist/components/atoms/SelectItemV2/SelectItemV2.stories.js +0 -45
- package/dist/components/atoms/SelectItemV2/index.js +0 -57
- package/dist/components/atoms/SelectItemV2/styles.js +0 -30
- package/dist/components/atoms/Tooltip/Tooltip.stories.js +0 -66
- package/dist/components/atoms/Tooltip/index.js +0 -72
- package/dist/components/atoms/Tooltip/styles.js +0 -20
- package/dist/components/molecules/ButtonDownloadFile/DownloadFile.stories.js +0 -66
- package/dist/components/molecules/ButtonDownloadFile/index.js +0 -179
- package/dist/components/molecules/ButtonDownloadFile/styles.js +0 -23
- package/dist/components/molecules/Dropdown/Dropdown.stories.js +0 -98
- package/dist/components/molecules/Dropdown/index.js +0 -150
- package/dist/components/molecules/Dropdown/styles.js +0 -26
- package/dist/components/molecules/ImageTooltip/ImageTooltip.stories.js +0 -82
- package/dist/components/molecules/ImageTooltip/index.js +0 -85
- package/dist/components/molecules/ImageTooltip/styles.js +0 -33
- package/dist/components/molecules/SelectV2/SelectV2.stories.js +0 -119
- package/dist/components/molecules/SelectV2/index.js +0 -306
- package/dist/components/molecules/SelectV2/styles.js +0 -42
- package/dist/components/molecules/SelectV2/test.js +0 -95
- package/dist/components/molecules/SelectV2/test.stories.js +0 -27
- package/dist/components/organisms/Chat/Chat.stories.js +0 -215
- package/dist/components/organisms/Chat/ChatLists/ChatLists.stories.js +0 -83
- package/dist/components/organisms/Chat/ChatLists/index.js +0 -160
- package/dist/components/organisms/Chat/ChatLists/styles.js +0 -29
- package/dist/components/organisms/Chat/ContainerItems/ContainerItems.stories.js +0 -176
- package/dist/components/organisms/Chat/ContainerItems/index.js +0 -569
- package/dist/components/organisms/Chat/ContainerItems/styles.js +0 -20
- package/dist/components/organisms/Chat/ContentChat/ContentChat.stories.js +0 -142
- package/dist/components/organisms/Chat/ContentChat/index.js +0 -1422
- package/dist/components/organisms/Chat/ContentChat/styles.js +0 -20
- package/dist/components/organisms/Chat/Footer/Footer.stories.js +0 -43
- package/dist/components/organisms/Chat/Footer/index.js +0 -984
- package/dist/components/organisms/Chat/Footer/styles.js +0 -32
- package/dist/components/organisms/Chat/Header/Header.stories.js +0 -96
- package/dist/components/organisms/Chat/Header/index.js +0 -84
- package/dist/components/organisms/Chat/Header/styles.js +0 -20
- package/dist/components/organisms/Chat/index.js +0 -327
- package/dist/components/organisms/Chat/styles.js +0 -29
- package/dist/components/organisms/Modal/Modal.stories.js +0 -66
- package/dist/components/organisms/Modal/index.js +0 -95
- package/dist/components/organisms/Modal/styles.js +0 -20
- package/dist/components/organisms/RangeCalendar/RangeCalendar.stories.js +0 -33
- package/dist/components/organisms/RangeCalendar/index.js +0 -148
- package/dist/components/organisms/RangeCalendar/styles.js +0 -27
- package/dist/global-files/handle_http.js +0 -383
- package/dist/global-files/utils.js +0 -484
- package/src/assets/images/customSelect/starIcon.svg +0 -14
- package/src/assets/images/defaultImages/Spinner.gif +0 -0
- package/src/assets/images/defaultImages/notFound.svg +0 -124
- package/src/components/atoms/ButtonFileChooser/ButtonFileChooser.stories.js +0 -47
- package/src/components/atoms/ButtonFileChooser/index.js +0 -69
- package/src/components/atoms/ButtonFileChooser/styles.js +0 -4
- package/src/components/atoms/ButtonV2/ButtonV2.stories.js +0 -53
- package/src/components/atoms/ButtonV2/index.js +0 -85
- package/src/components/atoms/ButtonV2/styles.js +0 -217
- package/src/components/atoms/CustomIcon/CustomIcon.stories.js +0 -36
- package/src/components/atoms/CustomIcon/index.js +0 -41
- package/src/components/atoms/CustomIcon/styles.js +0 -85
- package/src/components/atoms/IconFile/IconFile.stories.js +0 -35
- package/src/components/atoms/IconFile/index.js +0 -119
- package/src/components/atoms/IconFile/styles.js +0 -67
- package/src/components/atoms/Image/Image.stories.js +0 -51
- package/src/components/atoms/Image/index.js +0 -55
- package/src/components/atoms/Image/styles.js +0 -34
- package/src/components/atoms/ImageLink/ImageLink.stories.js +0 -43
- package/src/components/atoms/ImageLink/index.js +0 -57
- package/src/components/atoms/ImageLink/styles.js +0 -30
- package/src/components/atoms/ImagePreview/ImagePreview.stories.js +0 -52
- package/src/components/atoms/ImagePreview/index.js +0 -191
- package/src/components/atoms/ImagePreview/styles.js +0 -77
- package/src/components/atoms/InputText/InputText.stories.js +0 -39
- package/src/components/atoms/InputText/index.js +0 -61
- package/src/components/atoms/InputText/styles.js +0 -89
- package/src/components/atoms/NotFound/NotFound.stories.js +0 -19
- package/src/components/atoms/NotFound/index.js +0 -52
- package/src/components/atoms/NotFound/styles.js +0 -55
- package/src/components/atoms/SelectItemV2/SelectItemV2.stories.js +0 -26
- package/src/components/atoms/SelectItemV2/index.js +0 -61
- package/src/components/atoms/SelectItemV2/styles.js +0 -90
- package/src/components/atoms/Tooltip/Tooltip.stories.js +0 -51
- package/src/components/atoms/Tooltip/index.js +0 -59
- package/src/components/atoms/Tooltip/styles.js +0 -42
- package/src/components/molecules/ButtonDownloadFile/DownloadFile.stories.js +0 -54
- package/src/components/molecules/ButtonDownloadFile/index.js +0 -111
- package/src/components/molecules/ButtonDownloadFile/styles.js +0 -66
- package/src/components/molecules/Dropdown/Dropdown.stories.js +0 -103
- package/src/components/molecules/Dropdown/index.js +0 -150
- package/src/components/molecules/Dropdown/styles.js +0 -75
- package/src/components/molecules/ImageTooltip/ImageTooltip.stories.js +0 -68
- package/src/components/molecules/ImageTooltip/index.js +0 -63
- package/src/components/molecules/ImageTooltip/styles.js +0 -18
- package/src/components/molecules/SelectV2/SelectV2.stories.js +0 -114
- package/src/components/molecules/SelectV2/index.js +0 -350
- package/src/components/molecules/SelectV2/styles.js +0 -105
- package/src/components/molecules/SelectV2/test.js +0 -61
- package/src/components/molecules/SelectV2/test.stories.js +0 -10
- package/src/components/organisms/Chat/Chat.stories.js +0 -199
- package/src/components/organisms/Chat/ChatLists/ChatLists.stories.js +0 -65
- package/src/components/organisms/Chat/ChatLists/Rotoplas.jpeg +0 -0
- package/src/components/organisms/Chat/ChatLists/THD.png +0 -0
- package/src/components/organisms/Chat/ChatLists/index.js +0 -141
- package/src/components/organisms/Chat/ChatLists/styles.js +0 -162
- package/src/components/organisms/Chat/ContainerItems/ContainerItems.stories.js +0 -142
- package/src/components/organisms/Chat/ContainerItems/index.js +0 -549
- package/src/components/organisms/Chat/ContainerItems/styles.js +0 -328
- package/src/components/organisms/Chat/ContentChat/ContentChat.stories.js +0 -102
- package/src/components/organisms/Chat/ContentChat/Rotoplas.jpeg +0 -0
- package/src/components/organisms/Chat/ContentChat/THD.png +0 -0
- package/src/components/organisms/Chat/ContentChat/index.js +0 -900
- package/src/components/organisms/Chat/ContentChat/styles.js +0 -41
- package/src/components/organisms/Chat/Footer/Footer.stories.js +0 -22
- package/src/components/organisms/Chat/Footer/index.js +0 -669
- package/src/components/organisms/Chat/Footer/styles.js +0 -286
- package/src/components/organisms/Chat/Header/Header.stories.js +0 -66
- package/src/components/organisms/Chat/Header/index.js +0 -94
- package/src/components/organisms/Chat/Header/styles.js +0 -49
- package/src/components/organisms/Chat/index.js +0 -294
- package/src/components/organisms/Chat/styles.js +0 -42
- package/src/components/organisms/Modal/Modal.stories.js +0 -55
- package/src/components/organisms/Modal/index.js +0 -97
- package/src/components/organisms/Modal/styles.js +0 -103
- package/src/components/organisms/RangeCalendar/RangeCalendar.stories.js +0 -16
- package/src/components/organisms/RangeCalendar/index.js +0 -121
- package/src/components/organisms/RangeCalendar/styles.js +0 -883
- package/src/global-files/handle_http.js +0 -231
- package/src/global-files/utils.js +0 -309
package/.env.development
CHANGED
|
@@ -21,13 +21,10 @@ REACT_APP_READ_REQUIRED_ORDERS=https://fc069ovhuk.execute-api.us-east-1.amazonaw
|
|
|
21
21
|
REACT_APP_CATEGORY_ENDPOINT=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/categories
|
|
22
22
|
REACT_APP_READ_PROVIDERS=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/providers
|
|
23
23
|
REACT_APP_PENDING_INVITATIONS=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/pending-invitations
|
|
24
|
-
REACT_APP_PRODUCTS_CHAT_ENDPOINT=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/products-chat
|
|
25
|
-
REACT_APP_TICKETS_CHAT_ENDPOINT=https://ocqbzaa4a2.execute-api.us-east-1.amazonaws.com/dev/ticket-chat
|
|
26
|
-
REACT_APP_IMAGES_ENDPOINT=https://content-management-images.s3.amazonaws.com
|
|
27
24
|
|
|
28
25
|
REACT_APP_IMAGES_BUCKET=content-management-images
|
|
29
|
-
REACT_APP_KEY_UPLOAD_TO_S3=AKIA5CPHLQTT46EQ5TIK
|
|
30
26
|
REACT_APP_IMAGES_PROFILE_BUCKET=content-management-profile
|
|
31
|
-
|
|
27
|
+
REACT_APP_KUTS3=AKIA5CPHLQTTS22HCGHW
|
|
28
|
+
REACT_APP_AKUTS3=RSpwEaM0fsLEgN7BJzRyCKqyU0lNExTsPUvxyNXm
|
|
32
29
|
REACT_APP_USER_POOL_ID=us-east-1_XMZQdqkGj
|
|
33
30
|
REACT_APP_USER_POOL_WEB_CLIENT_ID=5ac8tpgs6gbsq13frvrpieep40
|
package/.env.production
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
REACT_APP_ARTICLE_DATA_ENDPOINT=https://
|
|
2
|
-
REACT_APP_ARTICLE_DATA_DATASHEET_ENDPOINT=https://
|
|
3
|
-
REACT_APP_ARTICLE_DATA_DESCRIPTION_ENDPOINT=https://
|
|
4
|
-
REACT_APP_ARTICLE_DATA_IMAGES_ENDPOINT=https://
|
|
5
|
-
REACT_APP_ARTICLE_DATA_ENDPOINT=https://
|
|
6
|
-
REACT_APP_VALID_EXPORT_ENDPOINT = https://
|
|
7
|
-
REACT_APP_SERVICES_ENDPOINT = https://
|
|
8
|
-
REACT_APP_EVALUATION_ENDPOINT = https://
|
|
9
|
-
REACT_APP_SEND_EVAL = https://
|
|
10
|
-
REACT_APP_COMMENTS_ENDPOINT = https://
|
|
11
|
-
REACT_APP_USER_ENDPOINT=https://
|
|
12
|
-
REACT_APP_ASSIGNATIONS_ENDPOINT = https://
|
|
13
|
-
REACT_APP_TASKS_ENDPOINT = https://
|
|
14
|
-
REACT_APP_USER_TASKS_ENDPOINT = https://
|
|
15
|
-
REACT_APP_CART = https://
|
|
16
|
-
REACT_APP_RETAILER_REQUEST = https://
|
|
17
|
-
REACT_APP_VERSIONS_ENDPOINT = https://
|
|
18
|
-
REACT_APP_RETAILER_ENDPOINT=https://
|
|
19
|
-
REACT_APP_READ_ORDERS_BY_STATUS=https://
|
|
20
|
-
REACT_APP_READ_REQUIRED_ORDERS=https://
|
|
21
|
-
REACT_APP_CATEGORY_ENDPOINT=https://
|
|
22
|
-
REACT_APP_READ_PROVIDERS=https://
|
|
23
|
-
REACT_APP_PENDING_INVITATIONS=https://
|
|
1
|
+
REACT_APP_ARTICLE_DATA_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/articles-data
|
|
2
|
+
REACT_APP_ARTICLE_DATA_DATASHEET_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/articles-data/datasheets
|
|
3
|
+
REACT_APP_ARTICLE_DATA_DESCRIPTION_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/articles-data/descriptions
|
|
4
|
+
REACT_APP_ARTICLE_DATA_IMAGES_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/articles-data/images
|
|
5
|
+
REACT_APP_ARTICLE_DATA_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/articles-data
|
|
6
|
+
REACT_APP_VALID_EXPORT_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/valid-export
|
|
7
|
+
REACT_APP_SERVICES_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/services
|
|
8
|
+
REACT_APP_EVALUATION_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/evaluations
|
|
9
|
+
REACT_APP_SEND_EVAL = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/eval-status
|
|
10
|
+
REACT_APP_COMMENTS_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/comments
|
|
11
|
+
REACT_APP_USER_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/users
|
|
12
|
+
REACT_APP_ASSIGNATIONS_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/assignations
|
|
13
|
+
REACT_APP_TASKS_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/tasks
|
|
14
|
+
REACT_APP_USER_TASKS_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/user-tasks
|
|
15
|
+
REACT_APP_CART = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/cart
|
|
16
|
+
REACT_APP_RETAILER_REQUEST = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/retailers-request
|
|
17
|
+
REACT_APP_VERSIONS_ENDPOINT = https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/versions
|
|
18
|
+
REACT_APP_RETAILER_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/retailers
|
|
19
|
+
REACT_APP_READ_ORDERS_BY_STATUS=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/read-orders-by-status
|
|
20
|
+
REACT_APP_READ_REQUIRED_ORDERS=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/read-required-orders
|
|
21
|
+
REACT_APP_CATEGORY_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/categories
|
|
22
|
+
REACT_APP_READ_PROVIDERS=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/providers
|
|
23
|
+
REACT_APP_PENDING_INVITATIONS=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/pending-invitations
|
|
24
24
|
|
|
25
25
|
REACT_APP_IMAGES_BUCKET=content-management-images-prod
|
|
26
|
-
REACT_APP_KEY_UPLOAD_TO_S3=AKIA5CPHLQTT46EQ5TIK
|
|
27
26
|
REACT_APP_IMAGES_PROFILE_BUCKET=content-management-profile-prod
|
|
28
|
-
|
|
27
|
+
REACT_APP_KUTS3=AKIA5CPHLQTT46EQ5TIK
|
|
28
|
+
REACT_APP_AKUTS3=tZDdrmvwxM1cScspfxFM3XpU4HSYrCNPazyHd0BL
|
|
29
29
|
REACT_APP_USER_POOL_ID=us-east-1_XMZQdqkGj
|
|
30
30
|
REACT_APP_USER_POOL_WEB_CLIENT_ID=5ac8tpgs6gbsq13frvrpieep40
|
|
@@ -20,12 +20,16 @@ var Button = function Button(_ref) {
|
|
|
20
20
|
image = _ref.image,
|
|
21
21
|
altText = _ref.altText,
|
|
22
22
|
buttonFont = _ref.buttonFont,
|
|
23
|
-
|
|
23
|
+
_onClick = _ref.onClick;
|
|
24
24
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.Container, {
|
|
25
25
|
id: id,
|
|
26
26
|
className: buttonType,
|
|
27
27
|
buttonFont: buttonFont,
|
|
28
|
-
onClick: onClick
|
|
28
|
+
onClick: function onClick(e) {
|
|
29
|
+
e.stopPropagation();
|
|
30
|
+
|
|
31
|
+
_onClick(e);
|
|
32
|
+
},
|
|
29
33
|
disabled: buttonType === "general-button-disabled",
|
|
30
34
|
children: [buttonType.includes("general") && label, image && /*#__PURE__*/(0, _jsxRuntime.jsx)("img", {
|
|
31
35
|
src: image,
|
|
@@ -23,10 +23,11 @@ var VersionSelect = function VersionSelect(_ref) {
|
|
|
23
23
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("select", {
|
|
24
24
|
id: id,
|
|
25
25
|
name: id,
|
|
26
|
-
value:
|
|
26
|
+
value: selectedVersions[id],
|
|
27
27
|
onChange: onChange,
|
|
28
28
|
children: versions.map(function (item, index) {
|
|
29
29
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("option", {
|
|
30
|
+
value: item.version,
|
|
30
31
|
children: ["Version ", item.version]
|
|
31
32
|
}, "".concat(id, "-").concat(index));
|
|
32
33
|
})
|
|
@@ -11,8 +11,6 @@ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/
|
|
|
11
11
|
|
|
12
12
|
var _index = require("./index");
|
|
13
13
|
|
|
14
|
-
var _starIcon = _interopRequireDefault(require("../../../assets/images/customSelect/starIcon.svg"));
|
|
15
|
-
|
|
16
14
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
17
15
|
|
|
18
16
|
var _default = {
|
|
@@ -28,26 +26,29 @@ var Template = function Template(args) {
|
|
|
28
26
|
var CustomSelectDefault = Template.bind({});
|
|
29
27
|
exports.CustomSelectDefault = CustomSelectDefault;
|
|
30
28
|
CustomSelectDefault.args = {
|
|
31
|
-
|
|
29
|
+
selectLabel: "Todos los departamentos",
|
|
32
30
|
defaultOption: "Todos los departamentos",
|
|
33
31
|
options: [{
|
|
34
|
-
id:
|
|
35
|
-
|
|
36
|
-
|
|
32
|
+
id: 1,
|
|
33
|
+
value: "Decoración",
|
|
34
|
+
subOptions: [{
|
|
35
|
+
id: 1,
|
|
36
|
+
value: "Espejos"
|
|
37
|
+
}, {
|
|
38
|
+
id: 2,
|
|
39
|
+
value: "Persianas"
|
|
40
|
+
}]
|
|
41
|
+
}, {
|
|
42
|
+
id: 2,
|
|
43
|
+
value: "Eléctrico"
|
|
44
|
+
}, {
|
|
45
|
+
id: 3,
|
|
46
|
+
value: "Ferretería"
|
|
47
|
+
}, {
|
|
48
|
+
id: 4,
|
|
49
|
+
value: "Herramientas"
|
|
37
50
|
}, {
|
|
38
|
-
id:
|
|
39
|
-
|
|
40
|
-
}]
|
|
41
|
-
onClickItem: function onClickItem(v, id) {
|
|
42
|
-
if (v) {
|
|
43
|
-
console.log("Agregar a la lista", id);
|
|
44
|
-
} else {
|
|
45
|
-
console.log("Eliminar a la lista", id);
|
|
46
|
-
}
|
|
47
|
-
},
|
|
48
|
-
icon: _starIcon.default,
|
|
49
|
-
showSearchBar: true,
|
|
50
|
-
customOptions: /*#__PURE__*/(0, _jsxRuntime.jsx)("p", {
|
|
51
|
-
children: "Esto es un customOptions"
|
|
52
|
-
})
|
|
51
|
+
id: 5,
|
|
52
|
+
value: "Iluminación"
|
|
53
|
+
}]
|
|
53
54
|
};
|
|
@@ -26,8 +26,7 @@ var SelecItem = function SelecItem(_ref) {
|
|
|
26
26
|
customSelectId = _ref.customSelectId,
|
|
27
27
|
setParameterArray = _ref.setParameterArray,
|
|
28
28
|
activeFilters = _ref.activeFilters,
|
|
29
|
-
setActiveFilters = _ref.setActiveFilters
|
|
30
|
-
onClickItem = _ref.onClickItem;
|
|
29
|
+
setActiveFilters = _ref.setActiveFilters;
|
|
31
30
|
|
|
32
31
|
var _useState = (0, _react.useState)(false),
|
|
33
32
|
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
@@ -47,10 +46,6 @@ var SelecItem = function SelecItem(_ref) {
|
|
|
47
46
|
id: "main-item-" + option.id,
|
|
48
47
|
label: option.name,
|
|
49
48
|
onChange: function onChange(e) {
|
|
50
|
-
if (onClickItem) {
|
|
51
|
-
onClickItem(e.target.checked, option.id);
|
|
52
|
-
}
|
|
53
|
-
|
|
54
49
|
var subOptions = option.subOptions;
|
|
55
50
|
var filtersCopy = (0, _objectSpread2.default)({}, activeFilters);
|
|
56
51
|
|
|
@@ -113,10 +108,6 @@ var SelecItem = function SelecItem(_ref) {
|
|
|
113
108
|
label: sub.name,
|
|
114
109
|
defaultChecked: activeFilters[option.name] && activeFilters[option.name][sub.name],
|
|
115
110
|
onChange: function onChange(e) {
|
|
116
|
-
if (onClickItem) {
|
|
117
|
-
onClickItem(e.target.checked, sub.id);
|
|
118
|
-
}
|
|
119
|
-
|
|
120
111
|
if (e.target.checked) {
|
|
121
112
|
setParameterArray(function (current) {
|
|
122
113
|
return [].concat((0, _toConsumableArray2.default)(current), [sub.id]).sort(function (a, b) {
|
|
@@ -13,8 +13,6 @@ var _index2 = require("../../atoms/GeneralButton/index");
|
|
|
13
13
|
|
|
14
14
|
var _react = require("react");
|
|
15
15
|
|
|
16
|
-
var _Chat = require("../../organisms/Chat");
|
|
17
|
-
|
|
18
16
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
19
17
|
|
|
20
18
|
var HeaderTop = function HeaderTop(_ref) {
|
|
@@ -27,14 +25,11 @@ var HeaderTop = function HeaderTop(_ref) {
|
|
|
27
25
|
ref: headerTop,
|
|
28
26
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_index.ScreenHeader, {
|
|
29
27
|
text: "Edici\xF3n de producto"
|
|
30
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
window.location.href = "/products";
|
|
36
|
-
}
|
|
37
|
-
})
|
|
28
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Button, {
|
|
29
|
+
buttonType: "close-button",
|
|
30
|
+
onClick: function onClick() {
|
|
31
|
+
window.location.href = "/products";
|
|
32
|
+
}
|
|
38
33
|
})]
|
|
39
34
|
});
|
|
40
35
|
};
|
|
@@ -13,6 +13,6 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
13
13
|
|
|
14
14
|
var _templateObject;
|
|
15
15
|
|
|
16
|
-
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n justify-content: space-between;\n
|
|
16
|
+
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n justify-content: space-between;\n"])));
|
|
17
17
|
|
|
18
18
|
exports.Container = Container;
|
|
@@ -34,22 +34,22 @@ var Children = function Children(step, setStep, versions, selectedVersions, _onC
|
|
|
34
34
|
fontFamily: _variables.FontFamily.Raleway_500,
|
|
35
35
|
headerType: "product-name-header",
|
|
36
36
|
color: _variables.GlobalColors.white,
|
|
37
|
-
text: "Crea una nueva
|
|
37
|
+
text: "Crea una nueva versi\xF3n"
|
|
38
38
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ScreenHeader.ScreenHeader, {
|
|
39
39
|
fontFamily: _variables.FontFamily.Raleway,
|
|
40
40
|
headerType: "retailer-name-header",
|
|
41
41
|
color: _variables.GlobalColors.white,
|
|
42
|
-
text: "Puedes elegir el contenido de versiones anteriores o crear una
|
|
42
|
+
text: "Puedes elegir el contenido de versiones anteriores o crear una versi\xF3n desde cero"
|
|
43
43
|
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
44
44
|
className: "buttons-container",
|
|
45
45
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_GeneralButton.Button, {
|
|
46
|
-
label: "
|
|
46
|
+
label: "Versi\xF3n desde cero",
|
|
47
47
|
buttonType: "general-transparent-button",
|
|
48
48
|
onClick: function onClick() {
|
|
49
49
|
return setStep("empty-version");
|
|
50
50
|
}
|
|
51
51
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_GeneralButton.Button, {
|
|
52
|
-
label: "
|
|
52
|
+
label: "Versi\xF3n personalizada",
|
|
53
53
|
buttonType: "general-default-button",
|
|
54
54
|
onClick: function onClick() {
|
|
55
55
|
return setStep("create-version");
|
|
@@ -67,16 +67,16 @@ var Children = function Children(step, setStep, versions, selectedVersions, _onC
|
|
|
67
67
|
fontFamily: _variables.FontFamily.Raleway_500,
|
|
68
68
|
headerType: "product-name-header",
|
|
69
69
|
color: _variables.GlobalColors.white,
|
|
70
|
-
text: "Si creas una
|
|
70
|
+
text: "Si creas una versi\xF3n desde cero perderas la informaci\xF3n actual"
|
|
71
71
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ScreenHeader.ScreenHeader, {
|
|
72
72
|
fontFamily: _variables.FontFamily.Raleway,
|
|
73
73
|
headerType: "retailer-name-header",
|
|
74
74
|
color: _variables.GlobalColors.white,
|
|
75
|
-
text: "
|
|
75
|
+
text: "\xBFDeseas Continuar?"
|
|
76
76
|
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
77
77
|
className: "buttons-container",
|
|
78
78
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_GeneralButton.Button, {
|
|
79
|
-
label: "
|
|
79
|
+
label: "Atr\xE1s",
|
|
80
80
|
buttonType: "general-transparent-button",
|
|
81
81
|
onClick: function onClick() {
|
|
82
82
|
return setStep("version-options");
|
|
@@ -104,7 +104,7 @@ var Children = function Children(step, setStep, versions, selectedVersions, _onC
|
|
|
104
104
|
className: "selector",
|
|
105
105
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_VersionSelect.VersionSelect, {
|
|
106
106
|
versions: versions,
|
|
107
|
-
label: "Ficha
|
|
107
|
+
label: "Ficha t\xE9cnica",
|
|
108
108
|
id: "datasheet",
|
|
109
109
|
selectedVersions: selectedVersions,
|
|
110
110
|
onChange: function onChange(e) {
|
|
@@ -115,7 +115,7 @@ var Children = function Children(step, setStep, versions, selectedVersions, _onC
|
|
|
115
115
|
className: "selector",
|
|
116
116
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_VersionSelect.VersionSelect, {
|
|
117
117
|
versions: versions,
|
|
118
|
-
label: "
|
|
118
|
+
label: "Descripci\xF3n",
|
|
119
119
|
id: "description",
|
|
120
120
|
selectedVersions: selectedVersions,
|
|
121
121
|
onChange: function onChange(e) {
|
|
@@ -126,7 +126,7 @@ var Children = function Children(step, setStep, versions, selectedVersions, _onC
|
|
|
126
126
|
className: "selector",
|
|
127
127
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_VersionSelect.VersionSelect, {
|
|
128
128
|
versions: versions,
|
|
129
|
-
label: "
|
|
129
|
+
label: "Im\xE1genes",
|
|
130
130
|
id: "image",
|
|
131
131
|
selectedVersions: selectedVersions,
|
|
132
132
|
onChange: function onChange(e) {
|
|
@@ -137,7 +137,7 @@ var Children = function Children(step, setStep, versions, selectedVersions, _onC
|
|
|
137
137
|
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
138
138
|
className: "buttons-container",
|
|
139
139
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_GeneralButton.Button, {
|
|
140
|
-
label: "
|
|
140
|
+
label: "Atr\xE1s",
|
|
141
141
|
buttonType: "general-transparent-button",
|
|
142
142
|
onClick: function onClick() {
|
|
143
143
|
return setStep("version-options");
|
|
@@ -32,137 +32,78 @@ var _axios = _interopRequireDefault(require("axios"));
|
|
|
32
32
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
33
33
|
|
|
34
34
|
var CreateVersion = function CreateVersion(_ref) {
|
|
35
|
-
var
|
|
35
|
+
var articleId = _ref.articleId,
|
|
36
36
|
version = _ref.version,
|
|
37
|
-
setShowCreateVersion = _ref.setShowCreateVersion
|
|
37
|
+
setShowCreateVersion = _ref.setShowCreateVersion,
|
|
38
|
+
versionsList = _ref.versionsList,
|
|
39
|
+
realoadVersion = _ref.realoadVersion,
|
|
40
|
+
jwt = _ref.jwt;
|
|
38
41
|
|
|
39
42
|
var _useState = (0, _react.useState)("version-options"),
|
|
40
43
|
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
41
44
|
step = _useState2[0],
|
|
42
45
|
setStep = _useState2[1];
|
|
43
46
|
|
|
44
|
-
var _useState3 = (0, _react.useState)(
|
|
45
|
-
_useState4 = (0, _slicedToArray2.default)(_useState3, 2),
|
|
46
|
-
versions = _useState4[0],
|
|
47
|
-
setVersions = _useState4[1];
|
|
48
|
-
|
|
49
|
-
var _useState5 = (0, _react.useState)({
|
|
47
|
+
var _useState3 = (0, _react.useState)({
|
|
50
48
|
datasheet: version,
|
|
51
49
|
description: version,
|
|
52
50
|
image: version
|
|
53
51
|
}),
|
|
54
|
-
|
|
55
|
-
selectedVersions =
|
|
56
|
-
setSelectedVersions =
|
|
52
|
+
_useState4 = (0, _slicedToArray2.default)(_useState3, 2),
|
|
53
|
+
selectedVersions = _useState4[0],
|
|
54
|
+
setSelectedVersions = _useState4[1];
|
|
57
55
|
|
|
58
|
-
var
|
|
59
|
-
var _ref2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
|
|
60
|
-
var
|
|
56
|
+
var createVersion = /*#__PURE__*/function () {
|
|
57
|
+
var _ref2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(isEmpty) {
|
|
58
|
+
var data;
|
|
61
59
|
return _regenerator.default.wrap(function _callee$(_context) {
|
|
62
60
|
while (1) {
|
|
63
61
|
switch (_context.prev = _context.next) {
|
|
64
62
|
case 0:
|
|
65
63
|
_context.prev = 0;
|
|
66
|
-
_context.next = 3;
|
|
67
|
-
return (0, _axios.default)({
|
|
68
|
-
method: "get",
|
|
69
|
-
url: "".concat(process.env.REACT_APP_VERSIONS_ENDPOINT, "?articleId=").concat(idArticle, "&provider=true"),
|
|
70
|
-
headers: {
|
|
71
|
-
Authorization: sessionStorage.getItem("jwt")
|
|
72
|
-
}
|
|
73
|
-
});
|
|
74
|
-
|
|
75
|
-
case 3:
|
|
76
|
-
response = _context.sent;
|
|
77
|
-
setVersions(JSON.parse(response.data.body).data);
|
|
78
|
-
_context.next = 10;
|
|
79
|
-
break;
|
|
80
|
-
|
|
81
|
-
case 7:
|
|
82
|
-
_context.prev = 7;
|
|
83
|
-
_context.t0 = _context["catch"](0);
|
|
84
|
-
console.log(_context.t0);
|
|
85
|
-
|
|
86
|
-
case 10:
|
|
87
|
-
case "end":
|
|
88
|
-
return _context.stop();
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
}, _callee, null, [[0, 7]]);
|
|
92
|
-
}));
|
|
93
|
-
|
|
94
|
-
return function getVersions() {
|
|
95
|
-
return _ref2.apply(this, arguments);
|
|
96
|
-
};
|
|
97
|
-
}();
|
|
98
|
-
|
|
99
|
-
var createVersion = /*#__PURE__*/function () {
|
|
100
|
-
var _ref3 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2(isEmpty) {
|
|
101
|
-
var data;
|
|
102
|
-
return _regenerator.default.wrap(function _callee2$(_context2) {
|
|
103
|
-
while (1) {
|
|
104
|
-
switch (_context2.prev = _context2.next) {
|
|
105
|
-
case 0:
|
|
106
|
-
_context2.prev = 0;
|
|
107
64
|
data = {
|
|
108
|
-
articleId:
|
|
65
|
+
articleId: articleId,
|
|
109
66
|
isEmpty: isEmpty
|
|
110
67
|
};
|
|
111
|
-
isEmpty
|
|
112
|
-
|
|
113
|
-
return
|
|
114
|
-
method: "post",
|
|
115
|
-
url: process.env.REACT_APP_VERSIONS_ENDPOINT,
|
|
116
|
-
data: data,
|
|
68
|
+
if (!isEmpty) data["version"] = selectedVersions;
|
|
69
|
+
_context.next = 5;
|
|
70
|
+
return _axios.default.post(process.env.REACT_APP_VERSIONS_ENDPOINT, data, {
|
|
117
71
|
headers: {
|
|
118
|
-
Authorization:
|
|
72
|
+
Authorization: jwt
|
|
119
73
|
}
|
|
120
74
|
});
|
|
121
75
|
|
|
122
76
|
case 5:
|
|
123
77
|
setShowCreateVersion(false);
|
|
124
|
-
|
|
78
|
+
realoadVersion && realoadVersion();
|
|
79
|
+
_context.next = 12;
|
|
125
80
|
break;
|
|
126
81
|
|
|
127
|
-
case
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
console.log(
|
|
82
|
+
case 9:
|
|
83
|
+
_context.prev = 9;
|
|
84
|
+
_context.t0 = _context["catch"](0);
|
|
85
|
+
console.log(_context.t0);
|
|
131
86
|
|
|
132
|
-
case
|
|
87
|
+
case 12:
|
|
133
88
|
case "end":
|
|
134
|
-
return
|
|
89
|
+
return _context.stop();
|
|
135
90
|
}
|
|
136
91
|
}
|
|
137
|
-
},
|
|
92
|
+
}, _callee, null, [[0, 9]]);
|
|
138
93
|
}));
|
|
139
94
|
|
|
140
95
|
return function createVersion(_x) {
|
|
141
|
-
return
|
|
96
|
+
return _ref2.apply(this, arguments);
|
|
142
97
|
};
|
|
143
98
|
}();
|
|
144
99
|
|
|
145
100
|
var onChange = function onChange(e) {
|
|
146
|
-
setSelectedVersions((0, _objectSpread3.default)((0, _objectSpread3.default)({}, selectedVersions), {}, (0, _defineProperty2.default)({}, e.target.name, parseInt(e.target.value
|
|
101
|
+
setSelectedVersions((0, _objectSpread3.default)((0, _objectSpread3.default)({}, selectedVersions), {}, (0, _defineProperty2.default)({}, e.target.name, parseInt(e.target.value))));
|
|
147
102
|
};
|
|
148
103
|
|
|
149
|
-
(0, _react.useEffect)( /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
|
|
150
|
-
return _regenerator.default.wrap(function _callee3$(_context3) {
|
|
151
|
-
while (1) {
|
|
152
|
-
switch (_context3.prev = _context3.next) {
|
|
153
|
-
case 0:
|
|
154
|
-
_context3.next = 2;
|
|
155
|
-
return getVersions();
|
|
156
|
-
|
|
157
|
-
case 2:
|
|
158
|
-
case "end":
|
|
159
|
-
return _context3.stop();
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
}, _callee3);
|
|
163
|
-
})), []);
|
|
164
104
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.Container, {
|
|
165
105
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
106
|
+
id: "create-version",
|
|
166
107
|
className: "modal-container",
|
|
167
108
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
168
109
|
className: "button-container",
|
|
@@ -174,7 +115,7 @@ var CreateVersion = function CreateVersion(_ref) {
|
|
|
174
115
|
return setShowCreateVersion(false);
|
|
175
116
|
}
|
|
176
117
|
})
|
|
177
|
-
}), (0, _RenderChilds.Children)(step, setStep,
|
|
118
|
+
}), (0, _RenderChilds.Children)(step, setStep, versionsList, selectedVersions, onChange, createVersion)]
|
|
178
119
|
})
|
|
179
120
|
});
|
|
180
121
|
};
|
|
@@ -19,6 +19,8 @@ var _index = require("../../atoms/Status/index");
|
|
|
19
19
|
|
|
20
20
|
var _index2 = require("../../atoms/ProgressBar/index");
|
|
21
21
|
|
|
22
|
+
var _index3 = require("../../atoms/Loading/index");
|
|
23
|
+
|
|
22
24
|
var _moment = _interopRequireDefault(require("moment"));
|
|
23
25
|
|
|
24
26
|
require("moment/locale/es");
|
|
@@ -36,17 +38,22 @@ _moment.default.locale("es");
|
|
|
36
38
|
var OrderDetail = function OrderDetail(props) {
|
|
37
39
|
var order = props.order;
|
|
38
40
|
|
|
39
|
-
var _useState = (0, _react.useState)(
|
|
41
|
+
var _useState = (0, _react.useState)(true),
|
|
40
42
|
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
41
|
-
|
|
42
|
-
|
|
43
|
+
isLoading = _useState2[0],
|
|
44
|
+
setIsLoading = _useState2[1];
|
|
43
45
|
|
|
44
|
-
var _useState3 = (0, _react.useState)(
|
|
46
|
+
var _useState3 = (0, _react.useState)(order.payment !== "pagado"),
|
|
45
47
|
_useState4 = (0, _slicedToArray2.default)(_useState3, 2),
|
|
46
|
-
|
|
47
|
-
|
|
48
|
+
showPaymentButton = _useState4[0],
|
|
49
|
+
setShowPaymentButton = _useState4[1];
|
|
50
|
+
|
|
51
|
+
var _useState5 = (0, _react.useState)({}),
|
|
52
|
+
_useState6 = (0, _slicedToArray2.default)(_useState5, 2),
|
|
53
|
+
orderData = _useState6[0],
|
|
54
|
+
setOrderData = _useState6[1];
|
|
48
55
|
|
|
49
|
-
var
|
|
56
|
+
var _useState7 = (0, _react.useState)({
|
|
50
57
|
approved: "-",
|
|
51
58
|
rejected: "-",
|
|
52
59
|
in_progress: "-",
|
|
@@ -56,9 +63,9 @@ var OrderDetail = function OrderDetail(props) {
|
|
|
56
63
|
description: "-",
|
|
57
64
|
images: "-"
|
|
58
65
|
}),
|
|
59
|
-
|
|
60
|
-
dataGeneral =
|
|
61
|
-
setDataGeneral =
|
|
66
|
+
_useState8 = (0, _slicedToArray2.default)(_useState7, 2),
|
|
67
|
+
dataGeneral = _useState8[0],
|
|
68
|
+
setDataGeneral = _useState8[1];
|
|
62
69
|
|
|
63
70
|
var updBilling = function updBilling(articleId, newBillingStatus) {
|
|
64
71
|
props.updateBilling && props.updateBilling({
|
|
@@ -81,6 +88,7 @@ var OrderDetail = function OrderDetail(props) {
|
|
|
81
88
|
|
|
82
89
|
(0, _react.useEffect)(function () {
|
|
83
90
|
var ac = new AbortController();
|
|
91
|
+
setIsLoading(true);
|
|
84
92
|
props.getOrderDetail && props.getOrderDetail({
|
|
85
93
|
query: {
|
|
86
94
|
orderId: order.id_order
|
|
@@ -102,6 +110,7 @@ var OrderDetail = function OrderDetail(props) {
|
|
|
102
110
|
setDataGeneral((0, _objectSpread2.default)((0, _objectSpread2.default)({}, countArticles), {}, {
|
|
103
111
|
totalArticles: totalArticles
|
|
104
112
|
}));
|
|
113
|
+
setIsLoading(false);
|
|
105
114
|
});
|
|
106
115
|
return function () {
|
|
107
116
|
return ac.abort();
|
|
@@ -189,7 +198,7 @@ var OrderDetail = function OrderDetail(props) {
|
|
|
189
198
|
})]
|
|
190
199
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
191
200
|
className: "body",
|
|
192
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_Table.default, {
|
|
201
|
+
children: isLoading ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_index3.Loading, {}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_Table.default, {
|
|
193
202
|
headers: [{
|
|
194
203
|
width: 140,
|
|
195
204
|
name: "UPC"
|
|
@@ -15,7 +15,7 @@ var _variables = require("../../../global-files/variables");
|
|
|
15
15
|
|
|
16
16
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6;
|
|
17
17
|
|
|
18
|
-
var MainContainer = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n position: fixed;\n top: 0;\n right: 0;\n width: 785px;\n height: 100vh;\n z-index: 5;\n background: #ffffff;\n box-sizing: border-box;\n font-family: ", ";\n & > * {\n padding: 0 30px;\n }\n .headerTitle {\n font-weight: bold;\n font-size: 25px;\n }\n\n display: grid;\n grid-template-columns: 1fr;\n grid-template-rows: 101px 120px 1fr 115px;\n grid-column-gap: 0px;\n grid-row-gap: 0px;\n\n .body {\n overflow-y: auto;\n }\n .footer {\n width: 100%;\n display: flex;\n align-items: center;\n height: 115px;\n border-top: 1px solid #e6e6e6;\n position: sticky;\n bottom: 0;\n padding: 20px;\n box-sizing: border-box;\n > h2 {\n margin-right: 20px;\n }\n > div {\n margin-right: 10px;\n }\n }\n"])), _variables.FontFamily.Roboto);
|
|
18
|
+
var MainContainer = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n position: fixed;\n top: 0;\n right: 0;\n width: 785px;\n height: 100vh;\n z-index: 5;\n background: #ffffff;\n box-sizing: border-box;\n font-family: ", ";\n & > * {\n padding: 0 30px;\n }\n box-shadow: -4px 0px 8px 0px rgba(0,0,0,0.1);\n .headerTitle {\n font-weight: bold;\n font-size: 25px;\n }\n\n display: grid;\n grid-template-columns: 1fr;\n grid-template-rows: 101px 120px 1fr 115px;\n grid-column-gap: 0px;\n grid-row-gap: 0px;\n\n .body {\n overflow-y: auto;\n }\n .footer {\n width: 100%;\n display: flex;\n align-items: center;\n height: 115px;\n border-top: 1px solid #e6e6e6;\n position: sticky;\n bottom: 0;\n padding: 20px;\n box-sizing: border-box;\n > h2 {\n margin-right: 20px;\n }\n > div {\n margin-right: 10px;\n }\n }\n"])), _variables.FontFamily.Roboto);
|
|
19
19
|
|
|
20
20
|
exports.MainContainer = MainContainer;
|
|
21
21
|
|
|
@@ -17,7 +17,7 @@ var Header = _styledComponents.default.div(_templateObject || (_templateObject =
|
|
|
17
17
|
|
|
18
18
|
exports.Header = Header;
|
|
19
19
|
|
|
20
|
-
var Column = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n align-items: center;\n height: 35px;\n width: ", ";\n padding: 10px 15px;\n font-family: Roboto;\n font-size: 12px;\n color: ", ";\n font-weight: ", ";\n white-space: nowrap;\n text-overflow: ellipsis;\n .flex {\n display: flex;\n }\n .material-icons.small {\n font-size: 18px;\n color: #b3b3b3;\n }\n .center {\n margin: auto;\n }\n &:nth-child(2) {\n overflow: hidden;\n }\n"])), function (_ref) {
|
|
20
|
+
var Column = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n align-items: center;\n height: 35px;\n width: ", ";\n padding: 10px 15px;\n font-family: Roboto;\n font-size: 12px;\n color: ", ";\n font-weight: ", ";\n white-space: nowrap;\n text-overflow: ellipsis;\n .flex {\n display: flex;\n }\n .material-icons.small {\n font-size: 18px;\n color: #b3b3b3;\n }\n .center {\n margin: auto;\n }\n &:nth-child(2) {\n overflow: hidden;\n }\n\n .tooltip {\n position: relative;\n display: inline-block;\n }\n\n .tooltip .tooltiptext {\n visibility: hidden;\n background-color: #fff;\n color: black;\n text-align: center;\n padding: 5px 0;\n border-radius: 3px;\n \n position: absolute;\n z-index: 1;\n top: -8px;\n left: 3px;\n font-family: Roboto;\n font-size: 10px;\n padding: 2px 5px;\n }\n\n .tooltip:hover .tooltiptext {\n visibility: visible;\n }\n"])), function (_ref) {
|
|
21
21
|
var width = _ref.width;
|
|
22
22
|
return "".concat(width, "px");
|
|
23
23
|
}, function (_ref2) {
|