@rh-support/troubleshoot 0.2.31 → 0.2.32
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/Tabs/CaseDiscussion/CaseAttachment.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.js +1 -3
- package/lib/esm/components/CaseInformation/Severity.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/Severity.js +4 -4
- package/lib/esm/reducers/CaseHelpers.d.ts.map +1 -1
- package/lib/esm/reducers/CaseHelpers.js +6 -4
- package/package.json +9 -9
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseAttachment.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,2CAA2C,CAAC;AAaxE,OAAO,KAAuC,MAAM,OAAO,CAAC;AAQ5D,UAAU,MAAM;IACZ,UAAU,EAAE,WAAW,CAAC;IACxB,kBAAkB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC3C,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,gBAAgB,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,iBAAiB,EAAE,WAAW,KAAK,IAAI,CAAC;IACzE,eAAe,CAAC,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,IAAI,CAAC;IACjD,kBAAkB,EAAE,CAAC,EAAE,UAAU,EAAE,IAAI,EAAE,IAAI,EAAE,EAAE;QAAE,UAAU,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAC;CAChH;AAED,QAAA,MAAM,cAAc,
|
|
1
|
+
{"version":3,"file":"CaseAttachment.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,2CAA2C,CAAC;AAaxE,OAAO,KAAuC,MAAM,OAAO,CAAC;AAQ5D,UAAU,MAAM;IACZ,UAAU,EAAE,WAAW,CAAC;IACxB,kBAAkB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC3C,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,gBAAgB,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,iBAAiB,EAAE,WAAW,KAAK,IAAI,CAAC;IACzE,eAAe,CAAC,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,IAAI,CAAC;IACjD,kBAAkB,EAAE,CAAC,EAAE,UAAU,EAAE,IAAI,EAAE,IAAI,EAAE,EAAE;QAAE,UAAU,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAC;CAChH;AAED,QAAA,MAAM,cAAc,4EAgOlB,CAAC;AAEH,eAAe,cAAc,CAAC"}
|
|
@@ -34,9 +34,7 @@ const CaseAttachment = React.forwardRef((props, ref) => {
|
|
|
34
34
|
const { request: updateDescriptionRequest, isFetching: isUpdating } = useFetch(kase.updateAttachment);
|
|
35
35
|
const canEditCase = useCanEditCase();
|
|
36
36
|
const onDescriptionSave = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
37
|
-
const updatedAttachment = yield updateDescriptionRequest(props.attachment.caseNumber, props.attachment.uuid, [
|
|
38
|
-
{ path: 'description', op: 'update', value: attachmentDescription },
|
|
39
|
-
]);
|
|
37
|
+
const updatedAttachment = yield updateDescriptionRequest(props.attachment.caseNumber, props.attachment.uuid, [{ path: 'description', op: 'update', value: attachmentDescription }], loggedInUsersAccount.data.secureSupport);
|
|
40
38
|
props.onMetadataUpdate && props.onMetadataUpdate(props.attachment.uuid, updatedAttachment);
|
|
41
39
|
});
|
|
42
40
|
const onDescriptionChange = (event) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Severity.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/Severity.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AAKvE,OAAO,EAAE,gBAAgB,EAAW,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"Severity.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/Severity.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AAKvE,OAAO,EAAE,gBAAgB,EAAW,MAAM,0BAA0B,CAAC;AAsBrE,UAAU,MAAO,SAAQ,gBAAgB;IACrC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,gBAAgB,EAAE,CAAC,WAAW,EAAE,OAAO,CAAC,YAAY,CAAC,KAAK,IAAI,CAAC;IAC/D,oBAAoB,EAAE,OAAO,CAAC;CACjC;AASD,MAAM,WAAW,gBAAgB;IAC7B,QAAQ,EAAE,OAAO,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,EAAE,CAAC;CACxD;AAED,iBAAS,QAAQ,CAAC,KAAK,EAAE,MAAM,eA4N9B;kBA5NQ,QAAQ;;;AA8NjB,eAAe,QAAQ,CAAC"}
|
|
@@ -2,9 +2,9 @@ import { Popover, PopoverPosition, Tooltip, TooltipPosition } from '@patternfly/
|
|
|
2
2
|
import WarningTriangleIcon from '@patternfly/react-icons/dist/js/icons/warning-triangle-icon';
|
|
3
3
|
import { Dropdown, ValueChangedIcon } from '@rh-support/components';
|
|
4
4
|
import { GlobalMetadataStateContext } from '@rh-support/react-context';
|
|
5
|
-
import { autoEnableFtsOnCaseViewEditPage, showFtsOnCreateCasePage, toOption, toOptions } from '@rh-support/utils';
|
|
5
|
+
import { autoEnableFtsOnCaseViewEditPage, severitySort, showFtsOnCreateCasePage, toOption, toOptions, } from '@rh-support/utils';
|
|
6
|
+
import { findLast } from 'lodash';
|
|
6
7
|
import find from 'lodash/find';
|
|
7
|
-
import findLast from 'lodash/findLast';
|
|
8
8
|
import includes from 'lodash/includes';
|
|
9
9
|
import isEmpty from 'lodash/isEmpty';
|
|
10
10
|
import isEqual from 'lodash/isEqual';
|
|
@@ -23,7 +23,7 @@ const defaultProps = {
|
|
|
23
23
|
};
|
|
24
24
|
function Severity(props) {
|
|
25
25
|
const { t } = useTranslation();
|
|
26
|
-
const { product, version, caseNumber, severity, entitlementSla, ownersEntitlements, versionsDetails
|
|
26
|
+
const { product, version, caseNumber, severity, entitlementSla, ownersEntitlements, versionsDetails } = useCaseSelector((state) => ({
|
|
27
27
|
product: state.caseDetails.product,
|
|
28
28
|
version: state.caseDetails.version,
|
|
29
29
|
caseNumber: state.caseDetails.caseNumber,
|
|
@@ -128,7 +128,7 @@ function Severity(props) {
|
|
|
128
128
|
// we have no limit, we show all severity options
|
|
129
129
|
availableSeverities = (_c = allCaseSeverities.data) !== null && _c !== void 0 ? _c : [];
|
|
130
130
|
}
|
|
131
|
-
setSeveritiesOptions(availableSeverities);
|
|
131
|
+
setSeveritiesOptions(availableSeverities.sort((sevA, sevB) => severitySort(sevA, sevB)));
|
|
132
132
|
const shouldUpdateSeverityOnCaseCreate = !caseNumber && (!severity || !includes(availableSeverities, severity));
|
|
133
133
|
if (shouldUpdateSeverityOnCaseCreate) {
|
|
134
134
|
updateState(availableSeverities[0]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseHelpers.d.ts","sourceRoot":"","sources":["../../../src/reducers/CaseHelpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,qDAAqD,CAAC;AACpG,OAA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B,MAAM,gBACC,MAAM,uBACC,MAAM,yBACJ,MAAM,kBACb,MAAM,KACvB,MAuBF,CAAC;AAIF,eAAO,MAAM,oBAAoB,UACtB,MAAM,gBACC,MAAM,uBACC,MAAM,yBACJ,MAAM,KAC9B,MAQF,CAAC;AAEF,eAAO,MAAM,uBAAuB,iBAAkB,MAAM,YAAY,MAAM,KAAG,MAQhF,CAAC;AAEF,eAAO,MAAM,uBAAuB,iBAAkB,MAAM,YAAY,MAAM,KAAG,MAQhF,CAAC;AAEF,eAAO,MAAM,sBAAsB,aAAc,MAAM,KAAG,MAKzD,CAAC;AAEF,eAAO,MAAM,gBAAgB,+CAkC5B,CAAC;AAIF,eAAO,MAAM,gBAAgB,cAAe,UAAU,wBAAwB,QAAQ,eAAe,CAAC,KAAG,OA2BxG,CAAC;AAEF,eAAO,MAAM,0BAA0B,cACxB,UAAU,wBACC,QAAQ,eAAe,CAAC,KAC/C,OAiBF,CAAC;AAIF,eAAO,MAAM,6BAA6B,cAC3B,UAAU,wBACC,QAAQ,eAAe,CAAC,KAC/C,OAiBF,CAAC;AAEF,eAAO,MAAM,iBAAiB,cACf,UAAU,gBACP,YAAY,iBACZ,OAAO,KACtB,QAAQ,YAAY,CAiEtB,CAAC;AAEF,eAAO,MAAM,wBAAwB,qBAAsB,YAAY,EAAE,KAAG,YAAY,EAEvF,CAAC;AACF,eAAO,MAAM,yBAAyB,qBAAsB,YAAY,EAAE,KAAG,OAE5E,CAAC;AAEF,eAAO,MAAM,yBAAyB,gBACrB,YAAY,6BACE,MAAM,mBAChB,MAAM,KACxB,QAAQ,YAAY,CA6BtB,CAAC;AACF,eAAO,MAAM,yBAAyB,gBACrB,QAAQ,YAAY,CAAC,gCACJ,QAAQ,EAAE,KACzC,eAyCF,CAAC"}
|
|
@@ -45,6 +45,7 @@ export const getRecommendationObject = (doc, index) => {
|
|
|
45
45
|
}
|
|
46
46
|
return rec;
|
|
47
47
|
};
|
|
48
|
+
// Responsible for the order of the questions in which they appear on case details
|
|
48
49
|
export const getUpdatedDescription = (issue, environment, periodicityOfIssue, timeFramesAndUrgency, v3ClusterName) => {
|
|
49
50
|
let description = issue;
|
|
50
51
|
if (!isEmpty(environment) ||
|
|
@@ -52,6 +53,9 @@ export const getUpdatedDescription = (issue, environment, periodicityOfIssue, ti
|
|
|
52
53
|
!isEmpty(timeFramesAndUrgency) ||
|
|
53
54
|
!isEmpty(v3ClusterName)) {
|
|
54
55
|
description = `${KtQuestionConstant.issue}\n${issue}`;
|
|
56
|
+
description += !isEmpty(timeFramesAndUrgency)
|
|
57
|
+
? `\n\n${KtQuestionConstant.timeFramesAndUrgency}\n${timeFramesAndUrgency}`
|
|
58
|
+
: '';
|
|
55
59
|
description +=
|
|
56
60
|
!isEmpty(environment) || !isEmpty(v3ClusterName)
|
|
57
61
|
? `\n\n${KtQuestionConstant.environment}\n${v3ClusterName ? `OpenShift Cluster Name: ${v3ClusterName} \n` : ''}${environment}`
|
|
@@ -59,18 +63,16 @@ export const getUpdatedDescription = (issue, environment, periodicityOfIssue, ti
|
|
|
59
63
|
description += !isEmpty(periodicityOfIssue)
|
|
60
64
|
? `\n\n${KtQuestionConstant.periodicityOfIssue}\n${periodicityOfIssue}`
|
|
61
65
|
: '';
|
|
62
|
-
description += !isEmpty(timeFramesAndUrgency)
|
|
63
|
-
? `\n\n${KtQuestionConstant.timeFramesAndUrgency}\n${timeFramesAndUrgency}`
|
|
64
|
-
: '';
|
|
65
66
|
}
|
|
66
67
|
return description;
|
|
67
68
|
};
|
|
69
|
+
// Gets the descriptions without questions
|
|
68
70
|
export const getDescriptionWOQues = (issue, environment, periodicityOfIssue, timeFramesAndUrgency) => {
|
|
69
71
|
let description = issue;
|
|
70
72
|
if (!isEmpty(environment) || !isEmpty(periodicityOfIssue) || !isEmpty(timeFramesAndUrgency)) {
|
|
73
|
+
description += !isEmpty(timeFramesAndUrgency) ? ` ${timeFramesAndUrgency}` : '';
|
|
71
74
|
description += !isEmpty(environment) ? ` ${environment}` : '';
|
|
72
75
|
description += !isEmpty(periodicityOfIssue) ? ` ${periodicityOfIssue}` : '';
|
|
73
|
-
description += !isEmpty(timeFramesAndUrgency) ? ` ${timeFramesAndUrgency}` : '';
|
|
74
76
|
}
|
|
75
77
|
return description;
|
|
76
78
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/troubleshoot",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.32",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"lib/**/*"
|
|
27
27
|
],
|
|
28
28
|
"peerDependencies": {
|
|
29
|
-
"@cee-eng/hydrajs": "4.
|
|
29
|
+
"@cee-eng/hydrajs": "4.7.3",
|
|
30
30
|
"@cee-eng/ui-toolkit": "1.1.3",
|
|
31
31
|
"@patternfly/patternfly": "4.102.2",
|
|
32
32
|
"@patternfly/pfe-accordion": "1.1.0",
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"react-virtualized": "^9.21.2"
|
|
64
64
|
},
|
|
65
65
|
"dependencies": {
|
|
66
|
-
"@cee-eng/hydrajs": "4.
|
|
66
|
+
"@cee-eng/hydrajs": "4.7.3",
|
|
67
67
|
"@cee-eng/ui-toolkit": "1.1.3",
|
|
68
68
|
"@patternfly/patternfly": "4.102.2",
|
|
69
69
|
"@patternfly/pfe-accordion": "1.1.0",
|
|
@@ -72,12 +72,12 @@
|
|
|
72
72
|
"@patternfly/react-core": "4.128.2",
|
|
73
73
|
"@progress/kendo-drawing": "^1.6.0",
|
|
74
74
|
"@progress/kendo-react-pdf": "^3.12.0",
|
|
75
|
-
"@rh-support/api": "0.3.
|
|
76
|
-
"@rh-support/components": "1.1.
|
|
77
|
-
"@rh-support/react-context": "0.2.
|
|
75
|
+
"@rh-support/api": "0.3.8",
|
|
76
|
+
"@rh-support/components": "1.1.14",
|
|
77
|
+
"@rh-support/react-context": "0.2.16",
|
|
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.10",
|
|
80
|
+
"@rh-support/utils": "0.2.10",
|
|
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": "9a2829fecfe0e5755eacfb6f27b67271edb56e33"
|
|
146
146
|
}
|