@itilite/iui-user-management 1.4.763 → 1.4.765
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 +12 -0
- package/dist/index.js +19 -9
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +19 -9
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -826,7 +826,7 @@ var UserRole = function UserRole(_ref) {
|
|
|
826
826
|
|
|
827
827
|
var styles$1 = {"defaultLabel":"_smjc4","card":"_3_S9J","cardNumber":"_36E9M","cardDigit":"_2pm-T","expiryDate":"_2tBnF","cardImage":"_3QvZh","visa":"_1IpBm","mastercard":"_2x6IX","amex":"_2a38S","discover":"_2vksl","diners":"_2kQRs","jcb":"_2bO1f","unionpay":"_2_jfu","is_nothing":"_1Lrzs","addCard":"_3711U","cardDeleteBtn":"_7Da2t","cardLabel":"_PQTex","defaultBtn":"_1_ArA","cursonPointer":"_1L115","sectionWrapper":"_VpUCK","margin":"_1Fs_D","minGridWidth":"_1hl-Z","firstRowMargin":"_1WZZj","firstChildMargin":"_IT_O_","paddingTop":"_Mhnl7","dividerColor":"_3ltFd"};
|
|
828
828
|
|
|
829
|
-
var classes = {"sectionHeader":"_2d_OH","myCardsSection":"_3MNHj","companyCardsSection":"_34lN6","cardsGrid":"_1oHGu","card":"_3ZTQc","moreIcon":"_3utA0","personal":"_duePd","corporate":"_3O33a","company":"_180_L","cardHeader":"_1eF61","cardTitleSection":"_2c40W","cardMaskedNumber":"_2Vlhq","cardName":"_bp-Mt","cardType":"_3l4HZ","menuButton":"_3TTEn","lockIcon":"_1S27X","cardDetails":"_IP2rg","cardNumber":"_7FOPe","cardExpiry":"_CI_p2","cardCvv":"_3Gzqu","cardUnhide":"_ivgBf","cardFooter":"_1WgPL","brandLogo":"_EV0l8","addCardButton":"_1oaCc","plusIcon":"_w9L5L"};
|
|
829
|
+
var classes = {"sectionHeader":"_2d_OH","myCardsSection":"_3MNHj","companyCardsSection":"_34lN6","disabledNotice":"_1yV0j","cardsGrid":"_1oHGu","card":"_3ZTQc","moreIcon":"_3utA0","personal":"_duePd","corporate":"_3O33a","company":"_180_L","cardHeader":"_1eF61","cardTitleSection":"_2c40W","cardMaskedNumber":"_2Vlhq","cardName":"_bp-Mt","cardType":"_3l4HZ","menuButton":"_3TTEn","lockIcon":"_1S27X","cardDetails":"_IP2rg","cardNumber":"_7FOPe","cardExpiry":"_CI_p2","cardCvv":"_3Gzqu","cardUnhide":"_ivgBf","cardFooter":"_1WgPL","brandLogo":"_EV0l8","addCardButton":"_1oaCc","plusIcon":"_w9L5L"};
|
|
830
830
|
|
|
831
831
|
var SHOW_LOADER = 'SHOW_LOADER';
|
|
832
832
|
var STOP_LOADER = 'STOP_LOADER';
|
|
@@ -2237,7 +2237,9 @@ var env$3 = configs.env;
|
|
|
2237
2237
|
var CardsManagement = function CardsManagement(_ref) {
|
|
2238
2238
|
var _pg$gateway;
|
|
2239
2239
|
var _ref$paymentDetails = _ref.paymentDetails,
|
|
2240
|
-
paymentDetails = _ref$paymentDetails === void 0 ? {} : _ref$paymentDetails
|
|
2240
|
+
paymentDetails = _ref$paymentDetails === void 0 ? {} : _ref$paymentDetails,
|
|
2241
|
+
_ref$paymentMethod = _ref.paymentMethod,
|
|
2242
|
+
paymentMethod = _ref$paymentMethod === void 0 ? null : _ref$paymentMethod;
|
|
2241
2243
|
var dispatch = useDispatch();
|
|
2242
2244
|
var pg = paymentDetails.pg,
|
|
2243
2245
|
_paymentDetails$cards = paymentDetails.cards,
|
|
@@ -2405,13 +2407,15 @@ var CardsManagement = function CardsManagement(_ref) {
|
|
|
2405
2407
|
}, /*#__PURE__*/React.createElement(IUIGrid, {
|
|
2406
2408
|
container: true,
|
|
2407
2409
|
className: styles$1.formFieldsWrapper
|
|
2408
|
-
}, /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", {
|
|
2410
|
+
}, /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", null, paymentMethod === 2 && /*#__PURE__*/React.createElement("div", {
|
|
2411
|
+
style: classes.disabledNotice
|
|
2412
|
+
}, "Company has disabled usage of your personal cards, please reach out to your admin"), /*#__PURE__*/React.createElement("div", {
|
|
2409
2413
|
className: classes.cardsGrid
|
|
2410
2414
|
}, personalCards.map(function (card) {
|
|
2411
2415
|
return renderCard(card);
|
|
2412
2416
|
}), corporateCards.map(function (card) {
|
|
2413
2417
|
return renderCard(card);
|
|
2414
|
-
})), (!cards || (cards === null || cards === void 0 ? void 0 : cards.length) < 10) && (pg === null || pg === void 0 ? void 0 : (_pg$gateway = pg.gateway) === null || _pg$gateway === void 0 ? void 0 : _pg$gateway.toLowerCase()) === 'stripe' && (pg === null || pg === void 0 ? void 0 : pg.save_card_enable) === 1 && /*#__PURE__*/React.createElement("button", {
|
|
2418
|
+
})), (!cards || (cards === null || cards === void 0 ? void 0 : cards.length) < 10) && (pg === null || pg === void 0 ? void 0 : (_pg$gateway = pg.gateway) === null || _pg$gateway === void 0 ? void 0 : _pg$gateway.toLowerCase()) === 'stripe' && (pg === null || pg === void 0 ? void 0 : pg.save_card_enable) === 1 && paymentMethod !== 2 && /*#__PURE__*/React.createElement("button", {
|
|
2415
2419
|
className: classes.addCardButton,
|
|
2416
2420
|
onClick: function onClick() {
|
|
2417
2421
|
return window.location.assign(_url);
|
|
@@ -2456,7 +2460,7 @@ var CardsManagement = function CardsManagement(_ref) {
|
|
|
2456
2460
|
vertical: 'top',
|
|
2457
2461
|
horizontal: 'right'
|
|
2458
2462
|
}
|
|
2459
|
-
}, /*#__PURE__*/React.createElement(MenuItem, {
|
|
2463
|
+
}, selectedCard && !+selectedCard.metadata.default_card && /*#__PURE__*/React.createElement(MenuItem, {
|
|
2460
2464
|
onClick: handleMarkAsDefault
|
|
2461
2465
|
}, "Mark as default"), /*#__PURE__*/React.createElement(MenuItem, {
|
|
2462
2466
|
onClick: handleDeleteCard,
|
|
@@ -2549,7 +2553,9 @@ var TravelExpenseFields = function TravelExpenseFields(props) {
|
|
|
2549
2553
|
_props$editUserId = props.editUserId,
|
|
2550
2554
|
editUserId = _props$editUserId === void 0 ? null : _props$editUserId,
|
|
2551
2555
|
_props$roles = props.roles,
|
|
2552
|
-
roles = _props$roles === void 0 ? [] : _props$roles
|
|
2556
|
+
roles = _props$roles === void 0 ? [] : _props$roles,
|
|
2557
|
+
_props$paymentMethod = props.paymentMethod,
|
|
2558
|
+
paymentMethod = _props$paymentMethod === void 0 ? null : _props$paymentMethod;
|
|
2553
2559
|
var _useState = useState({
|
|
2554
2560
|
product: '',
|
|
2555
2561
|
approvers: []
|
|
@@ -2846,7 +2852,8 @@ var TravelExpenseFields = function TravelExpenseFields(props) {
|
|
|
2846
2852
|
placeholder: "Example label - \u201CManager\u201D"
|
|
2847
2853
|
}));
|
|
2848
2854
|
})))), type === 'travel' && paymentDetails && /*#__PURE__*/React.createElement(PaymentCards, {
|
|
2849
|
-
paymentDetails: paymentDetails
|
|
2855
|
+
paymentDetails: paymentDetails,
|
|
2856
|
+
paymentMethod: paymentMethod
|
|
2850
2857
|
}));
|
|
2851
2858
|
};
|
|
2852
2859
|
|
|
@@ -5967,7 +5974,9 @@ var UserAddEdit = function UserAddEdit(props) {
|
|
|
5967
5974
|
editUserId = props.editUserId,
|
|
5968
5975
|
config = props.config,
|
|
5969
5976
|
_props$isProfile = props.isProfile,
|
|
5970
|
-
isProfile = _props$isProfile === void 0 ? false : _props$isProfile
|
|
5977
|
+
isProfile = _props$isProfile === void 0 ? false : _props$isProfile,
|
|
5978
|
+
_props$paymentMethod = props.paymentMethod,
|
|
5979
|
+
paymentMethod = _props$paymentMethod === void 0 ? null : _props$paymentMethod;
|
|
5971
5980
|
env$4.init(config, isProfile);
|
|
5972
5981
|
var queryParams = new URLSearchParams(window.location.search);
|
|
5973
5982
|
var verifyUserId = Number(queryParams.get(config.routes.users.add.queryParamKeys.verifyUserId));
|
|
@@ -7878,7 +7887,8 @@ var UserAddEdit = function UserAddEdit(props) {
|
|
|
7878
7887
|
maxApprovers: maxTravelApprovers,
|
|
7879
7888
|
isProfile: isProfile,
|
|
7880
7889
|
editUserId: editUserId,
|
|
7881
|
-
roles: renderFields.travelRoles
|
|
7890
|
+
roles: renderFields.travelRoles,
|
|
7891
|
+
paymentMethod: paymentMethod
|
|
7882
7892
|
}), /*#__PURE__*/React.createElement(AdditionalInfo, {
|
|
7883
7893
|
membershipInfoInput: membershipInfoInput,
|
|
7884
7894
|
onMemInfoInputChange: onMemInfoInputChange,
|