From 977e5d735b0ac0dbacfd8621744fb55088f46494 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 1 Mar 2023 14:03:38 +0100 Subject: [PATCH] Bug 33103: Display the aliases in the dropdown list in ERM --- .../prog/js/vue/components/ERM/AgreementsFormAdd.vue | 2 +- .../components/ERM/EHoldingsLocalPackagesFormAdd.vue | 2 +- .../ERM/EHoldingsLocalTitlesFormAddResources.vue | 2 +- .../prog/js/vue/components/ERM/LicensesFormAdd.vue | 2 +- .../prog/js/vue/components/ERM/Main.vue | 12 ++++++++++-- 5 files changed, 14 insertions(+), 6 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue index 7720370b001..92ad8322413 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue @@ -31,7 +31,7 @@ diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalPackagesFormAdd.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalPackagesFormAdd.vue index c227105e715..ee47c06ad23 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalPackagesFormAdd.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalPackagesFormAdd.vue @@ -28,7 +28,7 @@ diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalTitlesFormAddResources.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalTitlesFormAddResources.vue index fe6ae050e6d..badeeee673a 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalTitlesFormAddResources.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalTitlesFormAddResources.vue @@ -46,7 +46,7 @@ diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/LicensesFormAdd.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/LicensesFormAdd.vue index 14b42290f15..c1891374fff 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/LicensesFormAdd.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/LicensesFormAdd.vue @@ -31,7 +31,7 @@ diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/Main.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/Main.vue index c430f61d83a..24ba4f6eb97 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/Main.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/Main.vue @@ -169,8 +169,16 @@ export default { const client = APIClient.acquisition client.vendors.getAll().then( vendors => { - this.vendorStore.vendors = vendors - this.initialized = true + this.vendorStore.vendors = vendors.map(v => ({ + ...v, + display_name: + v.name + + (v.aliases.length > 0 + ? " (" + + v.aliases.map(a => a.alias).join(", ") + + ")" + : ""), + })) }, error => {} ) -- 2.25.1