Skip to content

Commit

Permalink
Merge branch 'master' into UIREQ-1046
Browse files Browse the repository at this point in the history
  • Loading branch information
artem-blazhko authored Dec 12, 2024
2 parents b66208a + 7b8b5fd commit a2e4443
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
7 changes: 6 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,15 @@

## [11.1.0] IN PROGRESS

* Migrate from `mod-circulation` to `mod-circulation-bff` for `Print pick slips` and `Print search slips`. Refs UIREQ-1154.
* 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.
* Increase code coverage for src/ViewRequest.js by Jest/RTL tests. Refs UIREQ-1046.

## [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)

* Migrate from `mod-circulation` to `mod-circulation-bff` for `Print pick slips` and `Print search slips`. Refs UIREQ-1154.

## [11.0.1] (https://github.com/folio-org/ui-requests/tree/v11.0.1) (2024-12-02)
[Full Changelog](https://github.com/folio-org/ui-requests/compare/v11.0.0...v11.0.1)

Expand Down
5 changes: 4 additions & 1 deletion src/deprecated/routes/RequestsRoute/RequestsRoute.js
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,7 @@ export const getListFormatter = (
<SinglePrintButtonForPickSlip {...singlePrintButtonProps} />);
},
'requesterBarcode': rq => (rq.requester ? rq.requester.barcode : DEFAULT_FORMATTER_VALUE),
'retrievalServicePoint': rq => get(rq, 'item.retrievalServicePointName', DEFAULT_FORMATTER_VALUE),
'requestStatus': rq => (requestStatusesTranslations[rq.status]
? <FormattedMessage id={requestStatusesTranslations[rq.status]} />
: <NoValue />),
Expand Down Expand Up @@ -334,6 +335,7 @@ class RequestsRoute extends React.Component {
'requestStatus': 'status',
'servicePoint': 'searchIndex.pickupServicePointName',
'requesterBarcode': 'requester.barcode',
'retrievalServicePoint': 'item.retrievalServicePointName',
'requestDate': 'requestDate',
'position': 'position/number',
'proxy': 'proxy',
Expand Down Expand Up @@ -1416,6 +1418,7 @@ class RequestsRoute extends React.Component {
servicePoint: <FormattedMessage id="ui-requests.requests.servicePoint" />,
requester: <FormattedMessage id="ui-requests.requests.requester" />,
requesterBarcode: <FormattedMessage id="ui-requests.requests.requesterBarcode" />,
retrievalServicePoint: <FormattedMessage id="ui-requests.requests.retrievalServicePoint" />,
singlePrint: <FormattedMessage id="ui-requests.requests.singlePrint" />,
proxy: <FormattedMessage id="ui-requests.requests.proxy" />,
...(isViewPrintDetailsEnabled && {
Expand Down Expand Up @@ -1686,7 +1689,7 @@ class RequestsRoute extends React.Component {
resultIsSelected={this.resultIsSelected}
onFilterChange={this.handleFilterChange}
sortableColumns={['requestDate', 'title', 'year', 'itemBarcode', 'callNumber', 'type', 'requestStatus',
'position', 'servicePoint', 'requester', 'requesterBarcode', 'proxy', 'copies', 'printed']}
'position', 'servicePoint', 'requester', 'requesterBarcode', 'retrievalServicePoint', 'proxy', 'copies', 'printed']}
pageAmount={100}
pagingType={MCLPagingTypes.PREV_NEXT}
/>
Expand Down
8 changes: 8 additions & 0 deletions src/deprecated/routes/RequestsRoute/RequestsRoute.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1150,6 +1150,8 @@ describe('RequestsRoute', () => {
select: 'test value',
item: {
barcode: 'itemBarcode',
retrievalServicePointId: '3a40852d-49fd-4df2-a1f9-6e2641a6e91f',
retrievalServicePointName: 'Circ Desk 1',
},
position: 'position',
proxy: {},
Expand Down Expand Up @@ -1371,6 +1373,12 @@ describe('RequestsRoute', () => {
});
});

describe('retrieval service point', () => {
it('should return retrieval service point', () => {
expect(listFormatter.retrievalServicePoint(requestWithData)).toBe(requestWithData.item.retrievalServicePointName);
});
});

describe('when formatting copies column', () => {
it('should return copies for copies column', () => {
expect(listFormatter.copies(requestWithData)).toBe(requestWithData.printDetails.printCount);
Expand Down

0 comments on commit a2e4443

Please sign in to comment.