@rh-support/troubleshoot 2.5.39 → 2.5.40
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Case.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseEditView/Case.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAS,mBAAmB,EAAiD,MAAM,kBAAkB,CAAC;AAkB7G,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,UAAU,IAAI,CAAC,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"Case.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseEditView/Case.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAS,mBAAmB,EAAiD,MAAM,kBAAkB,CAAC;AAkB7G,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,UAAU,IAAI,CAAC,KAAK,EAAE,MAAM,qBA6LzC"}
|
|
@@ -1,12 +1,3 @@
|
|
|
1
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
-
});
|
|
9
|
-
};
|
|
10
1
|
import { CoverSpinner, ErrorBoundary, OverviewContentLoader, ToastNotification, useDocumentTitle, usePrevious, } from '@rh-support/components';
|
|
11
2
|
import { GlobalMetadataStateContext, HostnameAwarenessModal } from '@rh-support/react-context';
|
|
12
3
|
import { AbilityContext, CaseDetailsFields, resourceActions, resources } from '@rh-support/user-permissions';
|
|
@@ -82,8 +73,6 @@ export default function Case(props) {
|
|
|
82
73
|
}
|
|
83
74
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
84
75
|
}, [loggedInUsersAccount.data]);
|
|
85
|
-
// Create a ref to track the current case number
|
|
86
|
-
const currentCaseRef = useRef(caseNumber);
|
|
87
76
|
useEffect(() => {
|
|
88
77
|
if (caseNumber === previousCaseNumber)
|
|
89
78
|
return;
|
|
@@ -91,26 +80,20 @@ export default function Case(props) {
|
|
|
91
80
|
props.routeProps.history.replace('/case/list');
|
|
92
81
|
return;
|
|
93
82
|
}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
if (canSeeFeedbackButtons) {
|
|
109
|
-
fetchFeedbacks(caseDetailsPageDispatch, caseNumber);
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
});
|
|
113
|
-
handleCaseChange();
|
|
83
|
+
if (caseNumber) {
|
|
84
|
+
fetchCaseDetails(caseDispatch, caseNumber, loggedInUserRights.data, loggedInUser.data);
|
|
85
|
+
canSeeRMEs &&
|
|
86
|
+
fetchCaseEscalations(caseDetailsPageDispatch, caseNumber, loggedInUserRights.data.getAccountNumber());
|
|
87
|
+
// fetch data in advance
|
|
88
|
+
canSeeAttachments &&
|
|
89
|
+
fetchAttachments(caseDetailsPageDispatch, caseNumber, loggedInUsersAccount.data.secureSupport);
|
|
90
|
+
canSeeExternalTracker && fetchExternalTrackers(caseDetailsPageDispatch, caseNumber);
|
|
91
|
+
checkRemoteSessionFlag();
|
|
92
|
+
}
|
|
93
|
+
if (canSeeFeedbackButtons && caseNumber) {
|
|
94
|
+
// fetch data in advance
|
|
95
|
+
fetchFeedbacks(caseDetailsPageDispatch, caseNumber);
|
|
96
|
+
}
|
|
114
97
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
115
98
|
}, [
|
|
116
99
|
caseNumber,
|
|
@@ -15,7 +15,7 @@ export function CaseDetailsErrorMessage(props) {
|
|
|
15
15
|
1. Account mismatch.
|
|
16
16
|
2. Invalid case group
|
|
17
17
|
*/
|
|
18
|
-
const isCaseGroupError = errorDetails['detailMessage'] === INVALID_CASE_GROUP_API_ERROR_DEFAULT_MESSAGE;
|
|
18
|
+
const isCaseGroupError = (errorDetails === null || errorDetails === void 0 ? void 0 : errorDetails['detailMessage']) === INVALID_CASE_GROUP_API_ERROR_DEFAULT_MESSAGE;
|
|
19
19
|
const getErrorMessage = () => {
|
|
20
20
|
const { status, message = '' } = errorDetails || {};
|
|
21
21
|
const customDefaultErrorMessage403 = isCaseGroupError
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/troubleshoot",
|
|
3
|
-
"version": "2.5.
|
|
3
|
+
"version": "2.5.40",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -134,5 +134,5 @@
|
|
|
134
134
|
"defaults and supports es6-module",
|
|
135
135
|
"maintained node versions"
|
|
136
136
|
],
|
|
137
|
-
"gitHead": "
|
|
137
|
+
"gitHead": "2775daf617763b97ed2c3d3c6efc4e53fa61c9f1"
|
|
138
138
|
}
|