@rh-support/troubleshoot 2.6.312 → 2.6.314
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/lib/esm/components/CaseEditView/ActiveCustomerEscalation/RequestEscalationModal.js +2 -2
- package/lib/esm/components/CaseEditView/Case.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Case.js +4 -3
- package/lib/esm/components/CaseEditView/CaseOverview/index.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseOverview/index.js +2 -2
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseDetailsManagement.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseDetailsManagement.js +2 -2
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/ProductVersion.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/ProductVersion.js +64 -8
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.js +17 -20
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.js +7 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.js +7 -8
- package/lib/esm/components/CaseInformation/CaseInformation.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/CaseInformation.js +3 -4
- package/lib/esm/components/CaseInformation/FileDiag.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/FileDiag.js +0 -4
- package/lib/esm/components/IdeaInformation/IdeaInformation.d.ts.map +1 -1
- package/lib/esm/components/IdeaInformation/IdeaInformation.js +3 -4
- package/lib/esm/components/ProductSelector/NewProductVersionSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/NewProductVersionSelector.js +8 -1
- package/lib/esm/components/ProductSelector/ProductNotEntitledWarning.d.ts +3 -0
- package/lib/esm/components/ProductSelector/ProductNotEntitledWarning.d.ts.map +1 -0
- package/lib/esm/components/ProductSelector/ProductNotEntitledWarning.js +9 -0
- package/lib/esm/components/ProductSelector/ProductVersionDropdownSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/ProductVersionDropdownSelector.js +9 -1
- package/lib/esm/components/Recommendations/AsideResults.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/AsideResults.js +3 -2
- package/lib/esm/components/shared/fileUpload/FileUpload.js +2 -3
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.d.ts +1 -0
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.js +17 -8
- package/lib/esm/components/shared/fileUpload/useFileUploader.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/useFileUploader.js +26 -8
- package/lib/esm/components/shared/useIsSectionValid.d.ts.map +1 -1
- package/lib/esm/components/shared/useIsSectionValid.js +21 -42
- package/lib/esm/components/wizardLayout/GlobalTroubleshootEffects.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/GlobalTroubleshootEffects.js +19 -12
- package/lib/esm/components/wizardLayout/WizardAside.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/WizardAside.js +2 -4
- package/lib/esm/components/wizardLayout/WizardLayout.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/WizardLayout.js +4 -36
- package/lib/esm/css/case.css +6 -0
- package/lib/esm/reducers/CaseConstNTypes.d.ts +0 -1
- package/lib/esm/reducers/CaseConstNTypes.d.ts.map +1 -1
- package/lib/esm/reducers/CaseConstNTypes.js +0 -1
- package/lib/esm/reducers/CaseReducer.d.ts +3 -1
- package/lib/esm/reducers/CaseReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseReducer.js +30 -37
- package/package.json +7 -7
- package/lib/esm/components/ProductSelector/ProductNotEntitledModal.d.ts +0 -8
- package/lib/esm/components/ProductSelector/ProductNotEntitledModal.d.ts.map +0 -1
- package/lib/esm/components/ProductSelector/ProductNotEntitledModal.js +0 -11
|
@@ -64,7 +64,9 @@ export declare const updateCaseDetailsGraphQL: (dispatch: CaseReducerDispatchTyp
|
|
|
64
64
|
mutate: (options: any) => Promise<any>;
|
|
65
65
|
}, caseNumber: string, caseUpdate: Partial<IGraphQLCaseUpdateInput>, dontSetDetails?: boolean, options?: UpdateCaseDetailsGraphQLOptions) => Promise<void>;
|
|
66
66
|
export declare const getNotificationContacts4InternalUser: (dispatch: CaseReducerDispatchType, users: INotifiedUser[], caseOwnerSSO: string) => Promise<void>;
|
|
67
|
-
export declare const getNotificationContacts4ExternalUser: (dispatch: CaseReducerDispatchType, users: any, loggedInUserRights: any, accountNumber: any, caseOwnerSSO: string, fullNameCustom: string
|
|
67
|
+
export declare const getNotificationContacts4ExternalUser: (dispatch: CaseReducerDispatchType, users: any, loggedInUserRights: any, accountNumber: any, caseOwnerSSO: string, fullNameCustom: string, apolloClient?: {
|
|
68
|
+
query: (options: any) => Promise<any>;
|
|
69
|
+
}) => Promise<void>;
|
|
68
70
|
export declare const checkForCaseStatusToggleOnAttachOrComment: (dispatch: CaseReducerDispatchType, isInternal: boolean, currentStatus: string) => void;
|
|
69
71
|
export declare const setSelectedCaseGroupUsers: (dispatch: CaseReducerDispatchType, accountNumber: string, groupNumber: string, loggedInUserRights: UserAuth) => Promise<void>;
|
|
70
72
|
export declare function getCustomNotificationEmails(dispatch: CaseReducerDispatchType, caseNumber: string): Promise<void>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseReducer.d.ts","sourceRoot":"","sources":["../../../src/reducers/CaseReducer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,qDAAqD,CAAC;AACnF,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,WAAW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AAC,0BAA0B,EAAE,CAAC,CAAC,EAC5E,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,0BAA0B,EAAE,QAO5D;AAED,wBAAsB,kBAAkB,CACpC,QAAQ,EAAE,uBAAuB,EACjC,YAAY,EAAE;IAAE,KAAK,EAAE,CAAC,OAAO,EAAE,GAAG,KAAK,OAAO,CAAC,GAAG,CAAC,CAAA;CAAE,EACvD,eAAe,EAAE,MAAM,EACvB,iBAAiB,EAAE,MAAM,iBAgC5B;AAED,eAAO,MAAM,kBAAkB,GAAI,UAAU,uBAAuB,EAAE,MAAM,OAAO,SAKlF,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAAI,UAAU,uBAAuB,EAAE,iBAAiB,MAAM,SAK5F,CAAC"}
|
|
@@ -18,9 +18,9 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
18
18
|
}
|
|
19
19
|
return t;
|
|
20
20
|
};
|
|
21
|
-
import {
|
|
21
|
+
import { contacts, kase, pcm, publicApi } from '@cee-eng/hydrajs';
|
|
22
22
|
import { formattedApiErrorMessage } from '@rh-support/components';
|
|
23
|
-
import { CREATE_SUPPORT_CASE, dtmTrackEventCaseCreationStepEncountered, fetchCaseDetailsByCaseNumber, GET_ACCOUNT, GET_CASE_GROUP, GET_PRODUCTS, getAccountQueryVariables, getApiResourceObject, handleGraphQLAccountResponse, handleGraphQLVersionsResponse, mapGraphQLCaseDetailsToCasePayload, PreviousToNewCaseTypeMap, updateCaseDetailsGraphQLRequest, } from '@rh-support/utils';
|
|
23
|
+
import { CREATE_SUPPORT_CASE, dtmTrackEventCaseCreationStepEncountered, fetchCaseDetailsByCaseNumber, fetchLoggedInUserAccountContactsFromGraphQL, GET_ACCOUNT, GET_CASE_GROUP, GET_PRODUCTS, getAccountQueryVariables, getApiResourceObject, handleGraphQLAccountResponse, handleGraphQLVersionsResponse, mapGraphQLCaseDetailsToCasePayload, PreviousToNewCaseTypeMap, updateCaseDetailsGraphQLRequest, } from '@rh-support/utils';
|
|
24
24
|
// import delay from 'lodash/delay';
|
|
25
25
|
import filter from 'lodash/filter';
|
|
26
26
|
import find from 'lodash/find';
|
|
@@ -51,8 +51,10 @@ export const caseReducer = (pState, action) => {
|
|
|
51
51
|
}
|
|
52
52
|
if (((_f = (_e = action.payload) === null || _e === void 0 ? void 0 : _e.caseDetails) === null || _f === void 0 ? void 0 : _f.product) &&
|
|
53
53
|
pState.caseDetails.product !== ((_h = (_g = action.payload) === null || _g === void 0 ? void 0 : _g.caseDetails) === null || _h === void 0 ? void 0 : _h.product)) {
|
|
54
|
-
//
|
|
55
|
-
action.payload.caseDetails
|
|
54
|
+
// Reset SLA on product change unless the caller already provided the new entitlement SLA
|
|
55
|
+
if (!Object.prototype.hasOwnProperty.call(action.payload.caseDetails, 'entitlementSla')) {
|
|
56
|
+
action.payload.caseDetails.entitlementSla = undefined;
|
|
57
|
+
}
|
|
56
58
|
resetEntitlementId = true;
|
|
57
59
|
}
|
|
58
60
|
return Object.assign(Object.assign(Object.assign({}, pState), { hasLargeCaseDescription, caseDetails: Object.assign(Object.assign({}, pState.caseDetails), action.payload.caseDetails), isCaseUpdating: false }), (resetEntitlementId ? { selectedEntitlementId: undefined } : {}));
|
|
@@ -502,7 +504,11 @@ export const setCaseOwner = (dispatch_1, owner_1, product_1, abortSignalCaseGrou
|
|
|
502
504
|
}
|
|
503
505
|
dispatch({
|
|
504
506
|
type: CaseReducerConstants.caseStateChanged,
|
|
505
|
-
payload: {
|
|
507
|
+
payload: {
|
|
508
|
+
selectedOwner: getApiResourceObject(owner),
|
|
509
|
+
// Invert global/user isEntitled (from subscription GraphQL) into case entitlement flag
|
|
510
|
+
hasInvalidEntitlements: owner.isEntitled === false,
|
|
511
|
+
},
|
|
506
512
|
});
|
|
507
513
|
dispatch({
|
|
508
514
|
type: CaseReducerConstants.caseDetailChanged,
|
|
@@ -607,6 +613,7 @@ export const fetchCaseGroupsForContactGraphQL = (dispatch_1, apolloClient_1, con
|
|
|
607
613
|
try {
|
|
608
614
|
const { data } = yield apolloClient.query({
|
|
609
615
|
query: GET_CASE_GROUP,
|
|
616
|
+
variables: { first: 2000 },
|
|
610
617
|
});
|
|
611
618
|
const response = data;
|
|
612
619
|
const allGroups = (_d = (_c = (_b = (_a = response === null || response === void 0 ? void 0 : response.redhat_support_uiapi) === null || _a === void 0 ? void 0 : _a.query) === null || _b === void 0 ? void 0 : _b.RedHatSupportCaseGroup__c) === null || _c === void 0 ? void 0 : _c.edges) !== null && _d !== void 0 ? _d : [];
|
|
@@ -666,7 +673,7 @@ export const updateCaseWithSession = (dispatch_1, sessionItem_1, loggedInUserAcc
|
|
|
666
673
|
// Set owner and Notified users
|
|
667
674
|
const notifiedUsersExternal = (_b = (_a = sessionDetails.notifiedUsersExternal) === null || _a === void 0 ? void 0 : _a.split(',')) !== null && _b !== void 0 ? _b : [];
|
|
668
675
|
const notifiedUsersInternal = (_d = (_c = sessionDetails.notifiedUsersInternal) === null || _c === void 0 ? void 0 : _c.split(',')) !== null && _d !== void 0 ? _d : [];
|
|
669
|
-
const allRelevantContacts = yield getAllRelevantContacts(loggedInUserContact, caseDetails.accountNumberRef, caseDetails.contactSSOName, notifiedUsersExternal, notifiedUsersInternal);
|
|
676
|
+
const allRelevantContacts = yield getAllRelevantContacts(loggedInUserContact, caseDetails.accountNumberRef, caseDetails.contactSSOName, notifiedUsersExternal, notifiedUsersInternal, apolloClient);
|
|
670
677
|
const owner = find(allRelevantContacts, (c) => c.ssoUsername === caseDetails.contactSSOName);
|
|
671
678
|
const selectedNotificationContacts = getSelectedNotificationContactsFromSession(allRelevantContacts, [
|
|
672
679
|
...notifiedUsersExternal,
|
|
@@ -690,7 +697,7 @@ export const updateCaseWithSession = (dispatch_1, sessionItem_1, loggedInUserAcc
|
|
|
690
697
|
});
|
|
691
698
|
}
|
|
692
699
|
});
|
|
693
|
-
const getAllRelevantContacts = (loggedInUserContact, caseAccountNumber, contactSsoUsername, notifiedUsersExternal, notifiedUsersInternal) => __awaiter(void 0, void 0, void 0, function* () {
|
|
700
|
+
const getAllRelevantContacts = (loggedInUserContact, caseAccountNumber, contactSsoUsername, notifiedUsersExternal, notifiedUsersInternal, apolloClient) => __awaiter(void 0, void 0, void 0, function* () {
|
|
694
701
|
if (loggedInUserContact.isInternal) {
|
|
695
702
|
// Internal users can use the internal API and be done with it
|
|
696
703
|
const userArray = uniq([contactSsoUsername, ...notifiedUsersExternal, ...notifiedUsersInternal]);
|
|
@@ -701,18 +708,12 @@ const getAllRelevantContacts = (loggedInUserContact, caseAccountNumber, contactS
|
|
|
701
708
|
return response.items;
|
|
702
709
|
}
|
|
703
710
|
else {
|
|
704
|
-
const promiseArray = [];
|
|
705
|
-
// Only Org admins have access to there own org accounts
|
|
706
|
-
loggedInUserContact.isOrgAdmin &&
|
|
707
|
-
promiseArray.push(accounts.getAccountContacts(loggedInUserContact.accountNumber));
|
|
708
|
-
// However, all external users (org + non-org) can get list of the managed customer contacts
|
|
709
|
-
// This is specifically relevant for partners accessing their customer cases
|
|
710
|
-
loggedInUserContact.accountNumber !== caseAccountNumber &&
|
|
711
|
-
promiseArray.push(accounts.getAccountContacts(caseAccountNumber));
|
|
712
|
-
const response = yield Promise.all(promiseArray);
|
|
713
711
|
const contactsToReturn = [];
|
|
714
|
-
|
|
715
|
-
|
|
712
|
+
const shouldFetchAccountContacts = loggedInUserContact.isOrgAdmin || loggedInUserContact.accountNumber !== caseAccountNumber;
|
|
713
|
+
if (shouldFetchAccountContacts && apolloClient) {
|
|
714
|
+
const accountContacts = yield fetchLoggedInUserAccountContactsFromGraphQL(apolloClient);
|
|
715
|
+
contactsToReturn.push(...accountContacts);
|
|
716
|
+
}
|
|
716
717
|
contactsToReturn.push(loggedInUserContact);
|
|
717
718
|
return uniqBy(contactsToReturn, 'ssoUsername');
|
|
718
719
|
}
|
|
@@ -860,7 +861,9 @@ export const updateCaseDetailsGraphQL = (dispatch, apolloClient, caseNumber, cas
|
|
|
860
861
|
dispatch({ type: CaseReducerConstants.updateCaseDetailCompleted });
|
|
861
862
|
return;
|
|
862
863
|
}
|
|
863
|
-
|
|
864
|
+
// productId/entitlementId are only used to build the GraphQL mutation patch, not case details UI state
|
|
865
|
+
const { productId: _productId, entitlementId: _entitlementId } = caseUpdate, caseUpdateWithoutIds = __rest(caseUpdate, ["productId", "entitlementId"]);
|
|
866
|
+
let updatedCaseDetails = Object.assign({}, caseUpdateWithoutIds);
|
|
864
867
|
if (graphqlDetails) {
|
|
865
868
|
const mappedGraphQLDetails = mapGraphQLCaseDetailsToCasePayload(graphqlDetails);
|
|
866
869
|
updatedCaseDetails = Object.assign(Object.assign({}, updatedCaseDetails), Object.fromEntries(Object.entries(mappedGraphQLDetails).filter(([, value]) => value !== null && value !== undefined && value !== '')));
|
|
@@ -918,7 +921,7 @@ export const getNotificationContacts4InternalUser = (dispatch, users, caseOwnerS
|
|
|
918
921
|
});
|
|
919
922
|
}
|
|
920
923
|
});
|
|
921
|
-
export const getNotificationContacts4ExternalUser = (dispatch, users, loggedInUserRights, accountNumber, caseOwnerSSO, fullNameCustom) => __awaiter(void 0, void 0, void 0, function* () {
|
|
924
|
+
export const getNotificationContacts4ExternalUser = (dispatch, users, loggedInUserRights, accountNumber, caseOwnerSSO, fullNameCustom, apolloClient) => __awaiter(void 0, void 0, void 0, function* () {
|
|
922
925
|
try {
|
|
923
926
|
const selectedNotificationContacts = [];
|
|
924
927
|
if (loggedInUserRights.isExternalNonOrgAdmin()) {
|
|
@@ -957,24 +960,14 @@ export const getNotificationContacts4ExternalUser = (dispatch, users, loggedInUs
|
|
|
957
960
|
type: CaseReducerConstants.getSelectedAccountDetailsHydra,
|
|
958
961
|
payload: { isFetchingSelectedNotificationContacts: true, hasErrorSelectedNotificationContacts: false },
|
|
959
962
|
});
|
|
960
|
-
const
|
|
961
|
-
|
|
962
|
-
loggedInUserRights.isOrgAdmin() &&
|
|
963
|
-
promiseArray.push(accounts.getAccountContacts(loggedInUserRights.user.accountNumber));
|
|
964
|
-
// However, all external users (org + non-org) can get list of the managed customer contacts
|
|
965
|
-
// This is specifically relevant for partners accessing their customer cases
|
|
966
|
-
loggedInUserRights.isAccountDifferentFromLoggedInAccount(accountNumber) &&
|
|
967
|
-
promiseArray.push(accounts.getAccountContacts(accountNumber));
|
|
968
|
-
dispatch({
|
|
969
|
-
type: CaseReducerConstants.getSelectedAccountDetailsHydra,
|
|
970
|
-
payload: { isFetchingSelectedNotificationContacts: true, hasErrorSelectedNotificationContacts: false },
|
|
971
|
-
});
|
|
972
|
-
const response = yield Promise.all(promiseArray);
|
|
963
|
+
const shouldFetchAccountContacts = loggedInUserRights.isOrgAdmin() ||
|
|
964
|
+
loggedInUserRights.isAccountDifferentFromLoggedInAccount(accountNumber);
|
|
973
965
|
let contactsToReturn = [];
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
966
|
+
if (shouldFetchAccountContacts && apolloClient) {
|
|
967
|
+
contactsToReturn = yield fetchLoggedInUserAccountContactsFromGraphQL(apolloClient);
|
|
968
|
+
contactsToReturn = uniqBy(contactsToReturn, 'ssoUsername').filter((contact) => usersArr.indexOf(contact.ssoUsername) !== -1);
|
|
969
|
+
selectedNotificationContacts.push(...contactsToReturn);
|
|
970
|
+
}
|
|
978
971
|
}
|
|
979
972
|
dispatch({
|
|
980
973
|
type: CaseReducerConstants.getSelectedAccountDetailsHydra,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/troubleshoot",
|
|
3
|
-
"version": "2.6.
|
|
3
|
+
"version": "2.6.314",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"react-virtualized": "^9.22.5"
|
|
43
43
|
},
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@cee-eng/hydrajs": "^4.18.
|
|
45
|
+
"@cee-eng/hydrajs": "^4.18.114",
|
|
46
46
|
"@cee-eng/ui-toolkit": "1.1.9",
|
|
47
47
|
"@ifd-ui/ask-redhat-core": "^0.0.61",
|
|
48
48
|
"@patternfly/patternfly": "6.2.1",
|
|
@@ -52,11 +52,11 @@
|
|
|
52
52
|
"@progress/kendo-licensing": "1.3.5",
|
|
53
53
|
"@progress/kendo-react-pdf": "^5.16.0",
|
|
54
54
|
"@redux-devtools/extension": "^3.3.0",
|
|
55
|
-
"@rh-support/components": "2.5.
|
|
56
|
-
"@rh-support/react-context": "2.5.
|
|
55
|
+
"@rh-support/components": "2.5.195",
|
|
56
|
+
"@rh-support/react-context": "2.5.289",
|
|
57
57
|
"@rh-support/types": "2.0.26",
|
|
58
|
-
"@rh-support/user-permissions": "2.5.
|
|
59
|
-
"@rh-support/utils": "2.5.
|
|
58
|
+
"@rh-support/user-permissions": "2.5.141",
|
|
59
|
+
"@rh-support/utils": "2.5.123",
|
|
60
60
|
"@types/react-redux": "^7.1.33",
|
|
61
61
|
"@types/redux": "^3.6.0",
|
|
62
62
|
"date-fns": "3.6.0",
|
|
@@ -126,5 +126,5 @@
|
|
|
126
126
|
"defaults and supports es6-module",
|
|
127
127
|
"maintained node versions"
|
|
128
128
|
],
|
|
129
|
-
"gitHead": "
|
|
129
|
+
"gitHead": "f5994856f35873c8555a84006c0d278fbc98b067"
|
|
130
130
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ProductNotEntitledModal.d.ts","sourceRoot":"","sources":["../../../../src/components/ProductSelector/ProductNotEntitledModal.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,UAAU,MAAM;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;CACvB;AAED,wBAAgB,uBAAuB,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,EAAE,MAAM,qBAkBlE"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Button, Modal, ModalBody, ModalFooter, ModalHeader, ModalVariant } from '@patternfly/react-core';
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { useTranslation } from 'react-i18next';
|
|
4
|
-
export function ProductNotEntitledModal({ isOpen, onClose }) {
|
|
5
|
-
const { t } = useTranslation();
|
|
6
|
-
return (React.createElement(Modal, { variant: ModalVariant.small, isOpen: isOpen, onClose: onClose, "aria-label": t('Product Not Entitled') },
|
|
7
|
-
React.createElement(ModalHeader, { title: t('Product Not Entitled'), titleIconVariant: "warning" }),
|
|
8
|
-
React.createElement(ModalBody, null, t('The selected product is not included in your current subscription entitlements. Please choose an entitled product or contact your administrator to update your subscription.')),
|
|
9
|
-
React.createElement(ModalFooter, null,
|
|
10
|
-
React.createElement(Button, { variant: "primary", onClick: onClose }, t('Okay')))));
|
|
11
|
-
}
|