@rh-support/troubleshoot 0.2.39 → 0.2.43
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/CaseDetailsAside.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseDetailsAside.js +3 -2
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.d.ts +1 -0
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.js +3 -3
- package/lib/esm/components/Recommendations/ClusterRecommendationToast.d.ts +8 -0
- package/lib/esm/components/Recommendations/ClusterRecommendationToast.d.ts.map +1 -0
- package/lib/esm/components/Recommendations/ClusterRecommendationToast.js +10 -0
- package/lib/esm/components/Recommendations/ClusterRecommendations.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/ClusterRecommendations.js +20 -9
- package/lib/esm/components/Recommendations/Recommendations.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/Recommendations.js +6 -2
- package/lib/esm/components/wizardLayout/WizardAside.js +1 -1
- package/lib/esm/reducers/RecommendationsReducer.d.ts +1 -1
- package/lib/esm/reducers/RecommendationsReducer.d.ts.map +1 -1
- package/lib/esm/reducers/RecommendationsReducer.js +3 -2
- package/package.json +6 -6
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseDetailsAside.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseEditView/CaseDetailsAside.tsx"],"names":[],"mappings":"AAwBA,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;CACtB;AAMD,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"CaseDetailsAside.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseEditView/CaseDetailsAside.tsx"],"names":[],"mappings":"AAwBA,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;CACtB;AAMD,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,eAsL7C"}
|
|
@@ -43,7 +43,8 @@ export function CaseDetailsAside(props) {
|
|
|
43
43
|
const isXLScreen = breakPoint.xl;
|
|
44
44
|
const toggleCustomerViewRef = useRef(null);
|
|
45
45
|
const isFirstMountRef = useRef(true);
|
|
46
|
-
const { globalMetadataState: { navBarRef, viewAsCustomer }, } = useGlobalStateContext();
|
|
46
|
+
const { globalMetadataState: { navBarRef, viewAsCustomer, loggedInUsersAccount }, } = useGlobalStateContext();
|
|
47
|
+
const isSecureSupportAccount = loggedInUsersAccount.data.secureSupport;
|
|
47
48
|
const onToggleAside = (ev) => {
|
|
48
49
|
var _a;
|
|
49
50
|
toggleAside(!((_a = caseDetailsAsidePanelRef.current) === null || _a === void 0 ? void 0 : _a.expanded));
|
|
@@ -99,7 +100,7 @@ export function CaseDetailsAside(props) {
|
|
|
99
100
|
React.createElement("span", { className: "customer-view-switch-label" }, viewAsCustomer ? t('Customer view') : t('Internal view')),
|
|
100
101
|
React.createElement(Switch, { title: viewAsCustomer ? t('Customer view') : t('Internal view'), "data-tracking-id": viewAsCustomer ? 'disable-view-as-customer' : 'enable-view-as-customer', "aria-label": viewAsCustomer ? 'disable view as customer' : 'enable view as customer', id: "customer-view-switch", className: "pf-u-ml-auto", isChecked: viewAsCustomer, onChange: () => toggleViewAsCustomerFlag(globalMetadataDispatchContext) }))),
|
|
101
102
|
React.createElement(ErrorBoundary, { errorMsgInfo: { message: t('There was an error loading top solutions') } },
|
|
102
|
-
React.createElement(CaseSolutions, { caseNumber: caseNumber, ref: topSolutionsRef })),
|
|
103
|
+
React.createElement(CaseSolutions, { caseNumber: caseNumber, ref: topSolutionsRef, isSecureSupportAccount: isSecureSupportAccount })),
|
|
103
104
|
!caseEscalations.isFetching && canViewACESection && (React.createElement(ErrorBoundary, null,
|
|
104
105
|
React.createElement(ActiveCustomerEscalation, { caseNumber: caseNumber, caseSeverity: severity, caseStatus: status, ref: createEscalationRef })))))));
|
|
105
106
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseSolutions.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseSolutions/CaseSolutions.tsx"],"names":[],"mappings":"AAUA,OAAO,KAAsD,MAAM,OAAO,CAAC;AA8D3E,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"CaseSolutions.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseSolutions/CaseSolutions.tsx"],"names":[],"mappings":"AAUA,OAAO,KAAsD,MAAM,OAAO,CAAC;AA8D3E,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,sBAAsB,EAAE,OAAO,CAAC;CACnC;AAUD,eAAO,MAAM,aAAa,+EAmYxB,CAAC"}
|
|
@@ -90,7 +90,7 @@ export const CaseSolutions = forwardRef((props, ref) => {
|
|
|
90
90
|
const caseDispatch = useCaseDispatch();
|
|
91
91
|
const { recommendationState: { isLoadingRecommendations, allDocs }, } = useRecommendationStateContext();
|
|
92
92
|
const recommendationsDispatch = useRecommendationDispatchContext();
|
|
93
|
-
const { caseNumber } = props;
|
|
93
|
+
const { caseNumber, isSecureSupportAccount } = props;
|
|
94
94
|
const [isPinLoading, setIsPinLoading] = useState({});
|
|
95
95
|
const [expanded, setExpanded] = useState('sol-handpicked');
|
|
96
96
|
const [recommendations, setRecommendations] = useState([]);
|
|
@@ -169,11 +169,11 @@ export const CaseSolutions = forwardRef((props, ref) => {
|
|
|
169
169
|
function fetchRecs() {
|
|
170
170
|
if (product && version && summary && description) {
|
|
171
171
|
const payload = { product, version, summary, description };
|
|
172
|
-
fetchRecommendations(recommendationsDispatch, payload, 50, 5, 300);
|
|
172
|
+
fetchRecommendations(recommendationsDispatch, payload, 50, 5, 300, false, caseNumber, isSecureSupportAccount);
|
|
173
173
|
}
|
|
174
174
|
}
|
|
175
175
|
fetchRecs();
|
|
176
|
-
}, [product, version, summary, description, recommendationsDispatch]);
|
|
176
|
+
}, [product, version, summary, description, recommendationsDispatch, caseNumber, isSecureSupportAccount]);
|
|
177
177
|
// populate solutions when result is ready
|
|
178
178
|
useEffect(() => {
|
|
179
179
|
const mapRecommendation = (doc) => {
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
interface IProps {
|
|
3
|
+
onViewRecommendations: () => void;
|
|
4
|
+
onToastClose: () => void;
|
|
5
|
+
}
|
|
6
|
+
declare const ClusterRecommendationToast: FC<IProps>;
|
|
7
|
+
export default ClusterRecommendationToast;
|
|
8
|
+
//# sourceMappingURL=ClusterRecommendationToast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ClusterRecommendationToast.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/ClusterRecommendationToast.tsx"],"names":[],"mappings":"AACA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAGlC,UAAU,MAAM;IACZ,qBAAqB,EAAE,MAAM,IAAI,CAAC;IAClC,YAAY,EAAE,MAAM,IAAI,CAAC;CAC5B;AAED,QAAA,MAAM,0BAA0B,EAAE,EAAE,CAAC,MAAM,CAkB1C,CAAC;AAEF,eAAe,0BAA0B,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Alert, AlertActionCloseButton, AlertGroup, Button } from '@patternfly/react-core';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { Trans, useTranslation } from 'react-i18next';
|
|
4
|
+
const ClusterRecommendationToast = ({ onViewRecommendations, onToastClose }) => {
|
|
5
|
+
const { t } = useTranslation();
|
|
6
|
+
return (React.createElement(AlertGroup, { isToast: true },
|
|
7
|
+
React.createElement(Alert, { isLiveRegion: true, variant: "success", title: t('Cluster recommendation has been triggered'), "data-tracking-id": "toast-view-cluster-sol", actionLinks: React.createElement(Button, { isInline: true, variant: "link", onClick: onViewRecommendations },
|
|
8
|
+
React.createElement(Trans, null, "View recommendations")), actionClose: React.createElement(AlertActionCloseButton, { variantLabel: "success alert", onClose: onToastClose }) })));
|
|
9
|
+
};
|
|
10
|
+
export default ClusterRecommendationToast;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClusterRecommendations.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/ClusterRecommendations.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ClusterRecommendations.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/ClusterRecommendations.tsx"],"names":[],"mappings":"AASA,MAAM,CAAC,OAAO,UAAU,qBAAqB,gBAkD5C"}
|
|
@@ -1,24 +1,35 @@
|
|
|
1
1
|
import { Button } from '@patternfly/react-core';
|
|
2
|
-
import React, { useContext, useState } from 'react';
|
|
2
|
+
import React, { useContext, useEffect, useState } from 'react';
|
|
3
3
|
import { Trans } from 'react-i18next';
|
|
4
4
|
import { ClusterRecommendationsContext } from '../../context/ClusterRecommendationsContext';
|
|
5
5
|
import { ClusterRecommendationItems } from './ClusterRecommendationItems';
|
|
6
6
|
import { ClusterRecommendationsModal } from './ClusterRecommendationsModal';
|
|
7
|
+
import ClusterRecommendationToast from './ClusterRecommendationToast';
|
|
7
8
|
export default function ClusteRecommendations() {
|
|
8
9
|
const { clusterRecommendations } = useContext(ClusterRecommendationsContext);
|
|
9
10
|
const [showModal, setShowModal] = useState(false);
|
|
11
|
+
const [isToastVisible, setToastVisibility] = useState(false);
|
|
12
|
+
const onViewRecommendations = () => {
|
|
13
|
+
setToastVisibility(false);
|
|
14
|
+
setShowModal(true);
|
|
15
|
+
};
|
|
16
|
+
useEffect(() => {
|
|
17
|
+
setToastVisibility(true);
|
|
18
|
+
}, [clusterRecommendations.data]);
|
|
10
19
|
const NUMBER_OF_RULES_TO_DISPLAY = 3;
|
|
11
20
|
const onModalClose = () => {
|
|
12
21
|
setShowModal(false);
|
|
13
22
|
};
|
|
14
23
|
if (clusterRecommendations.data.length === 0 || clusterRecommendations.isError || clusterRecommendations.isFetching)
|
|
15
24
|
return React.createElement(React.Fragment, null);
|
|
16
|
-
return (React.createElement(
|
|
17
|
-
React.createElement(
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
React.createElement(
|
|
23
|
-
|
|
25
|
+
return (React.createElement(React.Fragment, null,
|
|
26
|
+
isToastVisible && (React.createElement(ClusterRecommendationToast, { onViewRecommendations: onViewRecommendations, onToastClose: () => setToastVisibility(false) })),
|
|
27
|
+
React.createElement("div", { className: "card card-white card-support top-recommendations" },
|
|
28
|
+
React.createElement("h3", { className: "card-heading" },
|
|
29
|
+
React.createElement(Trans, null, "Cluster recommendations")),
|
|
30
|
+
React.createElement("div", null,
|
|
31
|
+
React.createElement(ClusterRecommendationItems, { clusterRecommendations: clusterRecommendations.data.slice(0, NUMBER_OF_RULES_TO_DISPLAY) }),
|
|
32
|
+
clusterRecommendations.data.length > NUMBER_OF_RULES_TO_DISPLAY && (React.createElement(Button, { className: "pf-u-p-md", variant: "link", isBlock: true, onClick: () => setShowModal(true) },
|
|
33
|
+
React.createElement(Trans, null, "View more recommendations"))),
|
|
34
|
+
React.createElement(ClusterRecommendationsModal, { clusterRecommendations: clusterRecommendations.data, isOpen: showModal, onModalClose: onModalClose })))));
|
|
24
35
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Recommendations.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/Recommendations.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Recommendations.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/Recommendations.tsx"],"names":[],"mappings":"AA0CA,MAAM,CAAC,OAAO,UAAU,eAAe,gBAyNtC"}
|
|
@@ -9,6 +9,7 @@ import isEqual from 'lodash/isEqual';
|
|
|
9
9
|
import map from 'lodash/map';
|
|
10
10
|
import React, { useContext, useEffect, useRef, useState } from 'react';
|
|
11
11
|
import { Trans } from 'react-i18next';
|
|
12
|
+
import { useParams } from 'react-router-dom';
|
|
12
13
|
import { useCaseDispatch, useCaseSelector } from '../../context/CaseContext';
|
|
13
14
|
import { RecommendationDispatchContext, RecommendationStateContext } from '../../context/RecommendationContext';
|
|
14
15
|
import { RouteContext } from '../../context/RouteContext';
|
|
@@ -32,7 +33,10 @@ export default function Recommendations() {
|
|
|
32
33
|
caseResourceLinks: state.caseDetails.caseResourceLinks,
|
|
33
34
|
}), isEqual);
|
|
34
35
|
const caseDispatch = useCaseDispatch();
|
|
35
|
-
|
|
36
|
+
// Use Case Number
|
|
37
|
+
const { caseNumber } = useParams();
|
|
38
|
+
const { globalMetadataState: { navBarRef, loggedInUsersAccount }, } = useGlobalStateContext();
|
|
39
|
+
const isSecureSupportAccount = loggedInUsersAccount.data.secureSupport;
|
|
36
40
|
const { routeState: { activeSection }, } = useContext(RouteContext);
|
|
37
41
|
const { sessionRestore: { activeSessionId, sessionResourceTracking }, } = useContext(SessionRestoreStateContext);
|
|
38
42
|
const sessionRestoreDispatch = useContext(SessionRestoreDispatchContext);
|
|
@@ -77,7 +81,7 @@ export default function Recommendations() {
|
|
|
77
81
|
// recreate a new AbortController for each call
|
|
78
82
|
let controller = new AbortController();
|
|
79
83
|
abortControllerRef.current = controller;
|
|
80
|
-
fetchRecommendations(recommendationDispatch, payload, MAXROW, recPageSize, 0, true, queryFilters, controller.signal);
|
|
84
|
+
fetchRecommendations(recommendationDispatch, payload, MAXROW, recPageSize, 0, true, caseNumber, isSecureSupportAccount, queryFilters, controller.signal);
|
|
81
85
|
}, [
|
|
82
86
|
activeSection,
|
|
83
87
|
environment,
|
|
@@ -36,8 +36,8 @@ function WizardAside(props) {
|
|
|
36
36
|
return (React.createElement("aside", { className: "grid-aside" },
|
|
37
37
|
React.createElement("section", { className: "grid-aside-content" },
|
|
38
38
|
canshowEARuleWidget && React.createElement(EARuleWidget, null),
|
|
39
|
-
canShowClusterIdWidgets && React.createElement(ClusterRecommendations, null),
|
|
40
39
|
React.createElement(InsightsResults, null),
|
|
40
|
+
canShowClusterIdWidgets && React.createElement(ClusterRecommendations, null),
|
|
41
41
|
canUseSessionManagement && React.createElement(SessionRestore, { routeProps: props.routeProps }),
|
|
42
42
|
React.createElement(AsideResults, null),
|
|
43
43
|
canShowFileUploadWidget() && React.createElement(FileDiag, null))));
|
|
@@ -31,7 +31,7 @@ export declare enum RecommendationsConstants {
|
|
|
31
31
|
resetRecommendations = "resetRecommendations"
|
|
32
32
|
}
|
|
33
33
|
export declare const recommandationsReducer: (state: IRecommendationsState, action: IActionType) => IRecommendationsState;
|
|
34
|
-
export declare const fetchRecommendations: (dispatch: RecommendationsReducerDispatchType, body: IRecommendationsPayload, max_rows: number, page_size: number, highlighted_fragment_size: number, seQueryFields
|
|
34
|
+
export declare const fetchRecommendations: (dispatch: RecommendationsReducerDispatchType, body: IRecommendationsPayload, max_rows: number, page_size: number, highlighted_fragment_size: number, seQueryFields: boolean, caseNumber: string, isSecureSupportAccount: boolean, additionalFilters?: IRecommendationAdditionalFilters, abortSignal?: AbortSignal) => Promise<void>;
|
|
35
35
|
export declare const setVisibleDocs: (dispatch: RecommendationsReducerDispatchType, visDocs: ISolrRecommendation[]) => void;
|
|
36
36
|
export declare const setCurrentPage: (dispatch: RecommendationsReducerDispatchType, pageNum: number) => void;
|
|
37
37
|
export declare const setInsighResultsKcsIds: (dispatch: RecommendationsReducerDispatchType, insightsKcsIds: string[]) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RecommendationsReducer.d.ts","sourceRoot":"","sources":["../../../src/reducers/RecommendationsReducer.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,uBAAuB,EAAoB,MAAM,oCAAoC,CAAC;AAC/F,OAAO,EAAE,YAAY,EAAE,mBAAmB,EAAiB,MAAM,0CAA0C,CAAC;AAC5G,OAAO,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAC;AACnD,OAAO,EAAiB,gCAAgC,EAA2B,MAAM,mBAAmB,CAAC;A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,WAAW,kBAkC5B,CAAC;AAEF,eAAO,MAAM,cAAc,aAAc,kCAAkC,WAAW,mBAAmB,EAAE,SAE1G,CAAC;AAEF,eAAO,MAAM,cAAc,aAAc,kCAAkC,WAAW,MAAM,SAE3F,CAAC;AAEF,eAAO,MAAM,sBAAsB,aAAc,kCAAkC,kBAAkB,MAAM,EAAE,SAE5G,CAAC;AAEF,eAAO,MAAM,oBAAoB,aAAc,kCAAkC,SAEhF,CAAC"}
|
|
@@ -74,7 +74,7 @@ export const recommandationsReducer = (state, action) => {
|
|
|
74
74
|
}
|
|
75
75
|
};
|
|
76
76
|
// Actions
|
|
77
|
-
export const fetchRecommendations = (dispatch, body, max_rows, page_size, highlighted_fragment_size, seQueryFields = false, additionalFilters, abortSignal) => __awaiter(void 0, void 0, void 0, function* () {
|
|
77
|
+
export const fetchRecommendations = (dispatch, body, max_rows, page_size, highlighted_fragment_size, seQueryFields = false, caseNumber, isSecureSupportAccount, additionalFilters, abortSignal) => __awaiter(void 0, void 0, void 0, function* () {
|
|
78
78
|
dispatch({
|
|
79
79
|
type: RecommendationsConstants.requestRecommendations,
|
|
80
80
|
payload: { prevRecommendationsBody: Object.assign({}, body) },
|
|
@@ -85,7 +85,8 @@ export const fetchRecommendations = (dispatch, body, max_rows, page_size, highli
|
|
|
85
85
|
body.description = body.description && body.description.replace(/\?\?/g, '');
|
|
86
86
|
}
|
|
87
87
|
const searchParams = getSolrParams(max_rows, highlighted_fragment_size, additionalFilters, seQueryFields);
|
|
88
|
-
const response = yield search.getRecommendationsForCase(body, searchParams,
|
|
88
|
+
const response = yield search.getRecommendationsForCase(body, Object.assign(Object.assign({}, searchParams), { caseNumber, isSecureSupportAccount }), // Need to pass caseNumber and isSecureSupportAccount flag with SOLR parameter which will be used in service worker strategy.
|
|
89
|
+
abortSignal);
|
|
89
90
|
const docs = replaceHighlightingData(response.response.docs, response.highlighting);
|
|
90
91
|
dispatch({
|
|
91
92
|
type: RecommendationsConstants.receivedRecommendations,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/troubleshoot",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.43",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -73,11 +73,11 @@
|
|
|
73
73
|
"@progress/kendo-drawing": "^1.6.0",
|
|
74
74
|
"@progress/kendo-react-pdf": "^3.12.0",
|
|
75
75
|
"@rh-support/api": "0.3.9",
|
|
76
|
-
"@rh-support/components": "1.1.
|
|
77
|
-
"@rh-support/react-context": "0.2.
|
|
76
|
+
"@rh-support/components": "1.1.21",
|
|
77
|
+
"@rh-support/react-context": "0.2.23",
|
|
78
78
|
"@rh-support/types": "0.2.0",
|
|
79
|
-
"@rh-support/user-permissions": "0.2.
|
|
80
|
-
"@rh-support/utils": "0.2.
|
|
79
|
+
"@rh-support/user-permissions": "0.2.16",
|
|
80
|
+
"@rh-support/utils": "0.2.14",
|
|
81
81
|
"@types/react-redux": "^7.1.12",
|
|
82
82
|
"@types/redux": "^3.6.0",
|
|
83
83
|
"@webcomponents/webcomponentsjs": "^2.2.10",
|
|
@@ -142,5 +142,5 @@
|
|
|
142
142
|
"not ie <= 11",
|
|
143
143
|
"not op_mini all"
|
|
144
144
|
],
|
|
145
|
-
"gitHead": "
|
|
145
|
+
"gitHead": "f16c3e016d3cfc56fa94f1cb1a8f8ab2d3fe0a35"
|
|
146
146
|
}
|