ปรับการ fetch ข้อมูล tree
This commit is contained in:
parent
c7ea4e0e5b
commit
dd9239ac25
7 changed files with 18 additions and 12 deletions
|
|
@ -324,10 +324,8 @@ function validateFormPositionEdit() {
|
|||
|
||||
/** ฟังชั่น บันทึก */
|
||||
function onSubmit() {
|
||||
console.log(props.orgLevel);
|
||||
|
||||
dialogConfirm($q, async () => {
|
||||
const positionsData = rows.value.map((e) => ({
|
||||
const positionsData = rows.value.map((e: any) => ({
|
||||
posDictName: e.positionName, //ชื่อตำแหน่งในสายงาน (ชื่อตำแหน่ง)
|
||||
posDictField: e.positionField, //สายงาน
|
||||
posTypeId: e.posTypeId, //*ประเภทตำแหน่ง
|
||||
|
|
@ -471,7 +469,7 @@ watch(
|
|||
);
|
||||
|
||||
function addPosition(data: RowDetailPositions) {
|
||||
const isIdExist = rows.value.some((item) => item.id === data.id);
|
||||
const isIdExist = rows.value.some((item: any) => item.id === data.id);
|
||||
|
||||
if (!isIdExist) {
|
||||
rows.value = [data, ...rows.value];
|
||||
|
|
@ -521,7 +519,12 @@ async function clearFormPositionSelect() {
|
|||
<template>
|
||||
<q-dialog v-model="props.modal" persistent>
|
||||
<q-card style="min-width: 96vw">
|
||||
<DialogHeader :tittle="props.actionType === 'ADD' ? 'เพิ่มอัตรากำลัง':'แก้ไขอัตรากำลัง'" :close="props.close" />
|
||||
<DialogHeader
|
||||
:tittle="
|
||||
props.actionType === 'ADD' ? 'เพิ่มอัตรากำลัง' : 'แก้ไขอัตรากำลัง'
|
||||
"
|
||||
:close="props.close"
|
||||
/>
|
||||
<q-separator />
|
||||
|
||||
<q-card-section class="q-pa-sm">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue