@rh-support/troubleshoot 2.7.53 → 2.7.57
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/Case.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Case.js +2 -0
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseDetailsManagement.js +3 -6
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.js +9 -3
- package/lib/esm/components/CaseInformation/ContactPhoneNumber.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/ContactPhoneNumber.js +20 -6
- package/lib/esm/components/CaseManagement/CaseManagement.js +3 -0
- package/lib/esm/components/CaseManagement/SendNotifications/CaseContactSelector.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/SendNotifications/CaseContactSelector.js +178 -74
- package/lib/esm/components/CaseManagement/SendNotifications/SendNotificationsPopOver.d.ts +3 -0
- package/lib/esm/components/CaseManagement/SendNotifications/SendNotificationsPopOver.d.ts.map +1 -0
- package/lib/esm/components/CaseManagement/SendNotifications/SendNotificationsPopOver.js +10 -0
- package/lib/esm/components/IdeaInformation/IdeaInformation.js +2 -1
- package/lib/esm/components/Review/Review.d.ts.map +1 -1
- package/lib/esm/components/Review/Review.js +6 -9
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.js +10 -1
- package/lib/esm/components/shared/fileUpload/useFileUploader.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/useFileUploader.js +7 -3
- package/lib/esm/graphql/queries/getEscalationDetails.d.ts.map +1 -1
- package/lib/esm/graphql/queries/getEscalationDetails.js +3 -0
- package/lib/esm/graphql/schemas/escalation.d.ts +3 -0
- package/lib/esm/graphql/schemas/escalation.d.ts.map +1 -1
- package/lib/esm/hooks/useS3Upload.d.ts.map +1 -1
- package/lib/esm/hooks/useS3Upload.js +5 -1
- package/lib/esm/hooks/useSyncServerAttachments.d.ts.map +1 -1
- package/lib/esm/hooks/useSyncServerAttachments.js +33 -34
- package/lib/esm/index.js +1 -1
- package/lib/esm/reducers/CaseConstNTypes.d.ts +3 -0
- package/lib/esm/reducers/CaseConstNTypes.d.ts.map +1 -1
- package/lib/esm/reducers/CaseConstNTypes.js +3 -0
- package/lib/esm/reducers/CaseDetailsPageReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseDetailsPageReducer.js +20 -4
- package/lib/esm/reducers/CaseReducer.d.ts +11 -1
- package/lib/esm/reducers/CaseReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseReducer.js +80 -2
- package/package.json +7 -7
|
@@ -20,7 +20,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
20
20
|
};
|
|
21
21
|
import { contacts, kase, pcm, publicApi } from '@cee-eng/hydrajs';
|
|
22
22
|
import { formattedApiErrorMessage } from '@rh-support/components';
|
|
23
|
-
import { CREATE_CASE_LABEL_LINK, CREATE_SUPPORT_CASE, dtmTrackEventCaseCreationStepEncountered, fetchCaseDetailsByCaseNumber, fetchLoggedInUserAccountContactsFromGraphQL, GET_ACCOUNT, GET_CASE_GROUP, GET_PRODUCTS, getAccountQueryVariables, getApiResourceObject, handleGraphQLAccountResponse, handleGraphQLVersionsResponse, mapGraphQLCaseDetailsToCasePayload, PreviousToNewCaseTypeMap, shouldPersistInProgressOnCustomerActivity, updateCaseDetailsGraphQLRequest, } from '@rh-support/utils';
|
|
23
|
+
import { CREATE_CASE_LABEL_LINK, CREATE_SUPPORT_CASE, createCaseWatchersForContacts, deleteCaseWatchersForContacts, dtmTrackEventCaseCreationStepEncountered, fetchCaseDetailsByCaseNumber, fetchCaseWatcherContactsByCaseNumber, fetchLoggedInUserAccountContactsFromGraphQL, GET_ACCOUNT, GET_CASE_GROUP, GET_PRODUCTS, getAccountQueryVariables, getApiResourceObject, handleGraphQLAccountResponse, handleGraphQLVersionsResponse, mapGraphQLCaseDetailsToCasePayload, PreviousToNewCaseTypeMap, shouldPersistInProgressOnCustomerActivity, 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';
|
|
@@ -397,6 +397,47 @@ export const deleteNotifiedUsers = (dispatch, caseNumber, ssoUsernames) => __awa
|
|
|
397
397
|
});
|
|
398
398
|
}
|
|
399
399
|
});
|
|
400
|
+
export const deleteCaseWatchers = (dispatch, apolloClient, contacts) => __awaiter(void 0, void 0, void 0, function* () {
|
|
401
|
+
dispatch({
|
|
402
|
+
type: CaseReducerConstants.setAddNotifiedUserError,
|
|
403
|
+
payload: { updateNotifiedUserError: false, updateNotifiedUserLoading: true },
|
|
404
|
+
});
|
|
405
|
+
try {
|
|
406
|
+
yield deleteCaseWatchersForContacts(apolloClient, contacts);
|
|
407
|
+
dispatch({
|
|
408
|
+
type: CaseReducerConstants.setAddNotifiedUserError,
|
|
409
|
+
payload: { updateNotifiedUserError: false, updateNotifiedUserLoading: false },
|
|
410
|
+
});
|
|
411
|
+
}
|
|
412
|
+
catch (error) {
|
|
413
|
+
dispatch({
|
|
414
|
+
type: CaseReducerConstants.setAddNotifiedUserError,
|
|
415
|
+
payload: { updateNotifiedUserError: true, updateNotifiedUserLoading: false },
|
|
416
|
+
});
|
|
417
|
+
throw error;
|
|
418
|
+
}
|
|
419
|
+
});
|
|
420
|
+
export const createCaseWatchers = (dispatch, apolloClient, caseSalesforceId, contacts) => __awaiter(void 0, void 0, void 0, function* () {
|
|
421
|
+
dispatch({
|
|
422
|
+
type: CaseReducerConstants.setAddNotifiedUserError,
|
|
423
|
+
payload: { updateNotifiedUserError: false, updateNotifiedUserLoading: true },
|
|
424
|
+
});
|
|
425
|
+
try {
|
|
426
|
+
const createdContacts = yield createCaseWatchersForContacts(apolloClient, caseSalesforceId, contacts);
|
|
427
|
+
dispatch({
|
|
428
|
+
type: CaseReducerConstants.setAddNotifiedUserError,
|
|
429
|
+
payload: { updateNotifiedUserError: false, updateNotifiedUserLoading: false },
|
|
430
|
+
});
|
|
431
|
+
return createdContacts;
|
|
432
|
+
}
|
|
433
|
+
catch (error) {
|
|
434
|
+
dispatch({
|
|
435
|
+
type: CaseReducerConstants.setAddNotifiedUserError,
|
|
436
|
+
payload: { updateNotifiedUserError: true, updateNotifiedUserLoading: false },
|
|
437
|
+
});
|
|
438
|
+
throw error;
|
|
439
|
+
}
|
|
440
|
+
});
|
|
400
441
|
export const addingNotifiedUsers = (dispatch, caseNumber, addedUsers) => __awaiter(void 0, void 0, void 0, function* () {
|
|
401
442
|
const ssoUsernames = addedUsers.map((u) => ({ ssoUsername: u.ssoUsername }));
|
|
402
443
|
dispatch({
|
|
@@ -947,7 +988,6 @@ export const updateCaseDetailsGraphQL = (dispatch, apolloClient, caseNumber, cas
|
|
|
947
988
|
throw error;
|
|
948
989
|
}
|
|
949
990
|
});
|
|
950
|
-
/** GraphQL CaseUpdate for severity/status and FTS (X24x7__c / X24x7ContactInformation__c). */
|
|
951
991
|
export const updateCaseSeverityAndFtsGraphQL = (dispatch, apolloClient, caseNumber, payload, currentSeverity, options) => __awaiter(void 0, void 0, void 0, function* () {
|
|
952
992
|
const graphqlUpdate = buildCaseSeverityFtsGraphQLUpdate(payload, currentSeverity);
|
|
953
993
|
if (Object.keys(graphqlUpdate).length === 0) {
|
|
@@ -955,6 +995,44 @@ export const updateCaseSeverityAndFtsGraphQL = (dispatch, apolloClient, caseNumb
|
|
|
955
995
|
}
|
|
956
996
|
yield updateCaseDetailsGraphQL(dispatch, apolloClient, caseNumber, graphqlUpdate, false, options);
|
|
957
997
|
});
|
|
998
|
+
export const loadCaseWatcherNotificationContacts = (dispatch, apolloClient, caseNumber) => __awaiter(void 0, void 0, void 0, function* () {
|
|
999
|
+
if (!caseNumber) {
|
|
1000
|
+
dispatch({
|
|
1001
|
+
type: CaseReducerConstants.getSelectedAccountDetailsHydra,
|
|
1002
|
+
payload: { selectedNotificationContacts: [] },
|
|
1003
|
+
});
|
|
1004
|
+
return;
|
|
1005
|
+
}
|
|
1006
|
+
dispatch({
|
|
1007
|
+
type: CaseReducerConstants.getSelectedAccountDetailsHydra,
|
|
1008
|
+
payload: { isFetchingSelectedNotificationContacts: true, hasErrorSelectedNotificationContacts: false },
|
|
1009
|
+
});
|
|
1010
|
+
try {
|
|
1011
|
+
const selectedNotificationContacts = yield fetchCaseWatcherContactsByCaseNumber(apolloClient, caseNumber);
|
|
1012
|
+
dispatch({
|
|
1013
|
+
type: CaseReducerConstants.getSelectedAccountDetailsHydra,
|
|
1014
|
+
payload: {
|
|
1015
|
+
selectedNotificationContacts,
|
|
1016
|
+
isFetchingSelectedNotificationContacts: false,
|
|
1017
|
+
hasErrorSelectedNotificationContacts: false,
|
|
1018
|
+
},
|
|
1019
|
+
});
|
|
1020
|
+
const notifiedUsers = map(selectedNotificationContacts, (contact) => ({
|
|
1021
|
+
ssoUsername: contact.ssoUsername,
|
|
1022
|
+
fullNameCustom: [contact.firstName, contact.lastName].filter(Boolean).join(' '),
|
|
1023
|
+
}));
|
|
1024
|
+
dispatch({
|
|
1025
|
+
type: CaseReducerConstants.setLoadedNotificationContacts,
|
|
1026
|
+
payload: { notifiedUsers },
|
|
1027
|
+
});
|
|
1028
|
+
}
|
|
1029
|
+
catch (e) {
|
|
1030
|
+
dispatch({
|
|
1031
|
+
type: CaseReducerConstants.selectedAccountDetailsHydraError,
|
|
1032
|
+
payload: { isFetchingSelectedNotificationContacts: false, hasErrorSelectedNotificationContacts: true },
|
|
1033
|
+
});
|
|
1034
|
+
}
|
|
1035
|
+
});
|
|
958
1036
|
export const getNotificationContacts4InternalUser = (dispatch, users, caseOwnerSSO) => __awaiter(void 0, void 0, void 0, function* () {
|
|
959
1037
|
const usersArr = (users || []).map((o) => o.ssoUsername).filter((s) => !!s);
|
|
960
1038
|
caseOwnerSSO && usersArr.push(caseOwnerSSO);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/troubleshoot",
|
|
3
|
-
"version": "2.7.
|
|
3
|
+
"version": "2.7.57",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -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.6.
|
|
56
|
-
"@rh-support/react-context": "2.6.
|
|
57
|
-
"@rh-support/types": "2.0.
|
|
58
|
-
"@rh-support/user-permissions": "2.6.
|
|
59
|
-
"@rh-support/utils": "2.6.
|
|
55
|
+
"@rh-support/components": "2.6.49",
|
|
56
|
+
"@rh-support/react-context": "2.6.51",
|
|
57
|
+
"@rh-support/types": "2.0.33",
|
|
58
|
+
"@rh-support/user-permissions": "2.6.46",
|
|
59
|
+
"@rh-support/utils": "2.6.45",
|
|
60
60
|
"@types/react-redux": "^7.1.33",
|
|
61
61
|
"@types/redux": "^3.6.0",
|
|
62
62
|
"date-fns": "3.6.0",
|
|
@@ -129,5 +129,5 @@
|
|
|
129
129
|
"defaults and supports es6-module",
|
|
130
130
|
"maintained node versions"
|
|
131
131
|
],
|
|
132
|
-
"gitHead": "
|
|
132
|
+
"gitHead": "dd818edf4098c866388b59af94b99d889a004681"
|
|
133
133
|
}
|