diff --git a/src/deprecated/routes/RequestsRoute/RequestsRoute.js b/src/deprecated/routes/RequestsRoute/RequestsRoute.js
index c9f2faad..462eed1c 100644
--- a/src/deprecated/routes/RequestsRoute/RequestsRoute.js
+++ b/src/deprecated/routes/RequestsRoute/RequestsRoute.js
@@ -29,7 +29,6 @@ import {
Checkbox,
filters2cql,
FormattedTime,
- MenuSection,
TextLink,
DefaultMCLRowFormatter,
NoValue,
@@ -1460,121 +1459,120 @@ class RequestsRoute extends React.Component {
const actionMenu = ({ onToggle, renderColumnsMenu }) => (
<>
-
-
-
-
- {csvReportPending ?
+
+
+
+ {csvReportPending ?
+
+
+ :
+
+ }
+ {
+ isPickSlipsArePending ?
-
+
:
-
- }
- {
- isPickSlipsArePending ?
-
-
- :
- <>
-
- this.onBeforeGetContentForPrintButton(onToggle)}
- onBeforePrint={async () => {
+ // without the timeout the printing process starts right away
+ // and the callout and onToggle above are blocked
+ setTimeout(() => resolve(), 1000);
+ multiSelectPickSlipData = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
+ })
+ }
+ onBeforePrint={
+ async () => {
if (isViewPrintDetailsEnabled) {
- const requestIds = extractPickSlipRequestIds(pickSlipsData);
- await this.savePrintEventDetails(requestIds);
- }
- }}
- onAfterPrint={this.onAfterPrintForPrintButton}
- >
-
-
-
-
- new Promise(resolve => {
- this.context.sendCallout({ message: });
- onToggle();
- // without the timeout the printing process starts right away
- // and the callout and onToggle above are blocked
- setTimeout(() => resolve(), 1000);
- multiSelectPickSlipData = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
- })
- }
- onBeforePrint={
- async () => {
- if (isViewPrintDetailsEnabled) {
- const selectedPickSlips = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
- const selectedRequestIds = extractPickSlipRequestIds(selectedPickSlips);
- await this.savePrintEventDetails(selectedRequestIds);
- }
+ const selectedPickSlips = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
+ const selectedRequestIds = extractPickSlipRequestIds(selectedPickSlips);
+ await this.savePrintEventDetails(selectedRequestIds);
}
}
- onAfterPrint={this.onAfterPrintForPrintButton}
- >
-
-
-
-
- >
- }
- {
- isPrintHoldRequestsEnabled &&
+ }
+ onAfterPrint={this.onAfterPrintForPrintButton}
+ >
+
+
+
+
+ >
+ }
+ {
+ isPrintHoldRequestsEnabled &&
<>
{
isSearchSlipsArePending ?
@@ -1591,15 +1589,14 @@ class RequestsRoute extends React.Component {
>
}
>
- }
-
+ }
{renderColumnsMenu}
>
);
diff --git a/src/deprecated/routes/RequestsRoute/RequestsRoute.test.js b/src/deprecated/routes/RequestsRoute/RequestsRoute.test.js
index 51834545..df22b37b 100644
--- a/src/deprecated/routes/RequestsRoute/RequestsRoute.test.js
+++ b/src/deprecated/routes/RequestsRoute/RequestsRoute.test.js
@@ -220,8 +220,8 @@ const request = {
const labelIds = {
closedCancelledRequest: requestStatusesTranslations[requestStatuses.CANCELLED],
requestType: requestTypesTranslations[requestTypesMap.RECALL],
- printPickSlips: 'ui-requests.printPickSlips',
- printSearchSlips: 'ui-requests.printSearchSlips',
+ printPickSlips: 'ui-requests.printPickSlipsForSp',
+ printSearchSlips: 'ui-requests.printSearchSlipsForSp',
titleWithSearch: 'ui-requests.documentTitle.search',
defaultTitle: 'ui-requests.meta.title',
recordsSelected: 'ui-requests.rows.recordsSelected',
@@ -611,7 +611,7 @@ describe('RequestsRoute', () => {
});
it('should trigger "exportCsv"', async () => {
- await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsToCsv' }));
+ await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsCsv' }));
await waitFor(() => {
expect(exportCsv).toHaveBeenCalled();
@@ -820,7 +820,7 @@ describe('RequestsRoute', () => {
it('should trigger "exportCsv"', async () => {
renderComponent(getPropsWithSortInQuery());
- await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsToCsv' }));
+ await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsCsv' }));
await waitFor(() => {
expect(exportCsv).toHaveBeenCalled();
diff --git a/src/routes/RequestsRoute.js b/src/routes/RequestsRoute.js
index f4a3515d..beadb785 100644
--- a/src/routes/RequestsRoute.js
+++ b/src/routes/RequestsRoute.js
@@ -31,7 +31,6 @@ import {
Checkbox,
filters2cql,
FormattedTime,
- MenuSection,
TextLink,
DefaultMCLRowFormatter,
NoValue,
@@ -1541,19 +1540,18 @@ class RequestsRoute extends React.Component {
const actionMenu = ({ onToggle, renderColumnsMenu }) => (
<>
-
-
-
-
+
+
+
{csvReportPending ?
@@ -1569,93 +1567,93 @@ class RequestsRoute extends React.Component {
}}
>
-
+
}
- {
- isPickSlipsArePending ?
-
-
- :
- <>
-
- this.onBeforeGetContentForPrintButton(onToggle)}
- onBeforePrint={async () => {
+ // without the timeout the printing process starts right away
+ // and the callout and onToggle above are blocked
+ setTimeout(() => resolve(), 1000);
+ multiSelectPickSlipData = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
+ })
+ }
+ onBeforePrint={
+ async () => {
if (isViewPrintDetailsEnabled) {
- const requestIds = extractPickSlipRequestIds(pickSlipsData);
- await this.savePrintEventDetails(requestIds);
- }
- }}
- onAfterPrint={this.onAfterPrintForPrintButton}
- >
-
-
-
-
- new Promise(resolve => {
- this.context.sendCallout({ message: });
- onToggle();
- // without the timeout the printing process starts right away
- // and the callout and onToggle above are blocked
- setTimeout(() => resolve(), 1000);
- multiSelectPickSlipData = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
- })
- }
- onBeforePrint={
- async () => {
- if (isViewPrintDetailsEnabled) {
- const selectedPickSlips = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
- const selectedRequestIds = extractPickSlipRequestIds(selectedPickSlips);
- await this.savePrintEventDetails(selectedRequestIds);
- }
+ const selectedPickSlips = getSelectedSlipDataMulti(pickSlipsData, selectedRows);
+ const selectedRequestIds = extractPickSlipRequestIds(selectedPickSlips);
+ await this.savePrintEventDetails(selectedRequestIds);
}
}
- onAfterPrint={this.onAfterPrintForPrintButton}
- >
-
-
-
-
- >
- }
- {
- isPrintHoldRequestsEnabled &&
+ }
+ onAfterPrint={this.onAfterPrintForPrintButton}
+ >
+
+
+
+
+ >
+ }
+ {
+ isPrintHoldRequestsEnabled &&
<>
{
isSearchSlipsArePending ?
@@ -1672,15 +1670,14 @@ class RequestsRoute extends React.Component {
>
}
>
- }
-
+ }
{renderColumnsMenu}
>
);
diff --git a/src/routes/RequestsRoute.test.js b/src/routes/RequestsRoute.test.js
index c85beafd..bfa70970 100644
--- a/src/routes/RequestsRoute.test.js
+++ b/src/routes/RequestsRoute.test.js
@@ -222,8 +222,8 @@ const request = {
const labelIds = {
closedCancelledRequest: requestStatusesTranslations[requestStatuses.CANCELLED],
requestType: requestTypesTranslations[requestTypesMap.RECALL],
- printPickSlips: 'ui-requests.printPickSlips',
- printSearchSlips: 'ui-requests.printSearchSlips',
+ printPickSlips: 'ui-requests.printPickSlipsForSp',
+ printSearchSlips: 'ui-requests.printSearchSlipsForSp',
titleWithSearch: 'ui-requests.documentTitle.search',
defaultTitle: 'ui-requests.meta.title',
recordsSelected: 'ui-requests.rows.recordsSelected',
@@ -635,7 +635,7 @@ describe('RequestsRoute', () => {
});
it("should trigger 'exportCsv'", async () => {
- await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsToCsv' }));
+ await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsCsv' }));
await waitFor(() => {
expect(exportCsv).toHaveBeenCalled();
@@ -976,7 +976,7 @@ describe('RequestsRoute', () => {
it('should trigger "exportCsv"', async () => {
renderComponent(getPropsWithSortInQuery());
- await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsToCsv' }));
+ await userEvent.click(screen.getByRole('button', { name: 'ui-requests.exportSearchResultsCsv' }));
await waitFor(() => {
expect(exportCsv).toHaveBeenCalled();
diff --git a/translations/ui-requests/en.json b/translations/ui-requests/en.json
index 7fb5ecc2..3d23a206 100644
--- a/translations/ui-requests/en.json
+++ b/translations/ui-requests/en.json
@@ -109,7 +109,6 @@
"errors.movingRequestToTheSameItem": "Not allowed to move title level page request to the same item",
"errors.itemOfThisInstanceAlreadyRequested": "This requester already has an open request for one of the instance's items",
- "actions.label": "Actions",
"actions.edit": "Edit",
"actions.editRequestLink": "Edit Request Dialog",
"actions.closeNewRequest": "Close New Request",
@@ -244,8 +243,8 @@
"duplicateRequest.success": "Request has been successfully created for {requester}",
"duplicateRequest.fail": "This request was not placed successfully",
- "exportExpiredHoldShelfToCsv": "Export hold shelf clearance report for {currentServicePoint}",
- "exportSearchResultsToCsv": "Export search results to CSV",
+ "exportExpiredHoldShelfCsv": "Hold shelf clearance report {currentServicePoint} (CSV)",
+ "exportSearchResultsCsv": "Export search results (CSV)",
"noServicePoint.errorMessage": "You must be logged into a service point to access the Hold shelf clearance report. Please add one or more service points to your user record in the Users app. Contact an administrator if you do not have the ability to add service points to your record.",
"noServicePoint.label": "No service point selected",
@@ -282,9 +281,9 @@
"requestQueue.notYetFilledRequests.noData": "No requests found",
"cancellationReason": "Cancellation reason",
"cancellationAdditionalInformation": "Additional information for patron",
- "printPickSlips": "Print pick slips for {sp}",
- "printSearchSlips": "Print search slips for {sp}",
- "printPickSlipsSelected": "Print selected pick slips for {sp}",
+ "printPickSlipsForSp": "Print pick slips {sp}",
+ "printSearchSlipsForSp": "Print search slips {sp}",
+ "printSelectedPickSlipsForSp": "Print selected pick slips {sp}",
"common.cancel": "Cancel",