Skip to content
Snippets Groups Projects
Commit 755220d6 authored by Konrad Mohrfeldt's avatar Konrad Mohrfeldt :koala:
Browse files

fix: ensure licenses are properly loaded from store

parent 0ac7e87c
No related branches found
No related tags found
No related merge requests found
......@@ -18,7 +18,7 @@
<FormGroup v-slot="controlAttributes" :label="t('image.license')">
<select v-model="image.licenseId" class="form-control" required v-bind="controlAttributes">
<option v-for="license in licenses" :key="license.id" :value="license.id">
<option v-for="license in licenseStore.items" :key="license.id" :value="license.id">
{{ license.name }}
</option>
</select>
......@@ -68,7 +68,7 @@ defineOptions({
const modelValue = defineModel<Image | NewImage>({ required: true })
const attrs = useAttrs()
const { t } = useI18n()
const { items: licenses } = useLicenseStore()
const licenseStore = useLicenseStore()
const image = useCopy<Image | NewImage>(modelValue, {
clone: (image) => ({ ...image }),
save: (image) => (modelValue.value = image),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment