@rh-support/manage 0.2.19 → 0.2.23
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/Groups/GroupSelect/GroupSelect.d.ts.map +1 -1
- package/lib/esm/components/Groups/GroupSelect/GroupSelect.js +2 -1
- package/lib/esm/components/Groups/ManageGroupUsers/ManageGroupUsers.d.ts.map +1 -1
- package/lib/esm/components/Groups/ManageGroupUsers/ManageGroupUsers.js +3 -2
- package/lib/esm/components/ManagePreferences/sections/PreferencesCaseCreate.d.ts.map +1 -1
- package/lib/esm/components/ManagePreferences/sections/PreferencesCaseCreate.js +14 -14
- package/lib/esm/components/NotificationEmails/NotificationEmailsModal.d.ts.map +1 -1
- package/lib/esm/components/NotificationEmails/NotificationEmailsModal.js +4 -1
- package/package.json +10 -10
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GroupSelect.d.ts","sourceRoot":"","sources":["../../../../../src/components/Groups/GroupSelect/GroupSelect.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,+CAA+C,CAAC;AA0B3E,UAAU,MAAM;IACZ,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI,KAAK,IAAI,CAAC;CAChD;AAKD,eAAO,MAAM,WAAW,UAAW,MAAM,
|
|
1
|
+
{"version":3,"file":"GroupSelect.d.ts","sourceRoot":"","sources":["../../../../../src/components/Groups/GroupSelect/GroupSelect.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,+CAA+C,CAAC;AA0B3E,UAAU,MAAM;IACZ,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI,KAAK,IAAI,CAAC;CAChD;AAKD,eAAO,MAAM,WAAW,UAAW,MAAM,gBAmbxC,CAAC"}
|
|
@@ -310,7 +310,8 @@ export const GroupSelect = (props) => {
|
|
|
310
310
|
return (React.createElement("div", { ref: manageActionsRef, className: "toolbar-left" },
|
|
311
311
|
showErrorMessage && (React.createElement(AlertMessage, { variant: AlertType.DANGER, title: t('Could not create group'), show: true })),
|
|
312
312
|
!showErrorMessage && !showInput && (React.createElement(React.Fragment, null,
|
|
313
|
-
React.createElement("label", null,
|
|
313
|
+
React.createElement("label", null,
|
|
314
|
+
React.createElement(Trans, null, "Group")),
|
|
314
315
|
React.createElement(Select, { variant: SelectVariant.typeahead, isDisabled: caseGroups.isFetching || caseGroups.isError || props.isDisabled || disableOnFetch, "aria-label": "Select a group to view accounts", onToggle: toggleIsOpen, onSelect: onSelect, onClear: onClear, noResultsFoundText: t('No results found'), selections: selectedGroup, isOpen: isOpen, "aria-labelledby": selectAGroupText, placeholderText: selectAGroupText, "data-tracking-id": "group-list-selector" }, (caseGroups.data || [])
|
|
315
316
|
.filter((g) => g.groupNum !== unGroupedCaseGroupNumber)
|
|
316
317
|
.map((data, index) => (React.createElement(SelectOption, { key: index, isSelected: data.name === selectedGroup, value: data.name }, data.name)))))),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ManageGroupUsers.d.ts","sourceRoot":"","sources":["../../../../../src/components/Groups/ManageGroupUsers/ManageGroupUsers.tsx"],"names":[],"mappings":"AAsBA,eAAO,MAAM,gBAAgB,
|
|
1
|
+
{"version":3,"file":"ManageGroupUsers.d.ts","sourceRoot":"","sources":["../../../../../src/components/Groups/ManageGroupUsers/ManageGroupUsers.tsx"],"names":[],"mappings":"AAsBA,eAAO,MAAM,gBAAgB,mBA+L5B,CAAC"}
|
|
@@ -22,7 +22,7 @@ export const ManageGroupUsers = () => {
|
|
|
22
22
|
const { globalMetadataState: { loggedInUsersAccount, loggedInUserRights }, } = useGlobalStateContext();
|
|
23
23
|
const disableGroupSelect = !loggedInUsersAccount || !loggedInUsersAccount.data || !loggedInUsersAccount.data.accountNumber;
|
|
24
24
|
const [selectedGroup, setSelectedGroup] = useState();
|
|
25
|
-
const { clearResponse, isFetching, request, data: response } = useFetch(publicApi.caseGroups.getCaseGroupUsers);
|
|
25
|
+
const { clearResponse, isFetching, request, data: response, } = useFetch(publicApi.caseGroups.getCaseGroupUsers);
|
|
26
26
|
const groupUsers = useMemo(() => response || [], [response]);
|
|
27
27
|
// errors
|
|
28
28
|
function onPermissionError(error, user) {
|
|
@@ -139,7 +139,8 @@ export const ManageGroupUsers = () => {
|
|
|
139
139
|
React.createElement("div", { className: "toolbar" },
|
|
140
140
|
React.createElement(GroupSelect, { isDisabled: isFetching || disableGroupSelect, onSelect: onGroupSelect }),
|
|
141
141
|
React.createElement("span", { className: "toolbar-right" },
|
|
142
|
-
React.createElement("label", { htmlFor: "account-group-filter" },
|
|
142
|
+
React.createElement("label", { htmlFor: "account-group-filter" },
|
|
143
|
+
React.createElement(Trans, null, "Filter by")),
|
|
143
144
|
React.createElement(Input, { id: "account-group-filter", isDisabled: isFetching || !selectedGroup, onChange: onGroupUserSearch, placeholder: t('Search for people in this group'), ariaLabel: "Group search input" }))),
|
|
144
145
|
React.createElement(ErrorBoundary, { errorMsgInfo: { message: t('There was an error loading group users list') } },
|
|
145
146
|
React.createElement(ManageTable, { ariaLabel: t('Table to manage groups'), columns: columns, data: data, sortInfo: { column: 'first-name', direction: 'asc' }, isFetching: isFetching, isError: false }))));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PreferencesCaseCreate.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/sections/PreferencesCaseCreate.tsx"],"names":[],"mappings":"AAaA,UAAU,MAAM;CAAG;AACnB,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"PreferencesCaseCreate.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/sections/PreferencesCaseCreate.tsx"],"names":[],"mappings":"AAaA,UAAU,MAAM;CAAG;AACnB,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,eA0HlD"}
|
|
@@ -34,11 +34,7 @@ export function PreferencesCaseCreate(props) {
|
|
|
34
34
|
yield updatePreferredLanguage(selectedLanguageCode);
|
|
35
35
|
});
|
|
36
36
|
const onDefaultGroupSelect = (event, selection, isPlaceholder) => __awaiter(this, void 0, void 0, function* () {
|
|
37
|
-
console.log(selection);
|
|
38
|
-
console.log('groupDictionary: ', groupDictionary);
|
|
39
|
-
console.log(groupDictionary[`${selection}`]);
|
|
40
37
|
const selectionKey = invert(groupDictionary)[selection];
|
|
41
|
-
console.log('selectionKey', selectionKey);
|
|
42
38
|
yield updateDefaultGroup(selectionKey);
|
|
43
39
|
});
|
|
44
40
|
const userOriginalPreferredLanguage = () => __awaiter(this, void 0, void 0, function* () {
|
|
@@ -64,26 +60,28 @@ export function PreferencesCaseCreate(props) {
|
|
|
64
60
|
for (let i = 0; i < caseGroups.data.length; i++) {
|
|
65
61
|
defaultGroupDictionary[caseGroups.data[i].groupNum] = caseGroups.data[i].name;
|
|
66
62
|
}
|
|
67
|
-
console.log(defaultGroupDictionary);
|
|
68
63
|
return defaultGroupDictionary;
|
|
69
64
|
};
|
|
70
|
-
|
|
71
|
-
userOriginalPreferredLanguage();
|
|
72
|
-
userOriginalDefaultGroup();
|
|
73
|
-
});
|
|
74
|
-
useEffect(() => {
|
|
65
|
+
const refreshParsedGroups = () => {
|
|
75
66
|
var _a;
|
|
76
|
-
if (!isEmpty(caseGroups) && ((_a = caseGroups === null || caseGroups === void 0 ? void 0 : caseGroups.data) === null || _a === void 0 ? void 0 : _a.length) > 0
|
|
67
|
+
if (!isEmpty(caseGroups) && ((_a = caseGroups === null || caseGroups === void 0 ? void 0 : caseGroups.data) === null || _a === void 0 ? void 0 : _a.length) > 0) {
|
|
77
68
|
let updatedDictionary = createCaseGroupStruct(caseGroups);
|
|
78
69
|
setGroupDictionary(updatedDictionary);
|
|
79
70
|
const parsedDefaultGroupNames = [];
|
|
80
71
|
for (let groupId in updatedDictionary) {
|
|
81
72
|
parsedDefaultGroupNames.push(updatedDictionary[groupId]);
|
|
82
73
|
}
|
|
83
|
-
console.log('parsedDefaultGroupNames, ', parsedDefaultGroupNames);
|
|
84
74
|
setUserDefaultGroupList(parsedDefaultGroupNames);
|
|
85
75
|
}
|
|
86
|
-
}
|
|
76
|
+
};
|
|
77
|
+
useEffect(() => {
|
|
78
|
+
userOriginalPreferredLanguage();
|
|
79
|
+
userOriginalDefaultGroup();
|
|
80
|
+
});
|
|
81
|
+
useEffect(() => {
|
|
82
|
+
refreshParsedGroups();
|
|
83
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
84
|
+
}, [caseGroups]);
|
|
87
85
|
return (React.createElement(Card, { className: "preference-card" },
|
|
88
86
|
React.createElement(CardHeader, null,
|
|
89
87
|
React.createElement("h3", null,
|
|
@@ -91,7 +89,9 @@ export function PreferencesCaseCreate(props) {
|
|
|
91
89
|
React.createElement(CardBody, null,
|
|
92
90
|
React.createElement("form", null,
|
|
93
91
|
React.createElement("div", { className: "form-group" },
|
|
94
|
-
React.createElement(PreferenceSelect, { label: "Preferred case language", id: preferredLangTitleId, onSelect: onPreferredLanguageSelect, selections: originalPreferredLanguage }, Object.keys(languageConst).map((option, index) => (React.createElement(SelectOption, { key: index, value: languageConst[option] }))))
|
|
92
|
+
React.createElement(PreferenceSelect, { label: "Preferred case language", id: preferredLangTitleId, onSelect: onPreferredLanguageSelect, selections: originalPreferredLanguage }, Object.keys(languageConst).map((option, index) => (React.createElement(SelectOption, { key: index, value: languageConst[option] })))),
|
|
93
|
+
React.createElement("p", { className: "form-instructions" },
|
|
94
|
+
React.createElement(Trans, null, "Preferred language will impact future cases, not existing ones."))),
|
|
95
95
|
React.createElement("div", { className: "form-group" },
|
|
96
96
|
React.createElement(PreferenceSelect, { label: "Default group", id: defaultGroupTitleId, onSelect: onDefaultGroupSelect, selections: originalDefaultGroup }, userDefaultGroupList.map((option, index) => (React.createElement(SelectOption, { key: index, value: option })))))))));
|
|
97
97
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationEmailsModal.d.ts","sourceRoot":"","sources":["../../../../src/components/NotificationEmails/NotificationEmailsModal.tsx"],"names":[],"mappings":"AAiBA,UAAU,MAAM;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACzE,KAAK,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACtE,yBAAyB,EAAE,GAAG,CAAC;IAC/B,aAAa,EAAE,MAAM,CAAC;IACtB,yBAAyB,EAAE,OAAO,CAAC;IACnC,UAAU,EAAE,MAAM,EAAE,CAAC;CACxB;AAED,eAAO,MAAM,uBAAuB,UAAW,MAAM,
|
|
1
|
+
{"version":3,"file":"NotificationEmailsModal.d.ts","sourceRoot":"","sources":["../../../../src/components/NotificationEmails/NotificationEmailsModal.tsx"],"names":[],"mappings":"AAiBA,UAAU,MAAM;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACzE,KAAK,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACtE,yBAAyB,EAAE,GAAG,CAAC;IAC/B,aAAa,EAAE,MAAM,CAAC;IACtB,yBAAyB,EAAE,OAAO,CAAC;IACnC,UAAU,EAAE,MAAM,EAAE,CAAC;CACxB;AAED,eAAO,MAAM,uBAAuB,UAAW,MAAM,gBA8LpD,CAAC"}
|
|
@@ -29,6 +29,7 @@ export const NotificationEmailsModal = (props) => {
|
|
|
29
29
|
const { request: addCustomEmailToAccount, isFetching: isAdding } = useFetch(customEmail.addCustomEmailToAccount, {
|
|
30
30
|
propgateErrors: true,
|
|
31
31
|
});
|
|
32
|
+
const isLoading = isAdding || isUpdating;
|
|
32
33
|
const resetModal = () => {
|
|
33
34
|
setIsValidEmail(true);
|
|
34
35
|
setIsValidFirstName(true);
|
|
@@ -65,6 +66,8 @@ export const NotificationEmailsModal = (props) => {
|
|
|
65
66
|
}
|
|
66
67
|
});
|
|
67
68
|
const close = () => {
|
|
69
|
+
if (isLoading)
|
|
70
|
+
return;
|
|
68
71
|
resetModal();
|
|
69
72
|
props.onClose();
|
|
70
73
|
};
|
|
@@ -97,7 +100,7 @@ export const NotificationEmailsModal = (props) => {
|
|
|
97
100
|
!isValidEmail ||
|
|
98
101
|
isEmailDuplicate, spinnerAriaValueText: isUpdating || isAdding ? t('Adding') : undefined, isLoading: isUpdating || isAdding },
|
|
99
102
|
React.createElement(Trans, null, "Save")),
|
|
100
|
-
React.createElement(Button, { key: "cancel", variant: ButtonVariant.secondary, onClick: close },
|
|
103
|
+
React.createElement(Button, { key: "cancel", isDisabled: isLoading, variant: ButtonVariant.secondary, onClick: close },
|
|
101
104
|
React.createElement(Trans, null, "Cancel")),
|
|
102
105
|
] },
|
|
103
106
|
React.createElement(Form, null,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/manage",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.23",
|
|
4
4
|
"description": "Customer Support Manage App",
|
|
5
5
|
"author": "Jordan Eudy <jeudy100@gmail.com>",
|
|
6
6
|
"homepage": "",
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"not op_mini all"
|
|
52
52
|
],
|
|
53
53
|
"peerDependencies": {
|
|
54
|
-
"@cee-eng/hydrajs": "4.
|
|
54
|
+
"@cee-eng/hydrajs": "4.7.3",
|
|
55
55
|
"@patternfly/patternfly": "4.102.2",
|
|
56
56
|
"@patternfly/pfe-accordion": "1.1.0",
|
|
57
57
|
"@patternfly/pfe-collapse": "1.1.0",
|
|
@@ -89,20 +89,20 @@
|
|
|
89
89
|
"typescript": "4.3.5"
|
|
90
90
|
},
|
|
91
91
|
"dependencies": {
|
|
92
|
-
"@cee-eng/hydrajs": "4.
|
|
92
|
+
"@cee-eng/hydrajs": "4.7.3",
|
|
93
93
|
"@patternfly/patternfly": "4.102.2",
|
|
94
94
|
"@patternfly/pfe-accordion": "1.1.0",
|
|
95
95
|
"@patternfly/pfe-collapse": "1.1.0",
|
|
96
96
|
"@patternfly/pfe-tabs": "1.1.0",
|
|
97
97
|
"@patternfly/react-core": "4.128.2",
|
|
98
98
|
"@patternfly/react-table": "4.26.7",
|
|
99
|
-
"@rh-support/api": "0.3.
|
|
100
|
-
"@rh-support/components": "1.1.
|
|
101
|
-
"@rh-support/configs": "0.2.
|
|
102
|
-
"@rh-support/react-context": "0.2.
|
|
99
|
+
"@rh-support/api": "0.3.8",
|
|
100
|
+
"@rh-support/components": "1.1.15",
|
|
101
|
+
"@rh-support/configs": "0.2.2",
|
|
102
|
+
"@rh-support/react-context": "0.2.17",
|
|
103
103
|
"@rh-support/types": "0.2.0",
|
|
104
|
-
"@rh-support/user-permissions": "0.2.
|
|
105
|
-
"@rh-support/utils": "0.2.
|
|
104
|
+
"@rh-support/user-permissions": "0.2.11",
|
|
105
|
+
"@rh-support/utils": "0.2.11",
|
|
106
106
|
"@types/react-beautiful-dnd": "^13.0.0",
|
|
107
107
|
"i18next": ">=17.0.1",
|
|
108
108
|
"lodash": ">=4.17.15",
|
|
@@ -113,5 +113,5 @@
|
|
|
113
113
|
"react-i18next": ">=10.11.0",
|
|
114
114
|
"react-router-dom": ">=5.1.2"
|
|
115
115
|
},
|
|
116
|
-
"gitHead": "
|
|
116
|
+
"gitHead": "3dc034eff74761ebe67f6503a13ecf5a1d763071"
|
|
117
117
|
}
|