diff --git a/src/lib/config/defaultConfig.js b/src/lib/config/defaultConfig.js index 4f660eb5e..a2feb12b7 100644 --- a/src/lib/config/defaultConfig.js +++ b/src/lib/config/defaultConfig.js @@ -431,6 +431,9 @@ export const RECORDS_CONFIG = { loanMaxDuration: 180, statuses: ILL_BORROWING_REQUESTS_STATUSES, defaultType: 'PHYSICAL_COPY', + fieldOverrides: { + due_date: 'Due Date', + }, search: { filters: [ { diff --git a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestMetadata.js b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestMetadata.js index 9caf1bf5f..5bef32bf5 100644 --- a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestMetadata.js +++ b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestMetadata.js @@ -48,7 +48,7 @@ class Loan extends React.Component { value: this.dateOrDefault(brwReqMetadata.received_date), }, { - name: 'Due date', + name: invenioConfig.ILL_BORROWING_REQUESTS.fieldOverrides.due_date, value: this.dateOrDefault(brwReqMetadata.due_date), }, { diff --git a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestStatistics.js b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestStatistics.js index 112a9f104..8bab23cdd 100644 --- a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestStatistics.js +++ b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestDetails/BorrowingRequestStatistics.js @@ -1,4 +1,4 @@ -import { getDisplayVal } from '@config'; +import { getDisplayVal, invenioConfig } from '@config'; import PropTypes from 'prop-types'; import React from 'react'; import { Statistic } from 'semantic-ui-react'; @@ -50,9 +50,10 @@ export class BorrowingRequestStatistics extends React.Component { const { brwReq: { due_date: dueDate }, } = this.props; + const title = invenioConfig.ILL_BORROWING_REQUESTS.fieldOverrides.due_date; return ( - Due date + {title} {dueDate ? dueDate : '-'} ); diff --git a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestEditor/schema.js b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestEditor/schema.js index 71c40a007..f3e950f2e 100644 --- a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestEditor/schema.js +++ b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestEditor/schema.js @@ -89,7 +89,7 @@ export const schema = () => { }, due_date: { format: 'date', - title: 'Due date', + title: invenioConfig.ILL_BORROWING_REQUESTS.fieldOverrides.due_date, type: 'string', }, expected_delivery_date: { diff --git a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestSearch/BorrowingRequestList/BorrowingRequestListEntry.js b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestSearch/BorrowingRequestList/BorrowingRequestListEntry.js index a7b65acfa..8044555d5 100644 --- a/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestSearch/BorrowingRequestList/BorrowingRequestListEntry.js +++ b/src/lib/pages/backoffice/ILL/BorrowingRequest/BorrowingRequestSearch/BorrowingRequestList/BorrowingRequestListEntry.js @@ -1,4 +1,4 @@ -import { getDisplayVal } from '@config'; +import { getDisplayVal, invenioConfig } from '@config'; import { ILLBorrowingRequestIcon } from '@components/backoffice/icons'; import { BackOfficeRoutes, ILLRoutes, ProviderRoutes } from '@routes/urls'; import PropTypes from 'prop-types'; @@ -27,7 +27,9 @@ export default class BorrowingRequestListEntry extends Component { - + {dueDate ? dueDate : '-'}