fix: zone events postcode select
gitea/salix-front/pipeline/pr-master This commit looks good Details

This commit is contained in:
Jon Elias 2024-12-30 14:02:23 +01:00
parent 8502e13bdb
commit 3c7880d02f
2 changed files with 7 additions and 2 deletions

View File

@ -148,7 +148,11 @@ onMounted(() => {
const arrayDataKey = const arrayDataKey =
$props.dataKey ?? ($props.url?.length > 0 ? $props.url : $attrs.name ?? $attrs.label); $props.dataKey ?? ($props.url?.length > 0 ? $props.url : $attrs.name ?? $attrs.label);
const arrayData = useArrayData(arrayDataKey, { url: $props.url, searchUrl: false }); const arrayData = useArrayData(arrayDataKey, {
url: $props.url,
searchUrl: false,
mapKey: $attrs['map-key'],
});
function findKeyInOptions() { function findKeyInOptions() {
if (!$props.options) return; if (!$props.options) return;

View File

@ -89,7 +89,7 @@ watch(
v-model="formData.geoFk" v-model="formData.geoFk"
url="Postcodes/location" url="Postcodes/location"
:fields="['geoFk', 'code', 'townFk', 'countryFk']" :fields="['geoFk', 'code', 'townFk', 'countryFk']"
sort-by="code, townFk" :sort-by="['code ASC']"
option-value="geoFk" option-value="geoFk"
option-label="code" option-label="code"
:filter-options="['code']" :filter-options="['code']"
@ -97,6 +97,7 @@ watch(
dense dense
outlined outlined
rounded rounded
map-key="geoFk"
> >
<template #option="{ itemProps, opt }"> <template #option="{ itemProps, opt }">
<QItem v-bind="itemProps"> <QItem v-bind="itemProps">