Bug 38201: Fix custom toolbar buttons for eholdings titles
Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
parent
44767f5535
commit
89cb2adf0c
|
|
@ -68,6 +68,7 @@ export default {
|
|||
resourceListFiltersRequired:
|
||||
props.resourceListFiltersRequired || null,
|
||||
formGroupsDisplayMode: props.formGroupsDisplayMode || null,
|
||||
getToolbarButtons: props.getToolbarButtons || (() => []),
|
||||
};
|
||||
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -17,6 +17,21 @@ export default {
|
|||
const vendorStore = inject("vendorStore");
|
||||
const { vendors } = storeToRefs(vendorStore);
|
||||
|
||||
function getToolbarButtons() {
|
||||
return [
|
||||
{
|
||||
to: { name: "EHoldingsLocalTitlesFormImport" },
|
||||
icon: "plus",
|
||||
title: __("Import from list"),
|
||||
},
|
||||
{
|
||||
to: { name: "EHoldingsLocalTitlesKBARTImport" },
|
||||
icon: "plus",
|
||||
title: __("Import from KBART file"),
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
return {
|
||||
...BaseResource.setup({
|
||||
resourceName: "title",
|
||||
|
|
@ -36,6 +51,7 @@ export default {
|
|||
},
|
||||
av_title_publication_types,
|
||||
vendors,
|
||||
getToolbarButtons,
|
||||
}),
|
||||
};
|
||||
},
|
||||
|
|
@ -451,20 +467,6 @@ export default {
|
|||
);
|
||||
}
|
||||
},
|
||||
getToolbarButtons() {
|
||||
return [
|
||||
{
|
||||
to: { name: "EHoldingsLocalTitlesFormImport" },
|
||||
icon: "plus",
|
||||
title: __("Import from list"),
|
||||
},
|
||||
{
|
||||
to: { name: "EHoldingsLocalTitlesKBARTImport" },
|
||||
icon: "plus",
|
||||
title: __("Import from KBART file"),
|
||||
},
|
||||
];
|
||||
},
|
||||
},
|
||||
emits: ["select-resource"],
|
||||
name: "EHoldingsLocalTitlesResource",
|
||||
|
|
|
|||
Loading…
Reference in New Issue