diff --git a/resources/js/Pages/Settings/Partials/ActionTable.vue b/resources/js/Pages/Settings/Partials/ActionTable.vue index f56c5cd..f69a244 100644 --- a/resources/js/Pages/Settings/Partials/ActionTable.vue +++ b/resources/js/Pages/Settings/Partials/ActionTable.vue @@ -36,9 +36,9 @@ const page = ref(1); const pageSize = ref(25); const columns = [ { key: "id", label: "#", sortable: true, class: "w-16" }, - { key: "name", label: "Name", sortable: true }, - { key: "color_tag", label: "Color tag", sortable: false }, - { key: "decisions", label: "Decisions", sortable: false, class: "w-32" }, + { key: "name", label: "Ime", sortable: true }, + { key: "color_tag", label: "Barva", sortable: false }, + { key: "decisions", label: "Odločitve", sortable: false, class: "w-32" }, ]; const form = useForm({ @@ -193,7 +193,7 @@ const destroyAction = () => { class="inline-block h-4 w-4 rounded" :style="{ backgroundColor: row.color_tag }" > - {{ row.color_tag || "—" }} + {{ row.color_tag || "" }} diff --git a/resources/js/Pages/Settings/Partials/DecisionTable.vue b/resources/js/Pages/Settings/Partials/DecisionTable.vue index 5fcda6e..4c0feee 100644 --- a/resources/js/Pages/Settings/Partials/DecisionTable.vue +++ b/resources/js/Pages/Settings/Partials/DecisionTable.vue @@ -3,7 +3,7 @@ import { EditIcon, TrashBinIcon } from "@/Utilities/Icons"; import DialogModal from "@/Components/DialogModal.vue"; import ConfirmationModal from "@/Components/ConfirmationModal.vue"; -import { computed, onMounted, ref } from "vue"; +import { computed, onMounted, ref, watch } from "vue"; import { router, useForm } from "@inertiajs/vue3"; import InputLabel from "@/Components/InputLabel.vue"; import TextInput from "@/Components/TextInput.vue"; @@ -36,10 +36,10 @@ const page = ref(1); const pageSize = ref(25); const columns = [ { key: "id", label: "#", sortable: true, class: "w-16" }, - { key: "name", label: "Name", sortable: true }, - { key: "color_tag", label: "Color tag", sortable: false }, - { key: "belongs", label: "Belongs to actions", sortable: false, class: "w-40" }, - { key: "auto_mail", label: "Auto mail", sortable: false, class: "w-56" }, + { key: "name", label: "Ime", sortable: true }, + { key: "color_tag", label: "Barva", sortable: false }, + { key: "belongs", label: "Pripada akcijam", sortable: false, class: "w-40" }, + { key: "auto_mail", label: "Auto mail", sortable: false, class: "w-46" }, ]; const form = useForm({ @@ -59,6 +59,26 @@ const createForm = useForm({ email_template_id: null, }); +// When auto mail is disabled, also detach email template selection (edit form) +watch( + () => form.auto_mail, + (enabled) => { + if (!enabled) { + form.email_template_id = null; + } + } +); + +// Same behavior for create form for consistency +watch( + () => createForm.auto_mail, + (enabled) => { + if (!enabled) { + createForm.email_template_id = null; + } + } +); + const openEditDrawer = (item) => { form.actions = []; form.id = item.id; @@ -151,16 +171,12 @@ const destroyDecision = () => { - + - All templates + Vse predloge {{ t.name }} @@ -171,7 +187,7 @@ const destroyDecision = () => { v-model="onlyAutoMail" class="rounded border-gray-300 text-indigo-600 shadow-sm focus:ring-indigo-500" /> - Only auto mail + Samo auto mail + Dodaj odločitev @@ -196,7 +212,7 @@ const destroyDecision = () => { class="inline-block h-4 w-4 rounded" :style="{ backgroundColor: row.color_tag }" > - {{ row.color_tag || "—" }} + {{ row.color_tag || "" }} diff --git a/resources/js/Pages/Settings/Workflow/Index.vue b/resources/js/Pages/Settings/Workflow/Index.vue index 46e0307..06a6274 100644 --- a/resources/js/Pages/Settings/Workflow/Index.vue +++ b/resources/js/Pages/Settings/Workflow/Index.vue @@ -1,36 +1,43 @@ - - - - - - - - - - - - - - - + + + + + + + + + + + + + - + + +