Skip to content

Commit

Permalink
document: add acquisition aggregation
Browse files Browse the repository at this point in the history
* Adds datepicker css to the configuration.

Co-Authored-by: Bertrand Zuchuat <[email protected]>
  • Loading branch information
Garfield-fr committed Nov 27, 2023
1 parent 543ee11 commit 7b03f75
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
4 changes: 3 additions & 1 deletion angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,9 @@
"output": "/assets/"
}
],
"styles": [],
"styles": [
"node_modules/ngx-bootstrap/datepicker/bs-datepicker.css"
],
"scripts": [],
"vendorChunk": true,
"extractLicenses": false,
Expand Down
4 changes: 3 additions & 1 deletion projects/admin/src/app/routes/documents-route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ export class DocumentsRoute extends BaseRoute implements RouteInterface {
year: _('Publication year'),
subject_fiction: _('Subject (fiction)'),
subject_no_fiction: _('Subject (non-fiction)'),
acquisition: _('Acquisition date'),
},
showFacetsIfNoResults: true,
allowEmptySearch: false,
Expand All @@ -108,7 +109,8 @@ export class DocumentsRoute extends BaseRoute implements RouteInterface {
'subject_fiction',
'genreForm',
'intendedAudience',
'status'
'acquisition',
'status',
],
aggregationsExpand: () => {
const expand = ['document_type'];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export class DocumentsRouteService extends BaseRoute implements ResourceRouteInt
/**
* Create route
* @param viewcode - string
* @return dictionnary route configuration or null if loaded
* @return dictionary route configuration or null if loaded
*/
create(viewcode: string): null | {} {
if (!(this.availableConfig.some(v => v === viewcode))) {
Expand Down Expand Up @@ -104,6 +104,7 @@ export class DocumentsRouteService extends BaseRoute implements ResourceRouteInt
organisation: _('Library'),
genreForm: _('Genre, form'),
intendedAudience: _('Intended audience'),
acquisition: _('Acquisition date'),
year: _('Publication year'),
subject_fiction: _('Subject (fiction)'),
subject_no_fiction: _('Subject (non-fiction)'),
Expand Down Expand Up @@ -214,6 +215,7 @@ export class DocumentsRouteService extends BaseRoute implements ResourceRouteInt
_('subject_fiction'),
_('genreForm'),
_('intendedAudience'),
_('acquisition'),
_('status')
];
} else {
Expand All @@ -227,6 +229,7 @@ export class DocumentsRouteService extends BaseRoute implements ResourceRouteInt
_('subject_fiction'),
_('genreForm'),
_('intendedAudience'),
_('acquisition'),
_('status')
];
}
Expand Down

0 comments on commit 7b03f75

Please sign in to comment.