contentoh-components-library 21.3.57 → 21.3.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/pages/Dashboard/Dashboard.stories.js +45 -38
- package/dist/components/pages/Dashboard/index.js +4 -8
- package/dist/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +58 -72
- package/dist/components/pages/RetailerProductEdition/index.js +38 -39
- package/package.json +1 -1
- package/src/components/pages/Dashboard/Dashboard.stories.js +47 -38
- package/src/components/pages/Dashboard/index.js +3 -4
- package/src/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +19 -40
- package/src/components/pages/RetailerProductEdition/index.js +37 -37
- package/dist/assets/fonts/roboto/LICENSE.txt +0 -202
|
@@ -27,57 +27,64 @@ var DashboardDeafult = Template.bind({});
|
|
|
27
27
|
exports.DashboardDeafult = DashboardDeafult;
|
|
28
28
|
DashboardDeafult.args = {
|
|
29
29
|
user: {
|
|
30
|
-
id_user:
|
|
31
|
-
name: "
|
|
32
|
-
last_name: "
|
|
33
|
-
email: "
|
|
34
|
-
position: "
|
|
35
|
-
telephone: "",
|
|
30
|
+
id_user: 133,
|
|
31
|
+
name: "Financiado Bodega",
|
|
32
|
+
last_name: "Aurrera",
|
|
33
|
+
email: "financiadobodega@allfreemail.net",
|
|
34
|
+
position: "TI",
|
|
35
|
+
telephone: "+527777777777",
|
|
36
36
|
country: "México",
|
|
37
|
-
id_company:
|
|
38
|
-
id_cognito: "
|
|
37
|
+
id_company: 912,
|
|
38
|
+
id_cognito: "25481a4f-e8c7-4104-b772-64fdb291a640",
|
|
39
39
|
birth_Date: null,
|
|
40
|
-
about_me:
|
|
41
|
-
zip_code:
|
|
42
|
-
address:
|
|
43
|
-
job:
|
|
44
|
-
id_stripe:
|
|
45
|
-
id_role:
|
|
40
|
+
about_me: null,
|
|
41
|
+
zip_code: null,
|
|
42
|
+
address: null,
|
|
43
|
+
job: null,
|
|
44
|
+
id_stripe: null,
|
|
45
|
+
id_role: 0,
|
|
46
46
|
active: 1,
|
|
47
47
|
is_retailer: 0,
|
|
48
48
|
email_notify: 1,
|
|
49
49
|
is_user_tech: null,
|
|
50
50
|
membership: {
|
|
51
|
-
id:
|
|
52
|
-
start_date: "
|
|
53
|
-
end_date: "
|
|
54
|
-
planID:
|
|
55
|
-
plan: "
|
|
56
|
-
name: "Plan
|
|
57
|
-
user_limit: "
|
|
58
|
-
products_limit: "
|
|
59
|
-
type: "
|
|
51
|
+
id: 101,
|
|
52
|
+
start_date: "2022-12-22T19:16:53.000Z",
|
|
53
|
+
end_date: "2023-12-22T19:16:53.000Z",
|
|
54
|
+
planID: 8,
|
|
55
|
+
plan: "prod_KtlhECVSFG2iro",
|
|
56
|
+
name: "Plan Pro",
|
|
57
|
+
user_limit: "20",
|
|
58
|
+
products_limit: "5000",
|
|
59
|
+
type: "Enterprise"
|
|
60
60
|
},
|
|
61
|
-
src: "https://content-management-profile.s3.amazonaws.com/id-
|
|
61
|
+
src: "https://content-management-profile.s3.amazonaws.com/id-133/133.png?1684388625309"
|
|
62
62
|
},
|
|
63
63
|
company: {
|
|
64
|
-
id_company:
|
|
65
|
-
trade_name: "
|
|
66
|
-
company_name: "
|
|
67
|
-
rfc: "
|
|
68
|
-
adress: "
|
|
69
|
-
about_company:
|
|
70
|
-
telephone:
|
|
71
|
-
web_site:
|
|
72
|
-
zip_code:
|
|
64
|
+
id_company: 912,
|
|
65
|
+
trade_name: "Financiado Bodega",
|
|
66
|
+
company_name: "Bodega",
|
|
67
|
+
rfc: "9395jwhs",
|
|
68
|
+
adress: "Toluca",
|
|
69
|
+
about_company: null,
|
|
70
|
+
telephone: null,
|
|
71
|
+
web_site: null,
|
|
72
|
+
zip_code: null,
|
|
73
73
|
email: null,
|
|
74
|
-
social_link:
|
|
74
|
+
social_link: null,
|
|
75
75
|
is_retailer: 0,
|
|
76
|
+
financedRetailers: [{
|
|
77
|
+
id: 70,
|
|
78
|
+
name: "Bodega Aurrera",
|
|
79
|
+
country: "México",
|
|
80
|
+
id_region: 1,
|
|
81
|
+
active: 1
|
|
82
|
+
}],
|
|
76
83
|
retailers: [{
|
|
77
|
-
id:
|
|
78
|
-
name:
|
|
79
|
-
country:
|
|
84
|
+
id: 70,
|
|
85
|
+
name: "Bodega Aurrera",
|
|
86
|
+
country: "México"
|
|
80
87
|
}]
|
|
81
88
|
},
|
|
82
|
-
jwt: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.
|
|
89
|
+
jwt: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIyNTQ4MWE0Zi1lOGM3LTQxMDQtYjc3Mi02NGZkYjI5MWE2NDAiLCJjb2duaXRvOmdyb3VwcyI6WyJ1c3VhcmlvX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwicGhvbmVfbnVtYmVyX3ZlcmlmaWVkIjpmYWxzZSwiY29nbml0bzp1c2VybmFtZSI6IjI1NDgxYTRmLWU4YzctNDEwNC1iNzcyLTY0ZmRiMjkxYTY0MCIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiJlNmQwYTZiNS0wZjMzLTQ4NGItYWM1YS0wNmQ0ZTlkZTY4Y2YiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY4NDM4ODYyNCwibmFtZSI6IkZpbmFuY2lhZG8gQm9kZWdhIEF1cnJlcmEiLCJwaG9uZV9udW1iZXIiOiIrNTI3Nzc3Nzc3Nzc3IiwiZXhwIjoxNjg0MzkyMjI0LCJpYXQiOjE2ODQzODg2MjQsImVtYWlsIjoiZmluYW5jaWFkb2JvZGVnYUBhbGxmcmVlbWFpbC5uZXQifQ.kYOldsvuUQofyxyDtxzVHBKVSbnPp5MK0VHrPsMCOf6Xe5rbo834kJGIVVO4ztguTHkHakKE0o3IQimLH5E8IAk8lX8olm9vTcxwpnlxOOVjePGrMAx2rwJS6Oi_45qE18whJdD_tXxceoZsU4hdDc_zQp64DUac3SfIPjs2ClyGCr66nO1VNXKYSTVGVQgV3Tcx65ah3m04GEsnpwAckUxmfKIws9FGsWl_CalkYG3HMR84psAIEA3kSYpiSF_biOySrXpX6H1HZjLRRR_6-P0AxNVZ6kmVTYbSO4vgmbEsO_feoDwtIxPWc3O7htOcevCAM8KyjmmQwlI52y4caQ"
|
|
83
90
|
};
|
|
@@ -32,7 +32,7 @@ var _axios = _interopRequireDefault(require("axios"));
|
|
|
32
32
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
33
33
|
|
|
34
34
|
var Dashboard = function Dashboard(_ref) {
|
|
35
|
-
var
|
|
35
|
+
var _metricsData$;
|
|
36
36
|
|
|
37
37
|
var jwt = _ref.jwt,
|
|
38
38
|
user = _ref.user,
|
|
@@ -137,10 +137,6 @@ var Dashboard = function Dashboard(_ref) {
|
|
|
137
137
|
totalCount = _useState32[0],
|
|
138
138
|
setTotalCount = _useState32[1];
|
|
139
139
|
|
|
140
|
-
var _useState33 = (0, _react.useState)((company === null || company === void 0 ? void 0 : (_company$financedReta = company.financedRetailers) === null || _company$financedReta === void 0 ? void 0 : _company$financedReta.length) > 0),
|
|
141
|
-
_useState34 = (0, _slicedToArray2.default)(_useState33, 1),
|
|
142
|
-
isProviderFinanced = _useState34[0];
|
|
143
|
-
|
|
144
140
|
var loadProductVersions = /*#__PURE__*/function () {
|
|
145
141
|
var _ref2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(queryObject) {
|
|
146
142
|
var keys, string, query, endpoint, response;
|
|
@@ -205,7 +201,7 @@ var Dashboard = function Dashboard(_ref) {
|
|
|
205
201
|
parsed = JSON.parse(retailersResponse.data.body).data;
|
|
206
202
|
retailers = Object.values(parsed);
|
|
207
203
|
|
|
208
|
-
if (isRetailer
|
|
204
|
+
if (isRetailer) {
|
|
209
205
|
retailersValid = company.retailers.map(function (e) {
|
|
210
206
|
return e.id;
|
|
211
207
|
});
|
|
@@ -459,7 +455,7 @@ var Dashboard = function Dashboard(_ref) {
|
|
|
459
455
|
parameterArray: datesRange,
|
|
460
456
|
setParameterArray: setDatesRange,
|
|
461
457
|
isSingleSelect: true
|
|
462
|
-
}),
|
|
458
|
+
}), company.financedRetailers[0].id !== 70 && (providers === null || providers === void 0 ? void 0 : providers.length) > 0 && /*#__PURE__*/(0, _jsxRuntime.jsx)(_CustomSelect.CustomSelect, {
|
|
463
459
|
showFilterString: true,
|
|
464
460
|
showSearchBar: true,
|
|
465
461
|
options: providers,
|
|
@@ -479,7 +475,7 @@ var Dashboard = function Dashboard(_ref) {
|
|
|
479
475
|
parameterArray: categoryId,
|
|
480
476
|
setParameterArray: setCategoryId,
|
|
481
477
|
defaultOption: "Todas las categor\xEDas"
|
|
482
|
-
}),
|
|
478
|
+
}), company.financedRetailers[0].id !== 70 && (retailers === null || retailers === void 0 ? void 0 : retailers.length) > 1 && /*#__PURE__*/(0, _jsxRuntime.jsx)(_CustomSelect.CustomSelect, {
|
|
483
479
|
showFilterString: true,
|
|
484
480
|
showSearchBar: true,
|
|
485
481
|
options: retailers,
|
|
@@ -7,16 +7,12 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
});
|
|
8
8
|
exports.default = exports.RetailerProductEditionDefault = void 0;
|
|
9
9
|
|
|
10
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
|
|
11
|
-
|
|
12
10
|
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
|
|
13
11
|
|
|
14
12
|
var _index = require("./index");
|
|
15
13
|
|
|
16
14
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
17
15
|
|
|
18
|
-
var _productSelected;
|
|
19
|
-
|
|
20
16
|
var _default = {
|
|
21
17
|
title: "Components/pages/RetailerProductEdition",
|
|
22
18
|
component: _index.RetailerProductEdition
|
|
@@ -36,77 +32,67 @@ RetailerProductEditionDefault.args = {
|
|
|
36
32
|
Imágenes: false
|
|
37
33
|
},
|
|
38
34
|
token: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJhNmM0ZDNkNi0yNGE0LTQxZDQtYWQwZi1kMDg3NDM4YWI1YjYiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6ImE2YzRkM2Q2LTI0YTQtNDFkNC1hZDBmLWQwODc0MzhhYjViNiIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiIyYjU3MjZlMy04MjM2LTRmYzMtODBkMi05NWVmYmU4ODdjOTYiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY4MjAxNjI5MSwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY4MjAxOTg5MSwiaWF0IjoxNjgyMDE2MjkxLCJlbWFpbCI6ImV0Y0Bjb250ZW50b2guY29tIn0.SCj_yp1NkGCED59JHoDSdFAOakIOvZVeC0yLwt9z0BtenDXlU0m5cUofQQonnWPM8Q70yMFEkyMGI9kQs_fz1gxrmrSc2FGefn3B_1Vymq3pQ_S1JrY_syYf88m_GtJKOywEnE6--Ef9lZhFBFKGtqRJ4H8JBa9Xb96uCjAKyEMCSURDlw37pk2RQdULlZPj17Zb6Xrqi2lwrhpI1ByptX3__UoTiZklnTXwIxM4JdU7yuhXLznaEH8NOSd2Jw-CV6FCUbYBHlnRYBQg7B5mwyVKtDQm6QpRgBTBPCvljJJpFjRKUcnon8WZiFXx1qVbkWPt2vCT1TZqqoSLdlP6lA",
|
|
39
|
-
productSelected:
|
|
40
|
-
orderId:
|
|
41
|
-
status: "
|
|
42
|
-
datasheet_status: "
|
|
35
|
+
productSelected: {
|
|
36
|
+
orderId: 14606,
|
|
37
|
+
status: "RA",
|
|
38
|
+
datasheet_status: "RA",
|
|
43
39
|
prio: "none",
|
|
44
|
-
version:
|
|
45
|
-
description_status: "
|
|
46
|
-
images_status: "
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
40
|
+
version: 3,
|
|
41
|
+
description_status: "RA",
|
|
42
|
+
images_status: "RA",
|
|
43
|
+
statusByRetailer: {
|
|
44
|
+
4: {
|
|
45
|
+
datasheet: "RA/AC",
|
|
46
|
+
description: "RA/AC",
|
|
47
|
+
images: "RA/AC"
|
|
48
|
+
},
|
|
49
|
+
5: {
|
|
50
|
+
datasheet: "RA/AC",
|
|
51
|
+
description: "RA/AC",
|
|
52
|
+
images: "RA/AC"
|
|
53
|
+
},
|
|
54
|
+
6: {
|
|
55
|
+
description: "RA/AC",
|
|
56
|
+
images: "RA/AC",
|
|
57
|
+
datasheet: "RA/AC"
|
|
58
|
+
},
|
|
59
|
+
12: {
|
|
60
|
+
datasheet: "RA/AC",
|
|
61
|
+
description: "RA/AC",
|
|
62
|
+
images: "RA/AC"
|
|
63
|
+
},
|
|
64
|
+
17: {
|
|
65
|
+
datasheet: "RA/AC",
|
|
66
|
+
description: "RA/AC",
|
|
67
|
+
images: "RA/AC"
|
|
68
|
+
}
|
|
64
69
|
},
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
70
|
+
article: {
|
|
71
|
+
category: "Puertas y Ventanas|Molduras|Molduras Madera Blanda",
|
|
72
|
+
company_name: "Demo",
|
|
73
|
+
country: "México",
|
|
74
|
+
id_category: "2366",
|
|
75
|
+
id_datasheet_especialist: null,
|
|
76
|
+
id_datasheet_facilitator: null,
|
|
77
|
+
id_description_especialist: null,
|
|
78
|
+
id_description_facilitator: null,
|
|
79
|
+
id_images_especialist: null,
|
|
80
|
+
id_images_facilitator: null,
|
|
81
|
+
id_order: 15160,
|
|
82
|
+
id_article: 39290,
|
|
83
|
+
id_auditor: 37,
|
|
84
|
+
name: "MOLDURA MARCO MODER 11X4X244 CM",
|
|
85
|
+
timestamp: "2023-04-19T21:36:02.000Z",
|
|
86
|
+
upc: "100030"
|
|
69
87
|
},
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
images: "AC"
|
|
79
|
-
}
|
|
80
|
-
}), (0, _defineProperty2.default)(_productSelected, "article", {
|
|
81
|
-
category: "Puertas y Ventanas|Molduras|Molduras Madera Blanda",
|
|
82
|
-
company_name: "Demo",
|
|
83
|
-
country: "México",
|
|
84
|
-
id_category: "2366",
|
|
85
|
-
id_datasheet_especialist: null,
|
|
86
|
-
id_datasheet_facilitator: null,
|
|
87
|
-
id_description_especialist: null,
|
|
88
|
-
id_description_facilitator: null,
|
|
89
|
-
id_images_especialist: null,
|
|
90
|
-
id_images_facilitator: null,
|
|
91
|
-
id_order: 15160,
|
|
92
|
-
id_article: 39290,
|
|
93
|
-
id_auditor: 37,
|
|
94
|
-
name: "MOLDURA MARCO MODER 11X4X244 CM",
|
|
95
|
-
timestamp: "2023-04-19T21:36:02.000Z",
|
|
96
|
-
upc: "100030"
|
|
97
|
-
}), (0, _defineProperty2.default)(_productSelected, "retailers", [{
|
|
98
|
-
id: 58,
|
|
99
|
-
name: "The Home Depot Golden"
|
|
100
|
-
}, {
|
|
101
|
-
id: 68,
|
|
102
|
-
name: "The Home Depot Merchants"
|
|
103
|
-
}]), (0, _defineProperty2.default)(_productSelected, "statusByRetailer", {
|
|
104
|
-
58: {
|
|
105
|
-
datasheet: "SAC",
|
|
106
|
-
description: "SAC",
|
|
107
|
-
images: "SAC"
|
|
108
|
-
}
|
|
109
|
-
}), _productSelected),
|
|
88
|
+
retailers: [{
|
|
89
|
+
id: 58,
|
|
90
|
+
name: "The Home Depot Golden"
|
|
91
|
+
}, {
|
|
92
|
+
id: 68,
|
|
93
|
+
name: "The Home Depot Merchants"
|
|
94
|
+
}]
|
|
95
|
+
},
|
|
110
96
|
location: {
|
|
111
97
|
product: {
|
|
112
98
|
articleId: 39290,
|
|
@@ -709,7 +709,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
|
|
|
709
709
|
break;
|
|
710
710
|
|
|
711
711
|
case 12:
|
|
712
|
-
arr = ["
|
|
712
|
+
arr = ["AS", "CA", "RC", "RA", "RP", "RCA"];
|
|
713
713
|
return _context6.abrupt("break", 20);
|
|
714
714
|
|
|
715
715
|
case 14:
|
|
@@ -1790,8 +1790,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
|
|
|
1790
1790
|
|
|
1791
1791
|
var validateAll = /*#__PURE__*/function () {
|
|
1792
1792
|
var _ref18 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee15(result) {
|
|
1793
|
-
var
|
|
1794
|
-
|
|
1793
|
+
var evaluationArray, sendAll, conceptArray, productTemp;
|
|
1795
1794
|
return _regenerator.default.wrap(function _callee15$(_context15) {
|
|
1796
1795
|
while (1) {
|
|
1797
1796
|
switch (_context15.prev = _context15.next) {
|
|
@@ -1818,46 +1817,46 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
|
|
|
1818
1817
|
return _context15.abrupt("break", 14);
|
|
1819
1818
|
|
|
1820
1819
|
case 14:
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
// }
|
|
1840
|
-
// });
|
|
1841
|
-
// await Promise.all(evaluationArray);
|
|
1842
|
-
(_conceptArray = conceptArray) === null || _conceptArray === void 0 ? void 0 : _conceptArray.forEach(function (concept) {
|
|
1843
|
-
var _product$id_order;
|
|
1844
|
-
|
|
1845
|
-
var data = {
|
|
1846
|
-
articleId: product.article.id_article,
|
|
1847
|
-
orderId: (_product$id_order = product.id_order) !== null && _product$id_order !== void 0 ? _product$id_order : product.orderId,
|
|
1848
|
-
concept: concept,
|
|
1849
|
-
evalStatus: product["".concat(concept, "_status")]
|
|
1850
|
-
};
|
|
1851
|
-
sendAll.push(_axios.default.put("".concat(process.env.REACT_APP_SEND_EVAL), data, {
|
|
1852
|
-
headers: {
|
|
1853
|
-
Authorization: token
|
|
1854
|
-
}
|
|
1855
|
-
}));
|
|
1820
|
+
servicesData === null || servicesData === void 0 ? void 0 : servicesData.forEach(function (ret) {
|
|
1821
|
+
if (conceptArray.includes(ret.service)) {
|
|
1822
|
+
var _product$id_order;
|
|
1823
|
+
|
|
1824
|
+
var data = {
|
|
1825
|
+
articleId: product.article.id_article,
|
|
1826
|
+
orderId: (_product$id_order = product.id_order) !== null && _product$id_order !== void 0 ? _product$id_order : product.orderId,
|
|
1827
|
+
concept: ret.service,
|
|
1828
|
+
result: result,
|
|
1829
|
+
evalStatus: ret.status,
|
|
1830
|
+
retailerId: ret.id_retailer
|
|
1831
|
+
};
|
|
1832
|
+
evaluationArray.push(_axios.default.put("".concat(process.env.REACT_APP_EVALUATION_ENDPOINT), data, {
|
|
1833
|
+
headers: {
|
|
1834
|
+
Authorization: token
|
|
1835
|
+
}
|
|
1836
|
+
}));
|
|
1837
|
+
}
|
|
1856
1838
|
});
|
|
1857
1839
|
_context15.next = 17;
|
|
1858
|
-
return Promise.all(
|
|
1840
|
+
return Promise.all(evaluationArray);
|
|
1859
1841
|
|
|
1860
1842
|
case 17:
|
|
1843
|
+
//We comment this part of the code because it does not match with the correct flow
|
|
1844
|
+
// conceptArray?.forEach((concept) => {
|
|
1845
|
+
// let data = {
|
|
1846
|
+
// articleId: product.article.id_article,
|
|
1847
|
+
// orderId: product.id_order ?? product.orderId,
|
|
1848
|
+
// concept,
|
|
1849
|
+
// evalStatus: product[`${concept}_status`],
|
|
1850
|
+
// };
|
|
1851
|
+
// sendAll.push(
|
|
1852
|
+
// axios.put(`${process.env.REACT_APP_SEND_EVAL}`, data, {
|
|
1853
|
+
// headers: {
|
|
1854
|
+
// Authorization: token,
|
|
1855
|
+
// },
|
|
1856
|
+
// })
|
|
1857
|
+
// );
|
|
1858
|
+
// });
|
|
1859
|
+
// await Promise.all(sendAll);
|
|
1861
1860
|
productTemp = product;
|
|
1862
1861
|
productTemp.status = "".concat(result, "A");
|
|
1863
1862
|
productTemp.datasheet_status = productTemp.datasheet_status === "NA" ? "NA" : "".concat(result, "A");
|
package/package.json
CHANGED
|
@@ -9,59 +9,68 @@ const Template = (args) => <Dashboard {...args} />;
|
|
|
9
9
|
export const DashboardDeafult = Template.bind({});
|
|
10
10
|
DashboardDeafult.args = {
|
|
11
11
|
user: {
|
|
12
|
-
id_user:
|
|
13
|
-
name: "
|
|
14
|
-
last_name: "
|
|
15
|
-
email: "
|
|
16
|
-
position: "
|
|
17
|
-
telephone: "",
|
|
12
|
+
id_user: 133,
|
|
13
|
+
name: "Financiado Bodega",
|
|
14
|
+
last_name: "Aurrera",
|
|
15
|
+
email: "financiadobodega@allfreemail.net",
|
|
16
|
+
position: "TI",
|
|
17
|
+
telephone: "+527777777777",
|
|
18
18
|
country: "México",
|
|
19
|
-
id_company:
|
|
20
|
-
id_cognito: "
|
|
19
|
+
id_company: 912,
|
|
20
|
+
id_cognito: "25481a4f-e8c7-4104-b772-64fdb291a640",
|
|
21
21
|
birth_Date: null,
|
|
22
|
-
about_me:
|
|
23
|
-
zip_code:
|
|
24
|
-
address:
|
|
25
|
-
job:
|
|
26
|
-
id_stripe:
|
|
27
|
-
id_role:
|
|
22
|
+
about_me: null,
|
|
23
|
+
zip_code: null,
|
|
24
|
+
address: null,
|
|
25
|
+
job: null,
|
|
26
|
+
id_stripe: null,
|
|
27
|
+
id_role: 0,
|
|
28
28
|
active: 1,
|
|
29
29
|
is_retailer: 0,
|
|
30
30
|
email_notify: 1,
|
|
31
31
|
is_user_tech: null,
|
|
32
32
|
membership: {
|
|
33
|
-
id:
|
|
34
|
-
start_date: "
|
|
35
|
-
end_date: "
|
|
36
|
-
planID:
|
|
37
|
-
plan: "
|
|
38
|
-
name: "Plan
|
|
39
|
-
user_limit: "
|
|
40
|
-
products_limit: "
|
|
41
|
-
type: "
|
|
33
|
+
id: 101,
|
|
34
|
+
start_date: "2022-12-22T19:16:53.000Z",
|
|
35
|
+
end_date: "2023-12-22T19:16:53.000Z",
|
|
36
|
+
planID: 8,
|
|
37
|
+
plan: "prod_KtlhECVSFG2iro",
|
|
38
|
+
name: "Plan Pro",
|
|
39
|
+
user_limit: "20",
|
|
40
|
+
products_limit: "5000",
|
|
41
|
+
type: "Enterprise",
|
|
42
42
|
},
|
|
43
|
-
src: "https://content-management-profile.s3.amazonaws.com/id-
|
|
43
|
+
src: "https://content-management-profile.s3.amazonaws.com/id-133/133.png?1684388625309",
|
|
44
44
|
},
|
|
45
45
|
company: {
|
|
46
|
-
id_company:
|
|
47
|
-
trade_name: "
|
|
48
|
-
company_name: "
|
|
49
|
-
rfc: "
|
|
50
|
-
adress: "
|
|
51
|
-
about_company:
|
|
52
|
-
telephone:
|
|
53
|
-
web_site:
|
|
54
|
-
zip_code:
|
|
46
|
+
id_company: 912,
|
|
47
|
+
trade_name: "Financiado Bodega",
|
|
48
|
+
company_name: "Bodega",
|
|
49
|
+
rfc: "9395jwhs",
|
|
50
|
+
adress: "Toluca",
|
|
51
|
+
about_company: null,
|
|
52
|
+
telephone: null,
|
|
53
|
+
web_site: null,
|
|
54
|
+
zip_code: null,
|
|
55
55
|
email: null,
|
|
56
|
-
social_link:
|
|
56
|
+
social_link: null,
|
|
57
57
|
is_retailer: 0,
|
|
58
|
+
financedRetailers: [
|
|
59
|
+
{
|
|
60
|
+
id: 70,
|
|
61
|
+
name: "Bodega Aurrera",
|
|
62
|
+
country: "México",
|
|
63
|
+
id_region: 1,
|
|
64
|
+
active: 1,
|
|
65
|
+
},
|
|
66
|
+
],
|
|
58
67
|
retailers: [
|
|
59
68
|
{
|
|
60
|
-
id:
|
|
61
|
-
name:
|
|
62
|
-
country:
|
|
69
|
+
id: 70,
|
|
70
|
+
name: "Bodega Aurrera",
|
|
71
|
+
country: "México",
|
|
63
72
|
},
|
|
64
73
|
],
|
|
65
74
|
},
|
|
66
|
-
jwt: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.
|
|
75
|
+
jwt: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIyNTQ4MWE0Zi1lOGM3LTQxMDQtYjc3Mi02NGZkYjI5MWE2NDAiLCJjb2duaXRvOmdyb3VwcyI6WyJ1c3VhcmlvX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwicGhvbmVfbnVtYmVyX3ZlcmlmaWVkIjpmYWxzZSwiY29nbml0bzp1c2VybmFtZSI6IjI1NDgxYTRmLWU4YzctNDEwNC1iNzcyLTY0ZmRiMjkxYTY0MCIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiJlNmQwYTZiNS0wZjMzLTQ4NGItYWM1YS0wNmQ0ZTlkZTY4Y2YiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY4NDM4ODYyNCwibmFtZSI6IkZpbmFuY2lhZG8gQm9kZWdhIEF1cnJlcmEiLCJwaG9uZV9udW1iZXIiOiIrNTI3Nzc3Nzc3Nzc3IiwiZXhwIjoxNjg0MzkyMjI0LCJpYXQiOjE2ODQzODg2MjQsImVtYWlsIjoiZmluYW5jaWFkb2JvZGVnYUBhbGxmcmVlbWFpbC5uZXQifQ.kYOldsvuUQofyxyDtxzVHBKVSbnPp5MK0VHrPsMCOf6Xe5rbo834kJGIVVO4ztguTHkHakKE0o3IQimLH5E8IAk8lX8olm9vTcxwpnlxOOVjePGrMAx2rwJS6Oi_45qE18whJdD_tXxceoZsU4hdDc_zQp64DUac3SfIPjs2ClyGCr66nO1VNXKYSTVGVQgV3Tcx65ah3m04GEsnpwAckUxmfKIws9FGsWl_CalkYG3HMR84psAIEA3kSYpiSF_biOySrXpX6H1HZjLRRR_6-P0AxNVZ6kmVTYbSO4vgmbEsO_feoDwtIxPWc3O7htOcevCAM8KyjmmQwlI52y4caQ",
|
|
67
76
|
};
|
|
@@ -39,7 +39,6 @@ export const Dashboard = ({ jwt, user, company }) => {
|
|
|
39
39
|
];
|
|
40
40
|
const [applicantsFilter, setApplicantsFilter] = useState([]);
|
|
41
41
|
const [totalCount, setTotalCount] = useState(0);
|
|
42
|
-
const [isProviderFinanced] = useState(company?.financedRetailers?.length > 0);
|
|
43
42
|
|
|
44
43
|
const loadProductVersions = async (queryObject) => {
|
|
45
44
|
const keys = Object.keys(queryObject);
|
|
@@ -71,7 +70,7 @@ export const Dashboard = ({ jwt, user, company }) => {
|
|
|
71
70
|
);
|
|
72
71
|
const parsed = JSON.parse(retailersResponse.data.body).data;
|
|
73
72
|
let retailers = Object.values(parsed);
|
|
74
|
-
if (isRetailer
|
|
73
|
+
if (isRetailer) {
|
|
75
74
|
const retailersValid = company.retailers.map((e) => e.id);
|
|
76
75
|
retailers = retailers.filter((value) =>
|
|
77
76
|
retailersValid.includes(value.id)
|
|
@@ -253,7 +252,7 @@ export const Dashboard = ({ jwt, user, company }) => {
|
|
|
253
252
|
setParameterArray={setDatesRange}
|
|
254
253
|
isSingleSelect
|
|
255
254
|
/>
|
|
256
|
-
{
|
|
255
|
+
{company.financedRetailers[0].id !== 70 && providers?.length > 0 && (
|
|
257
256
|
<CustomSelect
|
|
258
257
|
showFilterString={true}
|
|
259
258
|
showSearchBar={true}
|
|
@@ -277,7 +276,7 @@ export const Dashboard = ({ jwt, user, company }) => {
|
|
|
277
276
|
setParameterArray={setCategoryId}
|
|
278
277
|
defaultOption="Todas las categorías"
|
|
279
278
|
/>
|
|
280
|
-
{
|
|
279
|
+
{company.financedRetailers[0].id !== 70 && retailers?.length > 1 && (
|
|
281
280
|
<CustomSelect
|
|
282
281
|
showFilterString={true}
|
|
283
282
|
showSearchBar={true}
|
|
@@ -18,52 +18,38 @@ RetailerProductEditionDefault.args = {
|
|
|
18
18
|
token:
|
|
19
19
|
"eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJhNmM0ZDNkNi0yNGE0LTQxZDQtYWQwZi1kMDg3NDM4YWI1YjYiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6ImE2YzRkM2Q2LTI0YTQtNDFkNC1hZDBmLWQwODc0MzhhYjViNiIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiIyYjU3MjZlMy04MjM2LTRmYzMtODBkMi05NWVmYmU4ODdjOTYiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY4MjAxNjI5MSwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY4MjAxOTg5MSwiaWF0IjoxNjgyMDE2MjkxLCJlbWFpbCI6ImV0Y0Bjb250ZW50b2guY29tIn0.SCj_yp1NkGCED59JHoDSdFAOakIOvZVeC0yLwt9z0BtenDXlU0m5cUofQQonnWPM8Q70yMFEkyMGI9kQs_fz1gxrmrSc2FGefn3B_1Vymq3pQ_S1JrY_syYf88m_GtJKOywEnE6--Ef9lZhFBFKGtqRJ4H8JBa9Xb96uCjAKyEMCSURDlw37pk2RQdULlZPj17Zb6Xrqi2lwrhpI1ByptX3__UoTiZklnTXwIxM4JdU7yuhXLznaEH8NOSd2Jw-CV6FCUbYBHlnRYBQg7B5mwyVKtDQm6QpRgBTBPCvljJJpFjRKUcnon8WZiFXx1qVbkWPt2vCT1TZqqoSLdlP6lA",
|
|
20
20
|
productSelected: {
|
|
21
|
-
orderId: 15160,
|
|
22
|
-
status: "SAC",
|
|
23
|
-
datasheet_status: "SAC",
|
|
24
|
-
prio: "none",
|
|
25
|
-
version: 7,
|
|
26
|
-
description_status: "SAC",
|
|
27
|
-
images_status: "SAC",
|
|
28
|
-
brand: null,
|
|
29
|
-
retailerOrder: 1,
|
|
30
|
-
missing: {
|
|
31
|
-
datasheet: null,
|
|
32
|
-
descriptions: null,
|
|
33
|
-
images: null,
|
|
34
|
-
},
|
|
35
21
|
orderId: 14606,
|
|
36
|
-
status: "
|
|
37
|
-
datasheet_status: "
|
|
22
|
+
status: "RA",
|
|
23
|
+
datasheet_status: "RA",
|
|
38
24
|
prio: "none",
|
|
39
25
|
version: 3,
|
|
40
|
-
description_status: "
|
|
41
|
-
images_status: "
|
|
26
|
+
description_status: "RA",
|
|
27
|
+
images_status: "RA",
|
|
42
28
|
statusByRetailer: {
|
|
43
29
|
4: {
|
|
44
|
-
datasheet: "AC",
|
|
45
|
-
description: "AC",
|
|
46
|
-
images: "AC",
|
|
30
|
+
datasheet: "RA/AC",
|
|
31
|
+
description: "RA/AC",
|
|
32
|
+
images: "RA/AC",
|
|
47
33
|
},
|
|
48
34
|
5: {
|
|
49
|
-
datasheet: "AC",
|
|
50
|
-
description: "AC",
|
|
51
|
-
images: "AC",
|
|
35
|
+
datasheet: "RA/AC",
|
|
36
|
+
description: "RA/AC",
|
|
37
|
+
images: "RA/AC",
|
|
52
38
|
},
|
|
53
39
|
6: {
|
|
54
|
-
description: "AC",
|
|
55
|
-
images: "AC",
|
|
56
|
-
datasheet: "AC",
|
|
40
|
+
description: "RA/AC",
|
|
41
|
+
images: "RA/AC",
|
|
42
|
+
datasheet: "RA/AC",
|
|
57
43
|
},
|
|
58
44
|
12: {
|
|
59
|
-
datasheet: "AC",
|
|
60
|
-
description: "AC",
|
|
61
|
-
images: "AC",
|
|
45
|
+
datasheet: "RA/AC",
|
|
46
|
+
description: "RA/AC",
|
|
47
|
+
images: "RA/AC",
|
|
62
48
|
},
|
|
63
49
|
17: {
|
|
64
|
-
datasheet: "AC",
|
|
65
|
-
description: "AC",
|
|
66
|
-
images: "AC",
|
|
50
|
+
datasheet: "RA/AC",
|
|
51
|
+
description: "RA/AC",
|
|
52
|
+
images: "RA/AC",
|
|
67
53
|
},
|
|
68
54
|
},
|
|
69
55
|
article: {
|
|
@@ -94,13 +80,6 @@ RetailerProductEditionDefault.args = {
|
|
|
94
80
|
name: "The Home Depot Merchants",
|
|
95
81
|
},
|
|
96
82
|
],
|
|
97
|
-
statusByRetailer: {
|
|
98
|
-
58: {
|
|
99
|
-
datasheet: "SAC",
|
|
100
|
-
description: "SAC",
|
|
101
|
-
images: "SAC",
|
|
102
|
-
},
|
|
103
|
-
},
|
|
104
83
|
},
|
|
105
84
|
location: {
|
|
106
85
|
product: { articleId: 39290, versionId: 7 },
|
|
@@ -337,7 +337,7 @@ export const RetailerProductEdition = ({
|
|
|
337
337
|
switch (user.id_role) {
|
|
338
338
|
case 7:
|
|
339
339
|
case 8:
|
|
340
|
-
arr = ["
|
|
340
|
+
arr = ["AS", "CA", "RC", "RA", "RP", "RCA"];
|
|
341
341
|
break;
|
|
342
342
|
case 4:
|
|
343
343
|
case 5:
|
|
@@ -1208,46 +1208,46 @@ export const RetailerProductEdition = ({
|
|
|
1208
1208
|
break;
|
|
1209
1209
|
}
|
|
1210
1210
|
|
|
1211
|
+
servicesData?.forEach((ret) => {
|
|
1212
|
+
if (conceptArray.includes(ret.service)) {
|
|
1213
|
+
let data = {
|
|
1214
|
+
articleId: product.article.id_article,
|
|
1215
|
+
orderId: product.id_order ?? product.orderId,
|
|
1216
|
+
concept: ret.service,
|
|
1217
|
+
result: result,
|
|
1218
|
+
evalStatus: ret.status,
|
|
1219
|
+
retailerId: ret.id_retailer,
|
|
1220
|
+
};
|
|
1221
|
+
evaluationArray.push(
|
|
1222
|
+
axios.put(`${process.env.REACT_APP_EVALUATION_ENDPOINT}`, data, {
|
|
1223
|
+
headers: {
|
|
1224
|
+
Authorization: token,
|
|
1225
|
+
},
|
|
1226
|
+
})
|
|
1227
|
+
);
|
|
1228
|
+
}
|
|
1229
|
+
});
|
|
1230
|
+
await Promise.all(evaluationArray);
|
|
1231
|
+
|
|
1211
1232
|
//We comment this part of the code because it does not match with the correct flow
|
|
1212
1233
|
|
|
1213
|
-
//
|
|
1214
|
-
//
|
|
1215
|
-
//
|
|
1216
|
-
//
|
|
1217
|
-
//
|
|
1218
|
-
//
|
|
1219
|
-
//
|
|
1220
|
-
//
|
|
1221
|
-
//
|
|
1222
|
-
//
|
|
1223
|
-
//
|
|
1224
|
-
//
|
|
1225
|
-
//
|
|
1226
|
-
//
|
|
1227
|
-
// },
|
|
1228
|
-
// })
|
|
1229
|
-
// );
|
|
1230
|
-
// }
|
|
1234
|
+
// conceptArray?.forEach((concept) => {
|
|
1235
|
+
// let data = {
|
|
1236
|
+
// articleId: product.article.id_article,
|
|
1237
|
+
// orderId: product.id_order ?? product.orderId,
|
|
1238
|
+
// concept,
|
|
1239
|
+
// evalStatus: product[`${concept}_status`],
|
|
1240
|
+
// };
|
|
1241
|
+
// sendAll.push(
|
|
1242
|
+
// axios.put(`${process.env.REACT_APP_SEND_EVAL}`, data, {
|
|
1243
|
+
// headers: {
|
|
1244
|
+
// Authorization: token,
|
|
1245
|
+
// },
|
|
1246
|
+
// })
|
|
1247
|
+
// );
|
|
1231
1248
|
// });
|
|
1249
|
+
// await Promise.all(sendAll);
|
|
1232
1250
|
|
|
1233
|
-
// await Promise.all(evaluationArray);
|
|
1234
|
-
|
|
1235
|
-
conceptArray?.forEach((concept) => {
|
|
1236
|
-
let data = {
|
|
1237
|
-
articleId: product.article.id_article,
|
|
1238
|
-
orderId: product.id_order ?? product.orderId,
|
|
1239
|
-
concept,
|
|
1240
|
-
evalStatus: product[`${concept}_status`],
|
|
1241
|
-
};
|
|
1242
|
-
sendAll.push(
|
|
1243
|
-
axios.put(`${process.env.REACT_APP_SEND_EVAL}`, data, {
|
|
1244
|
-
headers: {
|
|
1245
|
-
Authorization: token,
|
|
1246
|
-
},
|
|
1247
|
-
})
|
|
1248
|
-
);
|
|
1249
|
-
});
|
|
1250
|
-
await Promise.all(sendAll);
|
|
1251
1251
|
const productTemp = product;
|
|
1252
1252
|
productTemp.status = `${result}A`;
|
|
1253
1253
|
productTemp.datasheet_status =
|
|
@@ -1,202 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
Apache License
|
|
3
|
-
Version 2.0, January 2004
|
|
4
|
-
http://www.apache.org/licenses/
|
|
5
|
-
|
|
6
|
-
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
-
|
|
8
|
-
1. Definitions.
|
|
9
|
-
|
|
10
|
-
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
-
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
-
|
|
13
|
-
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
-
the copyright owner that is granting the License.
|
|
15
|
-
|
|
16
|
-
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
-
other entities that control, are controlled by, or are under common
|
|
18
|
-
control with that entity. For the purposes of this definition,
|
|
19
|
-
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
-
direction or management of such entity, whether by contract or
|
|
21
|
-
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
-
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
-
|
|
24
|
-
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
-
exercising permissions granted by this License.
|
|
26
|
-
|
|
27
|
-
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
-
including but not limited to software source code, documentation
|
|
29
|
-
source, and configuration files.
|
|
30
|
-
|
|
31
|
-
"Object" form shall mean any form resulting from mechanical
|
|
32
|
-
transformation or translation of a Source form, including but
|
|
33
|
-
not limited to compiled object code, generated documentation,
|
|
34
|
-
and conversions to other media types.
|
|
35
|
-
|
|
36
|
-
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
-
Object form, made available under the License, as indicated by a
|
|
38
|
-
copyright notice that is included in or attached to the work
|
|
39
|
-
(an example is provided in the Appendix below).
|
|
40
|
-
|
|
41
|
-
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
-
form, that is based on (or derived from) the Work and for which the
|
|
43
|
-
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
-
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
-
of this License, Derivative Works shall not include works that remain
|
|
46
|
-
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
-
the Work and Derivative Works thereof.
|
|
48
|
-
|
|
49
|
-
"Contribution" shall mean any work of authorship, including
|
|
50
|
-
the original version of the Work and any modifications or additions
|
|
51
|
-
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
-
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
-
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
-
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
-
means any form of electronic, verbal, or written communication sent
|
|
56
|
-
to the Licensor or its representatives, including but not limited to
|
|
57
|
-
communication on electronic mailing lists, source code control systems,
|
|
58
|
-
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
-
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
-
excluding communication that is conspicuously marked or otherwise
|
|
61
|
-
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
-
|
|
63
|
-
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
-
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
-
subsequently incorporated within the Work.
|
|
66
|
-
|
|
67
|
-
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
-
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
-
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
-
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
-
Work and such Derivative Works in Source or Object form.
|
|
73
|
-
|
|
74
|
-
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
-
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
-
(except as stated in this section) patent license to make, have made,
|
|
78
|
-
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
-
where such license applies only to those patent claims licensable
|
|
80
|
-
by such Contributor that are necessarily infringed by their
|
|
81
|
-
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
-
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
-
institute patent litigation against any entity (including a
|
|
84
|
-
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
-
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
-
or contributory patent infringement, then any patent licenses
|
|
87
|
-
granted to You under this License for that Work shall terminate
|
|
88
|
-
as of the date such litigation is filed.
|
|
89
|
-
|
|
90
|
-
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
-
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
-
modifications, and in Source or Object form, provided that You
|
|
93
|
-
meet the following conditions:
|
|
94
|
-
|
|
95
|
-
(a) You must give any other recipients of the Work or
|
|
96
|
-
Derivative Works a copy of this License; and
|
|
97
|
-
|
|
98
|
-
(b) You must cause any modified files to carry prominent notices
|
|
99
|
-
stating that You changed the files; and
|
|
100
|
-
|
|
101
|
-
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
-
that You distribute, all copyright, patent, trademark, and
|
|
103
|
-
attribution notices from the Source form of the Work,
|
|
104
|
-
excluding those notices that do not pertain to any part of
|
|
105
|
-
the Derivative Works; and
|
|
106
|
-
|
|
107
|
-
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
-
distribution, then any Derivative Works that You distribute must
|
|
109
|
-
include a readable copy of the attribution notices contained
|
|
110
|
-
within such NOTICE file, excluding those notices that do not
|
|
111
|
-
pertain to any part of the Derivative Works, in at least one
|
|
112
|
-
of the following places: within a NOTICE text file distributed
|
|
113
|
-
as part of the Derivative Works; within the Source form or
|
|
114
|
-
documentation, if provided along with the Derivative Works; or,
|
|
115
|
-
within a display generated by the Derivative Works, if and
|
|
116
|
-
wherever such third-party notices normally appear. The contents
|
|
117
|
-
of the NOTICE file are for informational purposes only and
|
|
118
|
-
do not modify the License. You may add Your own attribution
|
|
119
|
-
notices within Derivative Works that You distribute, alongside
|
|
120
|
-
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
-
that such additional attribution notices cannot be construed
|
|
122
|
-
as modifying the License.
|
|
123
|
-
|
|
124
|
-
You may add Your own copyright statement to Your modifications and
|
|
125
|
-
may provide additional or different license terms and conditions
|
|
126
|
-
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
-
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
-
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
-
the conditions stated in this License.
|
|
130
|
-
|
|
131
|
-
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
-
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
-
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
-
this License, without any additional terms or conditions.
|
|
135
|
-
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
-
the terms of any separate license agreement you may have executed
|
|
137
|
-
with Licensor regarding such Contributions.
|
|
138
|
-
|
|
139
|
-
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
-
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
-
except as required for reasonable and customary use in describing the
|
|
142
|
-
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
-
|
|
144
|
-
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
-
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
-
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
-
implied, including, without limitation, any warranties or conditions
|
|
149
|
-
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
-
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
-
appropriateness of using or redistributing the Work and assume any
|
|
152
|
-
risks associated with Your exercise of permissions under this License.
|
|
153
|
-
|
|
154
|
-
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
-
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
-
unless required by applicable law (such as deliberate and grossly
|
|
157
|
-
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
-
liable to You for damages, including any direct, indirect, special,
|
|
159
|
-
incidental, or consequential damages of any character arising as a
|
|
160
|
-
result of this License or out of the use or inability to use the
|
|
161
|
-
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
-
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
-
other commercial damages or losses), even if such Contributor
|
|
164
|
-
has been advised of the possibility of such damages.
|
|
165
|
-
|
|
166
|
-
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
-
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
-
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
-
or other liability obligations and/or rights consistent with this
|
|
170
|
-
License. However, in accepting such obligations, You may act only
|
|
171
|
-
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
-
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
-
defend, and hold each Contributor harmless for any liability
|
|
174
|
-
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
-
of your accepting any such warranty or additional liability.
|
|
176
|
-
|
|
177
|
-
END OF TERMS AND CONDITIONS
|
|
178
|
-
|
|
179
|
-
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
-
|
|
181
|
-
To apply the Apache License to your work, attach the following
|
|
182
|
-
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
-
replaced with your own identifying information. (Don't include
|
|
184
|
-
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
-
comment syntax for the file format. We also recommend that a
|
|
186
|
-
file or class name and description of purpose be included on the
|
|
187
|
-
same "printed page" as the copyright notice for easier
|
|
188
|
-
identification within third-party archives.
|
|
189
|
-
|
|
190
|
-
Copyright [yyyy] [name of copyright owner]
|
|
191
|
-
|
|
192
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
-
you may not use this file except in compliance with the License.
|
|
194
|
-
You may obtain a copy of the License at
|
|
195
|
-
|
|
196
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
-
|
|
198
|
-
Unless required by applicable law or agreed to in writing, software
|
|
199
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
-
See the License for the specific language governing permissions and
|
|
202
|
-
limitations under the License.
|