diff --git a/src/components/FormModel.vue b/src/components/FormModel.vue index c33835438..504a7acd6 100644 --- a/src/components/FormModel.vue +++ b/src/components/FormModel.vue @@ -79,9 +79,8 @@ onMounted(async () => { }); // Podemos enviarle al form la estructura de data inicial sin necesidad de fetchearla - if ($props.formInitialData || !$props.autoLoad) { - state.set($props.model, $props.formInitialData ?? {}); - } else { + state.set($props.model, $props.formInitialData ?? {}); + if ($props.autoLoad && !$props.formInitialData) { await fetch(); } diff --git a/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue b/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue index 2a29a3d0e..306220dd3 100644 --- a/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue +++ b/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue @@ -174,7 +174,12 @@ async function upsert() { @on-fetch="(data) => (userConfig = data)" auto-load /> - +