Bugzilla – Attachment 188212 Details for
Bug 41063
Additional fields are broken in Vue
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 41063: Fix additional fields in Vue
Bug-41063-Fix-additional-fields-in-Vue.patch (text/plain), 3.65 KB, created by
Matt Blenkinsop
on 2025-10-21 12:18:07 UTC
(
hide
)
Description:
Bug 41063: Fix additional fields in Vue
Filename:
MIME Type:
Creator:
Matt Blenkinsop
Created:
2025-10-21 12:18:07 UTC
Size:
3.65 KB
patch
obsolete
>From 852512dbec550d8bceedbfb3039a47147cc2c3ba Mon Sep 17 00:00:00 2001 >From: Matt Blenkinsop <matt.blenkinsop@openfifth.co.uk> >Date: Tue, 21 Oct 2025 11:26:09 +0100 >Subject: [PATCH] Bug 41063: Fix additional fields in Vue > >Test plan: >1) Go to Administration > Additional fields and add an additional field for erm_agreements >2) Enable ERM and navigate to ERM > Agreements >3) Click to add a new agreement and then fill out the form, making sure to add something into your new additional field >4) Hit save and navigate to the agreement you have just added >5) There will be no additional field added >6) Apply patch and yarn js:build >7) Repeat steps 3 - 5 >8) The additional field should be added and displayed correctly >--- > .../prog/js/vue/components/AdditionalFieldsEntry.vue | 12 ++++++------ > 1 file changed, 6 insertions(+), 6 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/AdditionalFieldsEntry.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/AdditionalFieldsEntry.vue >index 5f77d405e28..e7d3dcc2636 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/AdditionalFieldsEntry.vue >+++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/AdditionalFieldsEntry.vue >@@ -125,7 +125,7 @@ > </template> > > <script> >-import { onBeforeMount, watch, ref } from "vue"; >+import { onBeforeMount, watch, ref, reactive } from "vue"; > import { APIClient } from "../fetch/api-client.js"; > > export default { >@@ -133,7 +133,7 @@ export default { > const initialized = ref(false); > const available_fields = ref([]); > const av_options = ref([]); >- const current_additional_fields_values = ref({}); >+ const current_additional_fields_values = reactive({}); > > onBeforeMount(() => { > const client = APIClient.additional_fields; >@@ -154,7 +154,7 @@ export default { > }; > const cloneField = (available_field, current, event) => { > event.preventDefault(); >- current_additional_fields_values.value[ >+ current_additional_fields_values[ > available_field.extended_attribute_type_id > ].push({ > value: current.value, >@@ -231,7 +231,7 @@ export default { > // Iterate on available fields > newValue.forEach(available_field => { > // Initialize current field as empty array >- current_additional_fields_values.value[ >+ current_additional_fields_values[ > available_field.extended_attribute_type_id > ] = []; > >@@ -264,7 +264,7 @@ export default { > ? av_value[0].label > : ""; > } >- current_additional_fields_values.value[ >+ current_additional_fields_values[ > existing_field_value.field_id > ].push({ > value: existing_field_value.value, >@@ -278,7 +278,7 @@ export default { > if ( > !available_field.authorised_value_category_name > ) { >- current_additional_fields_values.value[ >+ current_additional_fields_values[ > available_field.extended_attribute_type_id > ] = [ > { >-- >2.50.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 41063
: 188212 |
188216
|
188228