contentoh-components-library 21.4.57 → 21.4.59
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/index.js +2 -7
- 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/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/molecules/TagAndInput/index.js +3 -64
- 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/FullProductNameHeader/index.js +2 -2
- package/dist/components/organisms/InputGroup/index.js +48 -154
- package/dist/components/organisms/Modal/styles.js +1 -1
- package/dist/components/pages/Dashboard/index.js +2 -8
- package/dist/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +137 -123
- package/dist/components/pages/ProviderProductEdition/index.js +258 -269
- 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 +276 -278
- package/dist/components/pages/RetailerProductEdition/styles.js +1 -1
- package/dist/components/pages/RetailerProductEdition/utils.js +2 -61
- package/dist/global-files/data.js +8 -21
- 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/index.js +1 -4
- 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/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 +8 -52
- 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/FullProductNameHeader/index.js +1 -1
- package/src/components/organisms/InputGroup/index.js +88 -238
- 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/index.js +1 -6
- package/src/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +145 -141
- package/src/components/pages/ProviderProductEdition/index.js +148 -145
- 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 +144 -115
- package/src/components/pages/RetailerProductEdition/styles.js +0 -4
- package/src/components/pages/RetailerProductEdition/utils.js +0 -37
- package/src/global-files/data.js +6 -10
- package/src/global-files/variables.js +0 -4
- package/src/index.js +0 -11
- package/src/assets/images/Icons/info.svg +0 -8
- 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/TabSection/styles.js +0 -23
- 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/BoxAttribute/BoxAttribute.stories.js +0 -16
- package/src/components/molecules/BoxAttribute/index.js +0 -72
- package/src/components/molecules/BoxAttribute/styles.js +0 -41
- package/src/components/molecules/BoxButtons/BoxButtons.stories.js +0 -15
- package/src/components/molecules/BoxButtons/index.js +0 -32
- package/src/components/molecules/BoxButtons/styles.js +0 -43
- 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/Box/Box.stories.js +0 -17
- package/src/components/organisms/Box/index.js +0 -103
- package/src/components/organisms/Box/styles.js +0 -48
- package/src/components/organisms/BoxOnboarding/BoxOnboarding.stories.js +0 -17
- package/src/components/organisms/BoxOnboarding/index.js +0 -60
- package/src/components/organisms/BoxOnboarding/styles.js +0 -44
- 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
|
@@ -23,7 +23,7 @@ export const FullProductNameHeader = ({
|
|
|
23
23
|
useEffect(() => {
|
|
24
24
|
const rtls = headerData?.retailers || headerData?.retailersAvailable;
|
|
25
25
|
servicesData &&
|
|
26
|
-
rtls
|
|
26
|
+
rtls.forEach((rt) => {
|
|
27
27
|
const element = [];
|
|
28
28
|
servicesData.forEach((sd) => {
|
|
29
29
|
if (sd.id_retailer === rt.id) {
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
import { Container } from "./styles";
|
|
2
2
|
import { ScreenHeader } from "../../atoms/ScreenHeader";
|
|
3
3
|
import { TagAndInput } from "../../molecules/TagAndInput";
|
|
4
|
-
import { BoxOnboarding } from "../BoxOnboarding";
|
|
5
|
-
import { Box } from "../Box";
|
|
6
|
-
import { useEffect, useState } from "react";
|
|
7
4
|
|
|
8
5
|
export const InputGroup = ({
|
|
9
6
|
inputGroup = {},
|
|
@@ -19,9 +16,6 @@ export const InputGroup = ({
|
|
|
19
16
|
version,
|
|
20
17
|
dinamicHeight,
|
|
21
18
|
compare,
|
|
22
|
-
groupData = [],
|
|
23
|
-
setUpdatedBoxData,
|
|
24
|
-
activeRetailer
|
|
25
19
|
}) => {
|
|
26
20
|
const inputTypeValue = (type) => {
|
|
27
21
|
switch (type) {
|
|
@@ -33,245 +27,101 @@ export const InputGroup = ({
|
|
|
33
27
|
return "text";
|
|
34
28
|
}
|
|
35
29
|
};
|
|
36
|
-
const [showBox, setShowBox] = useState(false);
|
|
37
30
|
|
|
38
31
|
const isEquals = (dataInputsVal, auditInputsVal) => {
|
|
39
32
|
const result = dataInputsVal === auditInputsVal;
|
|
40
33
|
return result;
|
|
41
34
|
};
|
|
42
35
|
|
|
43
|
-
|
|
44
|
-
useEffect(() => {
|
|
45
|
-
if (inputGroup.groupId === "16" && activeRetailer && activeRetailer?.retailer?.id) {
|
|
46
|
-
if (activeRetailer?.retailer?.id === 68) {
|
|
47
|
-
setShowBox(true);
|
|
48
|
-
} else {
|
|
49
|
-
setShowBox(false);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}, [activeRetailer, inputGroup.groupId]);
|
|
53
|
-
|
|
54
|
-
// useEffect(() => {
|
|
55
|
-
// if (showBox) {
|
|
56
|
-
// // Realiza la acción que deseas cuando showBox es true
|
|
57
|
-
// console.log("showBox es true");
|
|
58
|
-
// } else {
|
|
59
|
-
// // Realiza la acción que deseas cuando showBox es false
|
|
60
|
-
// console.log("showBox es false");
|
|
61
|
-
// }
|
|
62
|
-
// }, [showBox]);
|
|
63
|
-
console.log("dataInputs",dataInputs);
|
|
64
|
-
|
|
65
36
|
return (
|
|
66
|
-
|
|
67
|
-
{
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
onChange={setUpdatedBoxData}
|
|
79
|
-
/>
|
|
80
|
-
</Container>
|
|
81
|
-
)}
|
|
82
|
-
{(inputGroup.groupId !== "16") && (
|
|
83
|
-
<Container
|
|
84
|
-
className={
|
|
85
|
-
activeSection === "Ficha técnica"
|
|
86
|
-
? "datasheets-layout"
|
|
87
|
-
: "descriptions-layout"
|
|
88
|
-
}
|
|
89
|
-
>
|
|
90
|
-
{inputGroup?.dataGroup && (
|
|
91
|
-
<ScreenHeader
|
|
92
|
-
headerType={"retailer-name-header"}
|
|
93
|
-
text={`${inputGroup?.dataGroup}`}
|
|
94
|
-
/>
|
|
95
|
-
)}
|
|
96
|
-
<div className="inputs-container">
|
|
97
|
-
{inputGroup?.inputs?.map((input, index) =>
|
|
98
|
-
activeSection === "Ficha técnica" ? (
|
|
99
|
-
<>
|
|
100
|
-
<TagAndInput
|
|
101
|
-
key={
|
|
102
|
-
index +
|
|
103
|
-
"-" +
|
|
104
|
-
dataInputs[input]?.value +
|
|
105
|
-
"-" +
|
|
106
|
-
dataInputs[input]?.id +
|
|
107
|
-
"-" +
|
|
108
|
-
compare
|
|
109
|
-
}
|
|
110
|
-
//disabled={input === 40001}
|
|
111
|
-
disabled={false}
|
|
112
|
-
inputId={dataInputs[input]?.id}
|
|
113
|
-
version={version}
|
|
114
|
-
inputType={inputTypeValue(dataInputs[input]?.type)}
|
|
115
|
-
label={
|
|
116
|
-
dataInputs[input]?.name +
|
|
117
|
-
(dataInputs[input]?.required ? "*" : "")
|
|
118
|
-
}
|
|
119
|
-
value={
|
|
120
|
-
compare
|
|
121
|
-
? auditInputs[input]?.value
|
|
122
|
-
: dataInputs[input]?.value
|
|
123
|
-
}
|
|
124
|
-
inputPlaceHolder={input?.placeholder}
|
|
125
|
-
articleId={articleId}
|
|
126
|
-
isRequired={dataInputs[input]?.required}
|
|
127
|
-
updatedDatasheets={updatedDatasheets}
|
|
128
|
-
setUpdatedDatasheets={setUpdatedDatasheets}
|
|
129
|
-
maxChar={
|
|
130
|
-
dataInputs[input]?.max_chars
|
|
131
|
-
? dataInputs[input]?.max_chars
|
|
132
|
-
: 999
|
|
133
|
-
}
|
|
134
|
-
optionList={dataInputs[input]?.option_list}
|
|
135
|
-
description={dataInputs[input]?.description}
|
|
136
|
-
showTooltip={true}
|
|
137
|
-
auditClass={
|
|
138
|
-
compare &&
|
|
139
|
-
!isEquals(dataInputs[input].value, auditInputs[input].value)
|
|
140
|
-
? "audit-class"
|
|
141
|
-
: ""
|
|
142
|
-
}
|
|
143
|
-
/>
|
|
144
|
-
</>
|
|
145
|
-
) : (
|
|
146
|
-
<TagAndInput
|
|
147
|
-
key={index + "-" + input?.value + "-" + compare}
|
|
148
|
-
inputId={input.id}
|
|
149
|
-
index={index}
|
|
150
|
-
inputType={"textarea"}
|
|
151
|
-
label={input?.name + (input.required ? "*" : "")}
|
|
152
|
-
value={
|
|
153
|
-
compare ? auditInputGroup?.inputs[index]?.value : input?.value
|
|
154
|
-
}
|
|
155
|
-
isRequired={input.required}
|
|
156
|
-
maxChar={input.max_chars}
|
|
157
|
-
inputPlaceHolder={input?.placeholder}
|
|
158
|
-
updatedDescriptions={updatedDescriptions}
|
|
159
|
-
setUpdatedDescriptions={setUpdatedDescriptions}
|
|
160
|
-
articleId={articleId}
|
|
161
|
-
version={version}
|
|
162
|
-
dinamicHeight={dinamicHeight}
|
|
163
|
-
description={input?.description}
|
|
164
|
-
showTooltip={true}
|
|
165
|
-
auditClass={
|
|
166
|
-
compare &&
|
|
167
|
-
!isEquals(input?.value, auditInputGroup?.inputs[index]?.value)
|
|
168
|
-
? "audit-class"
|
|
169
|
-
: ""
|
|
170
|
-
}
|
|
171
|
-
/>
|
|
172
|
-
)
|
|
173
|
-
)}
|
|
174
|
-
</div>
|
|
175
|
-
</Container>
|
|
37
|
+
<Container
|
|
38
|
+
className={
|
|
39
|
+
activeSection === "Ficha técnica"
|
|
40
|
+
? "datasheets-layout"
|
|
41
|
+
: "descriptions-layout"
|
|
42
|
+
}
|
|
43
|
+
>
|
|
44
|
+
{inputGroup?.dataGroup && (
|
|
45
|
+
<ScreenHeader
|
|
46
|
+
headerType={"retailer-name-header"}
|
|
47
|
+
text={inputGroup?.dataGroup}
|
|
48
|
+
/>
|
|
176
49
|
)}
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
50
|
+
<div className="inputs-container">
|
|
51
|
+
{inputGroup?.inputs?.map((input, index) =>
|
|
52
|
+
activeSection === "Ficha técnica" ? (
|
|
53
|
+
<TagAndInput
|
|
54
|
+
key={
|
|
55
|
+
index +
|
|
56
|
+
"-" +
|
|
57
|
+
dataInputs[input]?.value +
|
|
58
|
+
"-" +
|
|
59
|
+
dataInputs[input]?.id +
|
|
60
|
+
"-" +
|
|
61
|
+
compare
|
|
62
|
+
}
|
|
63
|
+
//disabled={input === 40001}
|
|
64
|
+
disabled={false}
|
|
65
|
+
inputId={dataInputs[input]?.id}
|
|
66
|
+
version={version}
|
|
67
|
+
inputType={inputTypeValue(dataInputs[input]?.type)}
|
|
68
|
+
label={
|
|
69
|
+
dataInputs[input]?.name +
|
|
70
|
+
(dataInputs[input]?.required ? "*" : "")
|
|
71
|
+
}
|
|
72
|
+
value={
|
|
73
|
+
compare ? auditInputs[input]?.value : dataInputs[input]?.value
|
|
74
|
+
}
|
|
75
|
+
inputPlaceHolder={input?.placeholder}
|
|
76
|
+
articleId={articleId}
|
|
77
|
+
isRequired={dataInputs[input]?.required}
|
|
78
|
+
updatedDatasheets={updatedDatasheets}
|
|
79
|
+
setUpdatedDatasheets={setUpdatedDatasheets}
|
|
80
|
+
maxChar={
|
|
81
|
+
dataInputs[input]?.max_chars
|
|
82
|
+
? dataInputs[input]?.max_chars
|
|
83
|
+
: 999
|
|
84
|
+
}
|
|
85
|
+
optionList={dataInputs[input]?.option_list}
|
|
86
|
+
description={dataInputs[input]?.description}
|
|
87
|
+
showTooltip={true}
|
|
88
|
+
auditClass={
|
|
89
|
+
compare &&
|
|
90
|
+
!isEquals(dataInputs[input].value, auditInputs[input].value)
|
|
91
|
+
? "audit-class"
|
|
92
|
+
: ""
|
|
93
|
+
}
|
|
189
94
|
/>
|
|
190
|
-
)
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
isRequired={dataInputs[input]?.required}
|
|
222
|
-
updatedDatasheets={updatedDatasheets}
|
|
223
|
-
setUpdatedDatasheets={setUpdatedDatasheets}
|
|
224
|
-
maxChar={
|
|
225
|
-
dataInputs[input]?.max_chars
|
|
226
|
-
? dataInputs[input]?.max_chars
|
|
227
|
-
: 999
|
|
228
|
-
}
|
|
229
|
-
optionList={dataInputs[input]?.option_list}
|
|
230
|
-
description={dataInputs[input]?.description}
|
|
231
|
-
showTooltip={true}
|
|
232
|
-
inputGroup={inputGroup}
|
|
233
|
-
dataInputs={dataInputs}
|
|
234
|
-
onChange={setUpdatedBoxData}
|
|
235
|
-
auditClass={
|
|
236
|
-
compare &&
|
|
237
|
-
!isEquals(dataInputs[input].value, auditInputs[input].value)
|
|
238
|
-
? "audit-class"
|
|
239
|
-
: ""
|
|
240
|
-
}
|
|
241
|
-
/>
|
|
242
|
-
</>
|
|
243
|
-
) : (
|
|
244
|
-
<TagAndInput
|
|
245
|
-
key={index + "-" + input?.value + "-" + compare}
|
|
246
|
-
inputId={input.id}
|
|
247
|
-
index={index}
|
|
248
|
-
inputType={"textarea"}
|
|
249
|
-
label={input?.name + (input.required ? "*" : "")}
|
|
250
|
-
value={
|
|
251
|
-
compare ? auditInputGroup?.inputs[index]?.value : input?.value
|
|
252
|
-
}
|
|
253
|
-
isRequired={input.required}
|
|
254
|
-
maxChar={input.max_chars}
|
|
255
|
-
inputPlaceHolder={input?.placeholder}
|
|
256
|
-
updatedDescriptions={updatedDescriptions}
|
|
257
|
-
setUpdatedDescriptions={setUpdatedDescriptions}
|
|
258
|
-
articleId={articleId}
|
|
259
|
-
version={version}
|
|
260
|
-
dinamicHeight={dinamicHeight}
|
|
261
|
-
description={input?.description}
|
|
262
|
-
showTooltip={true}
|
|
263
|
-
auditClass={
|
|
264
|
-
compare &&
|
|
265
|
-
!isEquals(input?.value, auditInputGroup?.inputs[index]?.value)
|
|
266
|
-
? "audit-class"
|
|
267
|
-
: ""
|
|
268
|
-
}
|
|
269
|
-
/>
|
|
270
|
-
)
|
|
271
|
-
)}
|
|
272
|
-
</div>
|
|
273
|
-
</Container>
|
|
274
|
-
)}
|
|
275
|
-
</>
|
|
95
|
+
) : (
|
|
96
|
+
<TagAndInput
|
|
97
|
+
key={index + "-" + input?.value + "-" + compare}
|
|
98
|
+
inputId={input.id}
|
|
99
|
+
index={index}
|
|
100
|
+
inputType={"textarea"}
|
|
101
|
+
label={input?.name + (input.required ? "*" : "")}
|
|
102
|
+
value={
|
|
103
|
+
compare ? auditInputGroup?.inputs[index]?.value : input?.value
|
|
104
|
+
}
|
|
105
|
+
isRequired={input.required}
|
|
106
|
+
maxChar={input.max_chars}
|
|
107
|
+
inputPlaceHolder={input?.placeholder}
|
|
108
|
+
updatedDescriptions={updatedDescriptions}
|
|
109
|
+
setUpdatedDescriptions={setUpdatedDescriptions}
|
|
110
|
+
articleId={articleId}
|
|
111
|
+
version={version}
|
|
112
|
+
dinamicHeight={dinamicHeight}
|
|
113
|
+
description={input?.description}
|
|
114
|
+
showTooltip={true}
|
|
115
|
+
auditClass={
|
|
116
|
+
compare &&
|
|
117
|
+
!isEquals(input?.value, auditInputGroup?.inputs[index]?.value)
|
|
118
|
+
? "audit-class"
|
|
119
|
+
: ""
|
|
120
|
+
}
|
|
121
|
+
/>
|
|
122
|
+
)
|
|
123
|
+
)}
|
|
124
|
+
</div>
|
|
125
|
+
</Container>
|
|
276
126
|
);
|
|
277
|
-
}
|
|
127
|
+
};
|
|
@@ -31,6 +31,7 @@ export const ContainerModal = styled.div`
|
|
|
31
31
|
align-items: center;
|
|
32
32
|
justify-content: flex-start;
|
|
33
33
|
gap: 6px;
|
|
34
|
+
margin-bottom: 20px;
|
|
34
35
|
|
|
35
36
|
.label-title {
|
|
36
37
|
width: 100%;
|
|
@@ -41,10 +42,6 @@ export const ContainerModal = styled.div`
|
|
|
41
42
|
color: #262626;
|
|
42
43
|
white-space: pre-wrap;
|
|
43
44
|
}
|
|
44
|
-
|
|
45
|
-
& + * {
|
|
46
|
-
margin-top: 20px;
|
|
47
|
-
}
|
|
48
45
|
}
|
|
49
46
|
|
|
50
47
|
.iconModal {
|
|
@@ -1,31 +1,41 @@
|
|
|
1
1
|
export const servicesCodeIcon = {
|
|
2
2
|
datasheet: (
|
|
3
3
|
<div key="datasheet" className="tooltip">
|
|
4
|
-
<span className="material-icons small"
|
|
4
|
+
<span className="material-icons small">
|
|
5
|
+

|
|
6
|
+
</span>
|
|
5
7
|
<span className="tooltiptext">Ficha Técnica</span>
|
|
6
8
|
</div>
|
|
7
9
|
),
|
|
8
10
|
description: (
|
|
9
11
|
<div key="description" className="tooltip">
|
|
10
|
-
<span className="material-icons small"
|
|
12
|
+
<span className="material-icons small">
|
|
13
|
+

|
|
14
|
+
</span>
|
|
11
15
|
<span className="tooltiptext">Descripción</span>
|
|
12
16
|
</div>
|
|
13
17
|
),
|
|
14
18
|
image: (
|
|
15
19
|
<div key="image" className="tooltip">
|
|
16
|
-
<span className="material-icons small"
|
|
20
|
+
<span className="material-icons small">
|
|
21
|
+

|
|
22
|
+
</span>
|
|
17
23
|
<span className="tooltiptext">Imagen</span>
|
|
18
24
|
</div>
|
|
19
25
|
),
|
|
20
26
|
translate: (
|
|
21
27
|
<div key="translate" className="tooltip">
|
|
22
|
-
<span className="material-icons small"
|
|
28
|
+
<span className="material-icons small">
|
|
29
|
+

|
|
30
|
+
</span>
|
|
23
31
|
<span className="tooltiptext">Traducción</span>
|
|
24
32
|
</div>
|
|
25
33
|
),
|
|
26
34
|
build: (
|
|
27
|
-
<div key="build"
|
|
28
|
-
<span className="material-icons small"
|
|
35
|
+
<div key="build" className="tooltip">
|
|
36
|
+
<span className="material-icons small">
|
|
37
|
+

|
|
38
|
+
</span>
|
|
29
39
|
<span className="tooltiptext">Construcción</span>
|
|
30
40
|
</div>
|
|
31
41
|
),
|
|
@@ -84,7 +84,7 @@ export const Dashboard = ({ jwt, user, company }) => {
|
|
|
84
84
|
const isRetailer = user.is_retailer && company.retailers;
|
|
85
85
|
const isProvider = !user.is_retailer && user.id_role === 0;
|
|
86
86
|
const isCollaborator = user.id_role > 0;
|
|
87
|
-
const { ordersBydate, ordersByStatus
|
|
87
|
+
const { ordersBydate, ordersByStatus } =
|
|
88
88
|
(await loadProductVersions(orderByStatus)) || {};
|
|
89
89
|
|
|
90
90
|
const { total = 0, R = 0, PA = 0, Ex = 0, ACA = 0 } = ordersByStatus;
|
|
@@ -100,18 +100,13 @@ export const Dashboard = ({ jwt, user, company }) => {
|
|
|
100
100
|
: prev,
|
|
101
101
|
0
|
|
102
102
|
);
|
|
103
|
-
|
|
104
|
-
const registeredProducts = ordersByActive.registered;
|
|
105
103
|
let metricsArray = [
|
|
106
104
|
metricsData[0]
|
|
107
105
|
? metricsData[0]
|
|
108
106
|
: { label: "Productos totales", value: total },
|
|
109
107
|
];
|
|
110
108
|
|
|
111
|
-
console.log(registeredProducts);
|
|
112
|
-
|
|
113
109
|
metricsArray.push(
|
|
114
|
-
{ label: "Productos activos", value: registeredProducts },
|
|
115
110
|
{ label: "Productos filtrados", value: total },
|
|
116
111
|
{ label: "Productos sin asignar", value: PA + R },
|
|
117
112
|
{ label: "Productos en proceso", value: inProcess },
|