From fd567786a8341de4eb0459c122707534e300c232 Mon Sep 17 00:00:00 2001 From: Jake Deery Date: Fri, 6 Mar 2026 12:47:35 +0000 Subject: [PATCH] Bug 14962: (QA follow-up) Fix broken enable/disable radios This patch skips nulling of the enabled property of a new or edited display, avoiding breakage of the system in the process. It also includes a minor tidyup of the displays table's enabled and ID columns. Sponsored-by: ByWater Solutions --- .../components/Display/DisplaysResource.vue | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/Display/DisplaysResource.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/Display/DisplaysResource.vue index 2e5b35c24d0..77a6336fe7c 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/Display/DisplaysResource.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/Display/DisplaysResource.vue @@ -77,6 +77,18 @@ export default { name: "display_id", label: $__("ID"), type: "text", + tableColumnDefinition: { + title: $__("ID"), + data: "display_id", + searchable: false, + orderable: true, + render: function (data, type, row, meta) { + return '%s'.format( + data, + data + ); + }, + }, hideIn: ["Form", "Show"], }, { @@ -240,6 +252,15 @@ export default { name: "enabled", label: $__("Enabled"), type: "boolean", + tableColumnDefinition: { + title: $__("Enabled"), + data: "enabled", + searchable: false, + orderable: true, + render: function (data, type, row, meta) { + return data ? _("Yes") : _("No"); + }, + }, required: true, }, { @@ -480,6 +501,7 @@ export default { } Object.entries(display).forEach(([key, value]) => { + if (key == "enabled") return; if (value == "") display[key] = null; }); -- 2.50.1 (Apple Git-155)