0
0
Fork 0

refactor: refs #8304 simplify actionsChildCount computation and update saveUrl assignment in WorkerCalendar

This commit is contained in:
Jose Antonio Tubau 2025-01-31 09:29:20 +01:00
parent fceb5dd5fd
commit fb902b54bc
2 changed files with 2 additions and 3 deletions

View File

@ -1,7 +1,6 @@
<script setup>
import { onMounted, onBeforeUnmount, ref } from 'vue';
import { useStateStore } from 'stores/useStateStore';
import { computed } from 'vue';
const stateStore = useStateStore();
const actions = ref(null);
@ -26,7 +25,7 @@ onMounted(() => {
if (data.value) observer.observe(data.value, opts);
});
const actionsChildCount = computed(() => !!actions.value?.childNodes?.length);
const actionsChildCount = () => !!actions.value?.childNodes?.length;
onBeforeUnmount(() => stateStore.toggleSubToolbar() && hasSubToolbar);
</script>

View File

@ -201,7 +201,7 @@ watch([year, businessFk], () => refreshData());
:save-url="saveUrl"
@on-fetch="
(data) => {
saveUrl = `Businesses/${data[0].id}`;
saveUrl = `Businesses/${data.id}`;
}
"
:body="body"