ปรับ mixin messageError แสดง result ก่อน
This commit is contained in:
parent
f4ee2b89fc
commit
174530e7f9
3 changed files with 4 additions and 3 deletions
|
|
@ -16,7 +16,7 @@ import { useQuasar } from "quasar";
|
|||
|
||||
const $q = useQuasar();
|
||||
const mixin = useCounterMixin();
|
||||
const { showLoader, dialogConfirm, success, messageError } = mixin;
|
||||
const { dialogConfirm, success, messageError } = mixin;
|
||||
|
||||
/** propsData จาก RoundMain */
|
||||
const props = defineProps({
|
||||
|
|
|
|||
|
|
@ -229,7 +229,7 @@ const pagination = ref({
|
|||
</q-td>
|
||||
<q-td>
|
||||
<q-btn
|
||||
v-if="props.row.isActive === false"
|
||||
v-if="props.row.isDefault === false"
|
||||
dense
|
||||
flat
|
||||
round
|
||||
|
|
|
|||
|
|
@ -376,11 +376,12 @@ export const useCounterMixin = defineStore("mixin", () => {
|
|||
},
|
||||
});
|
||||
} else {
|
||||
const message = e.response.data.result ?? e.response.data.message;
|
||||
q.dialog({
|
||||
component: CustomComponent,
|
||||
componentProps: {
|
||||
title: `พบข้อผิดพลาด`,
|
||||
message: `${e.response.data.message}`,
|
||||
message: `${message}`,
|
||||
icon: "warning",
|
||||
color: "red",
|
||||
onlycancel: true,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue