From c3817452eaab5df3f2a626ce67fc494d69718b89 Mon Sep 17 00:00:00 2001 From: Priyanka Terala Date: Fri, 13 Dec 2024 17:53:24 +0530 Subject: [PATCH] UIU-1191 - Include `Retrieval service point` column in csv exports. --- CHANGELOG.md | 1 + src/constants.js | 2 ++ src/routes/RequestsRoute.js | 3 +++ translations/ui-requests/en.json | 1 + 4 files changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 49016346..05fb70c8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ * Add optional column "Retrieval service point" to requests search list. Refs UIREQ-1188. * Increase code coverage for src/ChooseRequestTypeDialog.js by Jest/RTL tests. Refs UIREQ-1044. * Cleanup retrieval service point implementation from deprecated folder. Refs UIREQ-1211. +* Include `Retrieval service point` column in csv exports. Refs UIREQ-1191. ## [11.0.2] (https://github.com/folio-org/ui-requests/tree/v11.0.2) (2024-12-10) [Full Changelog](https://github.com/folio-org/ui-requests/compare/v11.0.1...v11.0.2) diff --git a/src/constants.js b/src/constants.js index 225b174b..5ee53821 100644 --- a/src/constants.js +++ b/src/constants.js @@ -187,6 +187,7 @@ export const reportHeaders = [ 'holdShelfExpirationDate', 'position', 'item.barcode', + 'item.retrievalServicePointName', 'instance.title', 'instance.contributorNames', 'item.location.libraryName', @@ -219,6 +220,7 @@ export const reportHeaders = [ export const expiredHoldsReportHeaders = [ 'requester.name', 'requester.barcode', + 'item.retrievalServicePointName', 'instance.title', 'item.barcode', 'item.callNumberComponents.prefix', diff --git a/src/routes/RequestsRoute.js b/src/routes/RequestsRoute.js index e335ba15..d46829b1 100644 --- a/src/routes/RequestsRoute.js +++ b/src/routes/RequestsRoute.js @@ -1002,6 +1002,9 @@ class RequestsRoute extends React.Component { const { addressLine1, city, region, postalCode, countryId } = record.deliveryAddress; record.deliveryAddress = `${addressLine1 || ''} ${city || ''} ${region || ''} ${countryId || ''} ${postalCode || ''}`; } + if (record.item.retrievalServicePointName) { + record.retrievalServicePointName = record.item.retrievalServicePointName; + } record.instance.contributorNames = contributorNamesMap.join('; '); if (record.tags) record.tags.tagList = tagListMap.join('; '); }); diff --git a/translations/ui-requests/en.json b/translations/ui-requests/en.json index 19923c7a..7fb5ecc2 100644 --- a/translations/ui-requests/en.json +++ b/translations/ui-requests/en.json @@ -198,6 +198,7 @@ "deliveryAddress": "Delivery address", "requester.pickupLocation": "Pickup location", "pickupServicePoint.name": "Pickup service point", + "item.retrievalServicePointName": "Retrieval service point", "requester.patronGroup.group": "Requester patron group", "tags.tagList": "Tags", "printDetails.printCount": "# Copies",