@itilite/iui-user-management 0.0.7 → 0.0.9
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/index.css +5 -1
- package/dist/index.js +97 -71
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +98 -72
- package/dist/index.modern.js.map +1 -1
- package/package.json +3 -19
package/dist/index.css
CHANGED
|
@@ -363,7 +363,7 @@
|
|
|
363
363
|
}
|
|
364
364
|
|
|
365
365
|
._2Iuy1 {
|
|
366
|
-
|
|
366
|
+
padding-left: 10px;
|
|
367
367
|
}
|
|
368
368
|
._2Iuy1:hover {
|
|
369
369
|
background-color: rgba(229, 228, 228, 0.231372549) !important;
|
|
@@ -374,6 +374,10 @@
|
|
|
374
374
|
border-radius: 20px;
|
|
375
375
|
color: white;
|
|
376
376
|
}
|
|
377
|
+
|
|
378
|
+
._3Kbfm {
|
|
379
|
+
padding: 0px;
|
|
380
|
+
}
|
|
377
381
|
._2LqsB {
|
|
378
382
|
background-color: #ffffff;
|
|
379
383
|
}
|
package/dist/index.js
CHANGED
|
@@ -15,7 +15,6 @@ var reduxDevtoolsExtension = require('redux-devtools-extension');
|
|
|
15
15
|
var reactRouterDom = require('react-router-dom');
|
|
16
16
|
var styles$8 = require('@material-ui/core/styles');
|
|
17
17
|
var Switch = _interopDefault(require('@material-ui/core/Switch'));
|
|
18
|
-
var core = require('@material-ui/core');
|
|
19
18
|
|
|
20
19
|
function _extends() {
|
|
21
20
|
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
@@ -4428,7 +4427,7 @@ var AdditionalInfo = function AdditionalInfo(_ref) {
|
|
|
4428
4427
|
}))))));
|
|
4429
4428
|
};
|
|
4430
4429
|
|
|
4431
|
-
var styles$3 = {"root":"_b_muK","minWidth":"_3OQXs","bullet":"_1Q5vL","pos":"_6wGWA","cardHeader":"_SWCfJ","pageHeader":"_2ZeWp","buttonHover":"_2Iuy1","cardHeaderBackground":"_3NJWF"};
|
|
4430
|
+
var styles$3 = {"root":"_b_muK","minWidth":"_3OQXs","bullet":"_1Q5vL","pos":"_6wGWA","cardHeader":"_SWCfJ","pageHeader":"_2ZeWp","buttonHover":"_2Iuy1","cardHeaderBackground":"_3NJWF","actionCustom":"_3Kbfm"};
|
|
4432
4431
|
|
|
4433
4432
|
var VerificationError = function VerificationError(_ref) {
|
|
4434
4433
|
var config = _ref.config,
|
|
@@ -4451,8 +4450,8 @@ var VerificationError = function VerificationError(_ref) {
|
|
|
4451
4450
|
description: errMsg,
|
|
4452
4451
|
actionComponent: /*#__PURE__*/React__default.createElement(iuistyles.IUIButton, {
|
|
4453
4452
|
className: styles$3.buttonHover,
|
|
4454
|
-
buttonText: "
|
|
4455
|
-
|
|
4453
|
+
buttonText: "BACK TO HOMEPAGE",
|
|
4454
|
+
type: "outlined",
|
|
4456
4455
|
onClick: function onClick() {
|
|
4457
4456
|
return history.push(config.routes.fallbackUrl);
|
|
4458
4457
|
}
|
|
@@ -6830,8 +6829,8 @@ var UserBulkUpload = function UserBulkUpload(_ref) {
|
|
|
6830
6829
|
};
|
|
6831
6830
|
|
|
6832
6831
|
var CustomStepIcon = function CustomStepIcon(step) {
|
|
6833
|
-
if ((importStatus === 1 || importStatus === 2 || importStatus === 4) && step
|
|
6834
|
-
return /*#__PURE__*/React__default.createElement(iuistyles.
|
|
6832
|
+
if ((importStatus === 1 || importStatus === 2 || importStatus === 4) && step === Number(activeStep)) {
|
|
6833
|
+
return /*#__PURE__*/React__default.createElement(iuistyles.IUIPrimaryRadio, {
|
|
6835
6834
|
checked: true,
|
|
6836
6835
|
className: clsx(styles$4.customRadioEach),
|
|
6837
6836
|
size: "small",
|
|
@@ -6839,16 +6838,16 @@ var UserBulkUpload = function UserBulkUpload(_ref) {
|
|
|
6839
6838
|
});
|
|
6840
6839
|
}
|
|
6841
6840
|
|
|
6842
|
-
if ((importStatus === 1 || importStatus === 2 || importStatus === 4) && step
|
|
6843
|
-
return /*#__PURE__*/React__default.createElement(iuistyles.
|
|
6841
|
+
if ((importStatus === 1 || importStatus === 2 || importStatus === 4) && step !== Number(activeStep)) {
|
|
6842
|
+
return /*#__PURE__*/React__default.createElement(iuistyles.IUIPrimaryRadio, {
|
|
6844
6843
|
className: clsx(styles$4.customRadioEach),
|
|
6845
6844
|
size: "small",
|
|
6846
6845
|
disabled: true
|
|
6847
6846
|
});
|
|
6848
6847
|
}
|
|
6849
6848
|
|
|
6850
|
-
if (importStatus === 3 && step
|
|
6851
|
-
return /*#__PURE__*/React__default.createElement(iuistyles.
|
|
6849
|
+
if (importStatus === 3 && step === Number(activeStep)) {
|
|
6850
|
+
return /*#__PURE__*/React__default.createElement(iuistyles.IUIPrimaryRadio, {
|
|
6852
6851
|
checked: true,
|
|
6853
6852
|
className: clsx(styles$4.customRadioEach),
|
|
6854
6853
|
size: "small",
|
|
@@ -6856,7 +6855,7 @@ var UserBulkUpload = function UserBulkUpload(_ref) {
|
|
|
6856
6855
|
});
|
|
6857
6856
|
}
|
|
6858
6857
|
|
|
6859
|
-
if (importStatus === 3 && step
|
|
6858
|
+
if (importStatus === 3 && step !== Number(activeStep)) {
|
|
6860
6859
|
return /*#__PURE__*/React__default.createElement(CheckCircleIcon, {
|
|
6861
6860
|
width: "20",
|
|
6862
6861
|
height: "20",
|
|
@@ -6961,7 +6960,7 @@ var UserBulkUpload = function UserBulkUpload(_ref) {
|
|
|
6961
6960
|
activeStep: activeStep,
|
|
6962
6961
|
nonLinear: true,
|
|
6963
6962
|
className: styles$4.stepper,
|
|
6964
|
-
|
|
6963
|
+
CustomStepIcon: CustomStepIcon,
|
|
6965
6964
|
steps: steps
|
|
6966
6965
|
}), importStatus === 1 && /*#__PURE__*/React__default.createElement(iuistyles.IUIBox, {
|
|
6967
6966
|
display: "flex",
|
|
@@ -7141,7 +7140,7 @@ var UserBulkUpload = function UserBulkUpload(_ref) {
|
|
|
7141
7140
|
}, /*#__PURE__*/React__default.createElement(iuistyles.IUIFormControlLabel, {
|
|
7142
7141
|
control: /*#__PURE__*/React__default.createElement(iuistyles.IUICheckBox, {
|
|
7143
7142
|
handleCheckBoxHandler: handleExistingUserUpdation,
|
|
7144
|
-
|
|
7143
|
+
checked: canUpdateExistingUsers
|
|
7145
7144
|
}),
|
|
7146
7145
|
label: "Update any existing users",
|
|
7147
7146
|
className: clsx(styles$4.checkboxlabel, (_clsx5 = {}, _clsx5[styles$4.disabledText] = +userBulkImportInfo.exist_users === 0, _clsx5)),
|
|
@@ -7479,31 +7478,35 @@ var BulkActionHistoryTable = function BulkActionHistoryTable(props) {
|
|
|
7479
7478
|
|
|
7480
7479
|
var styles$6 = {"UUICustomFields":"_tdVCY","pageHeader":"_8iQvL","buttonWrapper":"_2k_GJ","headingWrapper":"_1rYVz","heading":"_2nxXO","headingLarge":"_2auvl","headingMedium":"_Wjaw1","headingSmall":"_1UmTe","description":"_2BS2i","headerText":"_3SZ_X","letterImage":"_2AwAF","tablewrapper":"_3qSxj","rowText":"_2ZSw6","textTransform":"_1F6ss","lightColor":"_2Wjom","importModalBodyContainer":"_2JCWP","dividerColor":"_3EsJG","downloadTemplateContainer":"_2uRic","downloadTemplateDescContainer":"_55kg5","labelContainer":"_78mCn","downlTempHeader":"_lqUA2","downlTempDescription":"_1vT5l","colGap":"_1x_9W","tableHead":"_5SygC","actionButtons":"_3PeqN","emptyData":"_1bHs-"};
|
|
7481
7480
|
|
|
7482
|
-
function SkeletonLoader() {
|
|
7483
|
-
|
|
7484
|
-
|
|
7481
|
+
function SkeletonLoader(_ref) {
|
|
7482
|
+
var _ref$data = _ref.data,
|
|
7483
|
+
data = _ref$data === void 0 ? [{
|
|
7484
|
+
variant: 'rect',
|
|
7485
|
+
height: 100,
|
|
7485
7486
|
style: {
|
|
7486
|
-
|
|
7487
|
+
top: 20,
|
|
7488
|
+
bottom: 20
|
|
7487
7489
|
}
|
|
7488
|
-
},
|
|
7489
|
-
variant:
|
|
7490
|
-
height: 120,
|
|
7491
|
-
style: {
|
|
7492
|
-
marginTop: 40,
|
|
7493
|
-
marginBottom: 20
|
|
7494
|
-
}
|
|
7495
|
-
}), /*#__PURE__*/React__default.createElement(iuistyles.IUISkeleton, {
|
|
7496
|
-
variant: "rect",
|
|
7490
|
+
}, {
|
|
7491
|
+
variant: 'rect',
|
|
7497
7492
|
height: 50,
|
|
7498
7493
|
style: {
|
|
7499
|
-
|
|
7494
|
+
bottom: 20
|
|
7500
7495
|
}
|
|
7501
|
-
}
|
|
7502
|
-
variant:
|
|
7496
|
+
}, {
|
|
7497
|
+
variant: 'rect',
|
|
7503
7498
|
height: 500,
|
|
7504
7499
|
style: {
|
|
7505
|
-
|
|
7500
|
+
bottom: 20
|
|
7506
7501
|
}
|
|
7502
|
+
}] : _ref$data;
|
|
7503
|
+
return /*#__PURE__*/React__default.createElement(iuistyles.IUIBox, {
|
|
7504
|
+
className: styles$6.tablewrapper,
|
|
7505
|
+
style: {
|
|
7506
|
+
margin: 20
|
|
7507
|
+
}
|
|
7508
|
+
}, /*#__PURE__*/React__default.createElement(iuistyles.IUISkeleton, {
|
|
7509
|
+
data: data
|
|
7507
7510
|
}));
|
|
7508
7511
|
}
|
|
7509
7512
|
|
|
@@ -9277,7 +9280,7 @@ var PageHeader = function PageHeader() {
|
|
|
9277
9280
|
}));
|
|
9278
9281
|
};
|
|
9279
9282
|
|
|
9280
|
-
function
|
|
9283
|
+
function Table() {
|
|
9281
9284
|
var _useSelector = reactRedux.useSelector(function (state) {
|
|
9282
9285
|
return state.customFields;
|
|
9283
9286
|
}),
|
|
@@ -9290,41 +9293,51 @@ function CustomFieldsTable() {
|
|
|
9290
9293
|
dispatch(toggleModal(true));
|
|
9291
9294
|
};
|
|
9292
9295
|
|
|
9296
|
+
var columns = [{
|
|
9297
|
+
id: 'sno',
|
|
9298
|
+
label: '#',
|
|
9299
|
+
sortable: false,
|
|
9300
|
+
cell: function cell(row, i) {
|
|
9301
|
+
return /*#__PURE__*/React__default.createElement(iuistyles.IUIBox, {
|
|
9302
|
+
component: "div"
|
|
9303
|
+
}, /*#__PURE__*/React__default.createElement(iuistyles.IUITypography, null, i + 1));
|
|
9304
|
+
}
|
|
9305
|
+
}, {
|
|
9306
|
+
id: 'name',
|
|
9307
|
+
label: 'Name',
|
|
9308
|
+
sortable: false,
|
|
9309
|
+
cell: function cell(row) {
|
|
9310
|
+
return /*#__PURE__*/React__default.createElement(iuistyles.IUIBox, {
|
|
9311
|
+
component: "div"
|
|
9312
|
+
}, /*#__PURE__*/React__default.createElement(iuistyles.IUITypography, null, row.field_name));
|
|
9313
|
+
}
|
|
9314
|
+
}, {
|
|
9315
|
+
id: 'actions',
|
|
9316
|
+
label: 'Actions',
|
|
9317
|
+
align: 'left',
|
|
9318
|
+
cell: function cell(row) {
|
|
9319
|
+
return /*#__PURE__*/React__default.createElement(iuistyles.IUIButton, {
|
|
9320
|
+
buttonText: "Edit",
|
|
9321
|
+
onClick: function onClick() {
|
|
9322
|
+
return handleEdit(row);
|
|
9323
|
+
}
|
|
9324
|
+
});
|
|
9325
|
+
},
|
|
9326
|
+
style: {
|
|
9327
|
+
paddingLeft: '40px'
|
|
9328
|
+
}
|
|
9329
|
+
}];
|
|
9293
9330
|
return /*#__PURE__*/React__default.createElement(iuistyles.IUIBox, {
|
|
9294
9331
|
className: styles$6.tablewrapper
|
|
9295
|
-
}, /*#__PURE__*/React__default.createElement(
|
|
9296
|
-
|
|
9297
|
-
|
|
9298
|
-
|
|
9299
|
-
|
|
9300
|
-
|
|
9301
|
-
|
|
9302
|
-
|
|
9303
|
-
|
|
9304
|
-
width: "40%"
|
|
9305
|
-
}, "#"), /*#__PURE__*/React__default.createElement(core.TableCell, {
|
|
9306
|
-
width: "40%"
|
|
9307
|
-
}, "Name"), /*#__PURE__*/React__default.createElement(core.TableCell, {
|
|
9308
|
-
width: "20%",
|
|
9309
|
-
style: {
|
|
9310
|
-
paddingLeft: '3%'
|
|
9311
|
-
}
|
|
9312
|
-
}, "Action"))), /*#__PURE__*/React__default.createElement(core.TableBody, null, data.length === 0 ? /*#__PURE__*/React__default.createElement(core.TableRow, null, /*#__PURE__*/React__default.createElement(core.TableCell, null), /*#__PURE__*/React__default.createElement(core.TableCell, null, /*#__PURE__*/React__default.createElement(iuistyles.IUIBox, {
|
|
9313
|
-
className: styles$6.emptyData
|
|
9314
|
-
}, "No data available")), /*#__PURE__*/React__default.createElement(core.TableCell, null)) : data.map(function (row, i) {
|
|
9315
|
-
return /*#__PURE__*/React__default.createElement(core.TableRow, {
|
|
9316
|
-
key: row.id.toString()
|
|
9317
|
-
}, /*#__PURE__*/React__default.createElement(core.TableCell, {
|
|
9318
|
-
align: "left"
|
|
9319
|
-
}, i + 1), /*#__PURE__*/React__default.createElement(core.TableCell, null, row.field_name), /*#__PURE__*/React__default.createElement(core.TableCell, {
|
|
9320
|
-
className: styles$6.actionButtons
|
|
9321
|
-
}, /*#__PURE__*/React__default.createElement(iuistyles.IUIButton, {
|
|
9322
|
-
buttonText: "Edit",
|
|
9323
|
-
onClick: function onClick() {
|
|
9324
|
-
return handleEdit(row);
|
|
9325
|
-
}
|
|
9326
|
-
})));
|
|
9327
|
-
})))));
|
|
9332
|
+
}, /*#__PURE__*/React__default.createElement(iuistyles.IUITable, {
|
|
9333
|
+
hasFilter: false,
|
|
9334
|
+
isCheckboxTable: false,
|
|
9335
|
+
columns: columns,
|
|
9336
|
+
rows: data,
|
|
9337
|
+
count: data.length,
|
|
9338
|
+
searchHide: true,
|
|
9339
|
+
hidePagination: true
|
|
9340
|
+
}));
|
|
9328
9341
|
}
|
|
9329
9342
|
|
|
9330
9343
|
var env$9 = utils.configs.env;
|
|
@@ -9340,27 +9353,40 @@ var CustomFields$1 = function CustomFields(_ref) {
|
|
|
9340
9353
|
}),
|
|
9341
9354
|
isTokenVerified = _useSelector.isTokenVerified;
|
|
9342
9355
|
|
|
9343
|
-
var
|
|
9344
|
-
|
|
9345
|
-
|
|
9346
|
-
loading = _useSelector2.loading;
|
|
9356
|
+
var _useState = React.useState(true),
|
|
9357
|
+
loading = _useState[0],
|
|
9358
|
+
setLoading = _useState[1];
|
|
9347
9359
|
|
|
9348
9360
|
React.useEffect(function () {
|
|
9349
|
-
|
|
9361
|
+
setLoading(true);
|
|
9350
9362
|
var roleCanAccess = ['travel_itilite_admin', 'travel_admin', 'expense_itilite_admin', 'expense_admin'];
|
|
9351
9363
|
dispatch(verifyAccessToken(roleCanAccess));
|
|
9352
9364
|
}, []);
|
|
9353
9365
|
React.useEffect(function () {
|
|
9354
9366
|
if (isTokenVerified) {
|
|
9355
9367
|
dispatch(fetchCustomFields())["finally"](function () {
|
|
9356
|
-
|
|
9368
|
+
setLoading(false);
|
|
9357
9369
|
});
|
|
9358
9370
|
}
|
|
9359
9371
|
}, [isTokenVerified]);
|
|
9360
9372
|
return /*#__PURE__*/React__default.createElement(iuistyles.IUIBox, {
|
|
9361
9373
|
component: "div",
|
|
9362
9374
|
className: styles$6.UUICustomFields
|
|
9363
|
-
}, /*#__PURE__*/React__default.createElement(PageHeader, null), loading ? /*#__PURE__*/React__default.createElement(SkeletonLoader,
|
|
9375
|
+
}, /*#__PURE__*/React__default.createElement(PageHeader, null), loading ? /*#__PURE__*/React__default.createElement(SkeletonLoader, {
|
|
9376
|
+
data: [{
|
|
9377
|
+
variant: 'rect',
|
|
9378
|
+
height: 50,
|
|
9379
|
+
style: {
|
|
9380
|
+
bottom: 20
|
|
9381
|
+
}
|
|
9382
|
+
}, {
|
|
9383
|
+
variant: 'rect',
|
|
9384
|
+
height: 500,
|
|
9385
|
+
style: {
|
|
9386
|
+
bottom: 20
|
|
9387
|
+
}
|
|
9388
|
+
}]
|
|
9389
|
+
}) : /*#__PURE__*/React__default.createElement(Table, null));
|
|
9364
9390
|
};
|
|
9365
9391
|
|
|
9366
9392
|
var index$4 = withStore(CustomFields$1);
|