เพิ้ม validate การเลือกตำแหน่ง
This commit is contained in:
parent
fdda661a3f
commit
9e27068e1e
1 changed files with 6 additions and 4 deletions
|
|
@ -46,6 +46,7 @@ const {
|
||||||
messageError,
|
messageError,
|
||||||
success,
|
success,
|
||||||
dialogRemove,
|
dialogRemove,
|
||||||
|
dialogMessageNotify,
|
||||||
} = mixin;
|
} = mixin;
|
||||||
const selected = ref<any>([]);
|
const selected = ref<any>([]);
|
||||||
const search = ref<string>("");
|
const search = ref<string>("");
|
||||||
|
|
@ -309,7 +310,11 @@ function validateForm() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (hasError.every((result) => result === true)) {
|
if (hasError.every((result) => result === true)) {
|
||||||
onSubmit();
|
if (rows.value.length !== 0) {
|
||||||
|
onSubmit();
|
||||||
|
} else {
|
||||||
|
dialogMessageNotify($q, "กรุณาเลือกตำแหน่งอย่างน้อย 1 ตำแหน่ง");
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -428,8 +433,6 @@ function onSubmitSelectEdit() {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/** input ค้นหา */
|
/** input ค้นหา */
|
||||||
const searchRef = ref<any>(null);
|
const searchRef = ref<any>(null);
|
||||||
async function searchInput() {
|
async function searchInput() {
|
||||||
|
|
@ -724,7 +727,6 @@ async function clearFormPositionSelect() {
|
||||||
:options="optionFilter"
|
:options="optionFilter"
|
||||||
emit-value
|
emit-value
|
||||||
dense
|
dense
|
||||||
|
|
||||||
map-options
|
map-options
|
||||||
outlined
|
outlined
|
||||||
option-label="name"
|
option-label="name"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue