@rh-support/troubleshoot 2.5.36 → 2.5.37
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/ActiveCustomerEscalation.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.js +1 -7
- package/lib/esm/components/CaseEditView/Tabs/RMEEscalations/RMEEscalationList.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/RMEEscalations/RMEEscalationList.js +6 -2
- package/package.json +2 -2
package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActiveCustomerEscalation.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ActiveCustomerEscalation.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.tsx"],"names":[],"mappings":"AAIA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;CACtB;AAED,eAAO,MAAM,wBAAwB,+EA6HnC,CAAC"}
|
package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.js
CHANGED
|
@@ -2,24 +2,18 @@ import { Button, ButtonVariant, List, ListItem, Popover } from '@patternfly/reac
|
|
|
2
2
|
import InfoCircleIcon from '@patternfly/react-icons/dist/js/icons/info-circle-icon';
|
|
3
3
|
import { useCanEditCase } from '@rh-support/react-context';
|
|
4
4
|
import { Can, resourceActions, resources } from '@rh-support/user-permissions';
|
|
5
|
-
import isEqual from 'lodash/isEqual';
|
|
6
5
|
import React, { forwardRef, useState } from 'react';
|
|
7
6
|
import { Trans, useTranslation } from 'react-i18next';
|
|
8
|
-
import { useCaseSelector } from '../../../context/CaseContext';
|
|
9
7
|
import { useCaseDetailsPageStateContext } from '../../../context/CaseDetailsPageContext';
|
|
10
8
|
import { RequestEscalationModal } from './RequestEscalationModal';
|
|
11
9
|
export const ActiveCustomerEscalation = forwardRef((props, ref) => {
|
|
12
10
|
const { t } = useTranslation();
|
|
13
11
|
const { caseDetailsPageState: { caseEscalations }, } = useCaseDetailsPageStateContext();
|
|
14
|
-
const { customerEscalation } = useCaseSelector((state) => ({
|
|
15
|
-
customerEscalation: state.customerEscalation,
|
|
16
|
-
}), isEqual);
|
|
17
12
|
const canEditCase = useCanEditCase();
|
|
18
13
|
const isCreateRMEVisible = (caseEscalations.data || []).length === 0 || caseEscalations.data.every((item) => item.status === 'Closed');
|
|
19
14
|
const commonElements = (React.createElement(React.Fragment, null,
|
|
20
15
|
React.createElement("p", null,
|
|
21
16
|
React.createElement(Trans, null, "After submitting, your case will be reviewed by a support manager."))));
|
|
22
|
-
const onAceBtnClick = () => window.open(`/watchlist/internal/aces/new?caseNumber=${props.caseNumber}`, '_blank', 'noopener noreferrer');
|
|
23
17
|
const isInternalElements = (React.createElement("div", { className: "card card-white card-support escalations", ref: ref },
|
|
24
18
|
React.createElement("h3", { className: "card-heading case-detail-panel-card-heading card-header-bg" },
|
|
25
19
|
React.createElement(Trans, null, "Active Customer Escalation (ACE)"),
|
|
@@ -34,7 +28,7 @@ export const ActiveCustomerEscalation = forwardRef((props, ref) => {
|
|
|
34
28
|
React.createElement(ListItem, null, t('The customer thinks the case is not moving appropriately')),
|
|
35
29
|
React.createElement(ListItem, null, t('The customer wants a new resource')),
|
|
36
30
|
React.createElement(ListItem, null, t('The issue is more severe than originally thought'))),
|
|
37
|
-
React.createElement(
|
|
31
|
+
React.createElement("a", { href: `/watchlist/internal/aces/new?caseNumber=${props.caseNumber}`, target: "_blank", rel: "noopener noreferrer", className: "pf-v5-c-button pf-m-tertiary", "data-tracking-id": "request-ace-trigger", "aria-label": t('Request an escalation') }, t('Request an escalation')))));
|
|
38
32
|
const [openRequestEscalationModal, setOpenRequestEscalationModal] = useState(false);
|
|
39
33
|
const toggleModal = () => {
|
|
40
34
|
if (canEditCase.alert())
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RMEEscalationList.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/RMEEscalations/RMEEscalationList.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAqB,MAAM,2CAA2C,CAAC;
|
|
1
|
+
{"version":3,"file":"RMEEscalationList.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/RMEEscalations/RMEEscalationList.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAqB,MAAM,2CAA2C,CAAC;AAe/F,OAAO,KAAsC,MAAM,OAAO,CAAC;AAiB3D,UAAU,MAAM;IACZ,WAAW,EAAE,eAAe,EAAE,CAAC;IAC/B,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,MAAM,CAAC;IACtB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;CACtB;AAOD,MAAM,CAAC,OAAO,UAAU,iBAAiB,CAAC,KAAK,EAAE,MAAM,qBA8MtD"}
|
|
@@ -14,9 +14,10 @@ import { ability, resourceActions, resources } from '@rh-support/user-permission
|
|
|
14
14
|
import { formatDate, sendToSentry } from '@rh-support/utils';
|
|
15
15
|
import find from 'lodash/find';
|
|
16
16
|
import isEmpty from 'lodash/isEmpty';
|
|
17
|
+
import isEqual from 'lodash/isEqual';
|
|
17
18
|
import React, { useEffect, useRef, useState } from 'react';
|
|
18
19
|
import { Trans, useTranslation } from 'react-i18next';
|
|
19
|
-
import { useCaseDispatch } from '../../../../context/CaseContext';
|
|
20
|
+
import { useCaseDispatch, useCaseSelector } from '../../../../context/CaseContext';
|
|
20
21
|
import { useCaseDetailsPageDispatchContext, useCaseDetailsPageStateContext, } from '../../../../context/CaseDetailsPageContext';
|
|
21
22
|
import { useCaseDiscussionTabDispatchContext, useCaseDiscussionTabStateContext, } from '../../../../context/CaseDiscussionTabContext';
|
|
22
23
|
import { escalationStatus } from '../../../../models/escalation';
|
|
@@ -45,6 +46,9 @@ export default function RMEEscalationList(props) {
|
|
|
45
46
|
const isUpdating = isUpdatingEscalation || isPostingComment || isUpdatingCase;
|
|
46
47
|
const [escalationList, setEscalationList] = useState([]);
|
|
47
48
|
const cannUpdateRME = ability.can(resourceActions.UPDATE, resources.RME_ESCALATION);
|
|
49
|
+
const { customerEscalation } = useCaseSelector((state) => ({
|
|
50
|
+
customerEscalation: state.customerEscalation,
|
|
51
|
+
}), isEqual);
|
|
48
52
|
useEffect(() => {
|
|
49
53
|
// hack to rerender the table to show loaders in cell
|
|
50
54
|
// called everytime we are updating the escalation
|
|
@@ -118,7 +122,7 @@ export default function RMEEscalationList(props) {
|
|
|
118
122
|
else {
|
|
119
123
|
return (React.createElement(Flex, null,
|
|
120
124
|
React.createElement(FlexItem, null,
|
|
121
|
-
React.createElement(Button, { variant: ButtonVariant.secondary, onClick: () => requestUpdateRMEEscalation(escalation.name), "data-tracking-id": "case-details-rme-req-update",
|
|
125
|
+
React.createElement(Button, { variant: ButtonVariant.secondary, onClick: () => requestUpdateRMEEscalation(escalation.name), "data-tracking-id": "case-details-rme-req-update", isDisabled: customerEscalation },
|
|
122
126
|
React.createElement(Trans, null, "Request Update"))),
|
|
123
127
|
React.createElement(FlexItem, null,
|
|
124
128
|
React.createElement(Button, { variant: ButtonVariant.secondary, className: "pf-v5-u-mt-sm", onClick: () => requestClosureRMEEscalation(escalation.name), "data-tracking-id": "case-details-rme-req-closure" },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/troubleshoot",
|
|
3
|
-
"version": "2.5.
|
|
3
|
+
"version": "2.5.37",
|
|
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": "c08734d041d891b422310c9e2bcb50da88fad809"
|
|
138
138
|
}
|