fix bug & แก้คำผิด
This commit is contained in:
parent
2590fb1142
commit
ad09bd908a
15 changed files with 45 additions and 47 deletions
|
|
@ -314,7 +314,7 @@ async function getTable() {
|
|||
rowsAll.value.push(rowData);
|
||||
});
|
||||
|
||||
// ราชชื่อทั้งหมด
|
||||
// รายชื่อทั้งหมด
|
||||
rows.value = roleAdmin.value
|
||||
? rowsAll.value
|
||||
: rowsAll.value.filter((x: any) => x.statusId !== "CONTAIN");
|
||||
|
|
@ -550,7 +550,7 @@ async function clickClose() {
|
|||
}
|
||||
}
|
||||
|
||||
/** ยืนยันส่งราชชื่อไปหน่วยงาน */
|
||||
/** ยืนยันส่งรายชื่อไปหน่วยงาน */
|
||||
function savelist() {
|
||||
selected.value.map((e: any) => {
|
||||
personal_selected.value.push(e.personalId);
|
||||
|
|
|
|||
|
|
@ -452,7 +452,7 @@ const openModalCalendar = (rows: any) => {
|
|||
</q-td>
|
||||
<q-td auto-width>
|
||||
<q-btn
|
||||
v-if="props.row.appointDate == null"
|
||||
v-if="!props.row.appointDate"
|
||||
icon="mdi-calendar"
|
||||
size="12px"
|
||||
color="blue-7"
|
||||
|
|
@ -481,7 +481,7 @@ const openModalCalendar = (rows: any) => {
|
|||
:close="closeModal"
|
||||
/>
|
||||
<q-separator />
|
||||
<q-card-section class="q-p-sm q-gutter-md bg-grey-1">
|
||||
<q-card-section class="q-p-sm q-gutter-md">
|
||||
<div class="col-xs-12 col-sm-12 col-md-12">
|
||||
<datepicker
|
||||
menu-class-name="modalfix"
|
||||
|
|
|
|||
|
|
@ -158,15 +158,15 @@ function clickAdd() {
|
|||
router.push({ name: "roundAdd" });
|
||||
}
|
||||
|
||||
/** Fnction คำนวณราชชื่อผู้ได้รับเครื่องราช */
|
||||
/** Fnction คำนวณรายชื่อผู้ได้รับเครื่องราช */
|
||||
async function clickListInsignia(propsId: string) {
|
||||
dialogConfirm(
|
||||
$q,
|
||||
async () => {
|
||||
await getRequest(propsId);
|
||||
},
|
||||
"ยืนยันการคำนวณราชชื่อผู้ได้รับเครื่องราชฯ",
|
||||
"ต้องการยืนยันการคำนวณราชชื่อผู้ได้รับเครื่องราชฯนี้หรือไม่ ?"
|
||||
"ยืนยันการคำนวณรายชื่อผู้ได้รับเครื่องราชฯ",
|
||||
"ต้องการยืนยันการคำนวณรายชื่อผู้ได้รับเครื่องราชฯนี้หรือไม่?"
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -272,7 +272,7 @@ function changtypeOc() {
|
|||
DataStore.typeOc = organization.value;
|
||||
}
|
||||
|
||||
/** function เพิ่มราชชื่อ*/
|
||||
/** function เพิ่มรายชื่อ*/
|
||||
async function clickmodalAdd() {
|
||||
let ocId = DataStore.typeOc ? DataStore.typeOc : DataStore.agency;
|
||||
showLoader();
|
||||
|
|
@ -321,7 +321,7 @@ async function fecthlistperson(id: string) {
|
|||
});
|
||||
}
|
||||
|
||||
/** function ยืนยันการเพิ่มราชชื่อ*/
|
||||
/** function ยืนยันการเพิ่มรายชื่อ*/
|
||||
async function clickAdd() {
|
||||
dataPerson.id
|
||||
? await myForm.value!.validate().then((result: boolean) => {
|
||||
|
|
@ -336,7 +336,7 @@ async function clickAdd() {
|
|||
);
|
||||
}
|
||||
})
|
||||
: dialogMessageNotify($q, "กรุณาเลือกราชชื่อที่ต้องการเพิ่ม");
|
||||
: dialogMessageNotify($q, "กรุณาเลือกรายชื่อที่ต้องการเพิ่ม");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ const props = defineProps({
|
|||
},
|
||||
});
|
||||
|
||||
/** callback function จำทำงานเมื่อ props.modal = true เปิด popup เพิ่มราชชื่อบันทึกผล*/
|
||||
/** callback function จำทำงานเมื่อ props.modal = true เปิด popup เพิ่มรายชื่อบันทึกผล*/
|
||||
watch(props, () => {
|
||||
if (props.modal === true) {
|
||||
employeeClass.value = "";
|
||||
|
|
@ -158,7 +158,7 @@ async function fecthlistPerson() {
|
|||
.then((res) => {
|
||||
const id = res.data.result[0].id;
|
||||
if (id !== "") {
|
||||
findlist(id); // id หน่วยงานไปเรียกราชชื่อ
|
||||
findlist(id); // id หน่วยงานไปเรียกรายชื่อ
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
|
|
@ -167,7 +167,7 @@ async function fecthlistPerson() {
|
|||
}
|
||||
|
||||
/**
|
||||
* function เรียกราชชื่อลูกจ้างตาม id หน่วยงาน
|
||||
* function เรียกรายชื่อลูกจ้างตาม id หน่วยงาน
|
||||
* @param id id หน่วยงาน
|
||||
*/
|
||||
async function findlist(id: string) {
|
||||
|
|
|
|||
|
|
@ -349,7 +349,7 @@ async function selectorRound(round: number) {
|
|||
await fecthlistInsignia();
|
||||
}
|
||||
|
||||
/** function เรียกราชชื่อการเสนอขอเครื่องราชฯ */
|
||||
/** function เรียกรายชื่อการเสนอขอเครื่องราชฯ */
|
||||
async function fecthlistInsignia() {
|
||||
showLoader();
|
||||
await http
|
||||
|
|
@ -372,7 +372,7 @@ function close() {
|
|||
modal.value = false;
|
||||
}
|
||||
|
||||
/** function closePopup และเเรียกข้อมูลราชชื่อการเสนอขอเครื่องราชฯ */
|
||||
/** function closePopup และเเรียกข้อมูลรายชื่อการเสนอขอเครื่องราชฯ */
|
||||
function closeAndFecth() {
|
||||
modal.value = false;
|
||||
fecthlistInsignia();
|
||||
|
|
|
|||
|
|
@ -161,7 +161,7 @@ export const useInsigniaDataStore = defineStore("insignia", () => {
|
|||
}
|
||||
|
||||
/**
|
||||
* function ค้นหาข้อมมูลราชชื่อ ตาม ประเภทและสถานภาพ
|
||||
* function ค้นหาข้อมมูลรายชื่อ ตาม ประเภทและสถานภาพ
|
||||
* @param type ประเภท
|
||||
* @param employeeClasstype สถานภาพ
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ export const useBrrowDataStore = defineStore("insigniaBrrow", () => {
|
|||
const type = ref<any[]>([]);
|
||||
|
||||
/**
|
||||
* function เรียกข้อมุลราชชื่อเครื่อง
|
||||
* function เรียกข้อมุลรายชื่อเครื่อง
|
||||
* @param data ข้อมูลเครื่องราช
|
||||
*/
|
||||
async function fetchDataInsignia(data: any) {
|
||||
|
|
|
|||
|
|
@ -313,7 +313,7 @@ watch(modal, () => {
|
|||
}
|
||||
});
|
||||
|
||||
/** function เรียกราชชื่อบันทึกผลการได้รับพระราชทานเครื่องราชอิสริยาภรณ์/การจ่ายใบกำกับ */
|
||||
/** function เรียกรายชื่อบันทึกผลการได้รับพระราชทานเครื่องราชอิสริยาภรณ์/การจ่ายใบกำกับ */
|
||||
async function fecthlistInsignia() {
|
||||
showLoader();
|
||||
let data = {
|
||||
|
|
|
|||
|
|
@ -779,7 +779,7 @@ const openDialog = (action: string) => {
|
|||
clickAction.value = action;
|
||||
selectedModal.value = [];
|
||||
};
|
||||
// บันทักราชชื่อกรรมการ
|
||||
// บันทักรายชื่อกรรมการ
|
||||
const clickSavelist = () => {
|
||||
if (selectedModal.value.length > 0) {
|
||||
if (clickAction.value === "chairman") {
|
||||
|
|
|
|||
|
|
@ -189,11 +189,11 @@ const checkNote = computed(() => {
|
|||
}
|
||||
return false;
|
||||
});
|
||||
// ยืนยันลบข้อมูลราชชื่อ
|
||||
// ยืนยันลบข้อมูลรายชื่อ
|
||||
const dialogDeleteData = async (id: string) => {
|
||||
dialogRemove($q, () => deleteData(id));
|
||||
};
|
||||
// ลบข้อมูลราชชื่อ API
|
||||
// ลบข้อมูลรายชื่อ API
|
||||
const deleteData = async (id: string) => {
|
||||
await http
|
||||
.delete(config.API.personsOrder(id))
|
||||
|
|
@ -208,7 +208,7 @@ const deleteData = async (id: string) => {
|
|||
await conditionData();
|
||||
});
|
||||
};
|
||||
// ปรับราชชื่อขึ้น
|
||||
// ปรับรายชื่อขึ้น
|
||||
const swapUp = async (id: string) => {
|
||||
await http
|
||||
.put(config.API.swapUpOrder(id))
|
||||
|
|
@ -220,7 +220,7 @@ const swapUp = async (id: string) => {
|
|||
hideLoader();
|
||||
});
|
||||
};
|
||||
// ปรับราชชื่อลง
|
||||
// ปรับรายชื่อลง
|
||||
const swapDown = async (id: string) => {
|
||||
await http
|
||||
.put(config.API.swapDownOrder(id))
|
||||
|
|
@ -332,7 +332,7 @@ const putSalary = async (salary: any) => {
|
|||
});
|
||||
});
|
||||
};
|
||||
// เปิด popup เพิ่มข้อมูลราชชื่อ
|
||||
// เปิด popup เพิ่มข้อมูลรายชื่อ
|
||||
const modalAddChange = async () => {
|
||||
modalAdd.value = !modalAdd.value;
|
||||
if (modalAdd.value == true) {
|
||||
|
|
@ -392,7 +392,7 @@ const saveModalAdd = () => {
|
|||
});
|
||||
}
|
||||
};
|
||||
// เพิ่มราชชื่อ API
|
||||
// เพิ่มรายชื่อ API
|
||||
const addlist = async (data: Object) => {
|
||||
const id = route.params.orderid
|
||||
? route.params.orderid.toString()
|
||||
|
|
@ -620,7 +620,7 @@ const pagination = ref({
|
|||
@click="save"
|
||||
class="q-px-md"
|
||||
>
|
||||
<q-tooltip>บันทึกข้อมูล</q-tooltip>
|
||||
<q-tooltip>บันทึกข้อมูล</q-tooltip>
|
||||
</q-btn>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -243,7 +243,7 @@ const getData = async (id: string) => {
|
|||
hideLoader();
|
||||
});
|
||||
};
|
||||
// เลือกราชชื่อจากหน่วยงาน
|
||||
// เลือกรายชื่อจากหน่วยงาน
|
||||
const saveData = async () => {
|
||||
const id = route.params.orderid
|
||||
? route.params.orderid.toString()
|
||||
|
|
@ -319,7 +319,7 @@ const nodeTree = async () => {
|
|||
const onSelected = async (id: string) => {
|
||||
await listModal(id);
|
||||
};
|
||||
// ลบข้อมูลราชชื่อ
|
||||
// ลบข้อมูลรายชื่อ
|
||||
const deleteData = async (id: string) => {
|
||||
await http
|
||||
.delete(config.API.copyOrderId(id))
|
||||
|
|
|
|||
|
|
@ -189,11 +189,11 @@ const checkNote = computed(() => {
|
|||
}
|
||||
return false;
|
||||
});
|
||||
// ยืนยันลบข้อมูลราชชื่อ
|
||||
// ยืนยันลบข้อมูลรายชื่อ
|
||||
const dialogDeleteData = async (id: string) => {
|
||||
dialogRemove($q, () => deleteData(id));
|
||||
};
|
||||
// ลบข้อมูลราชชื่อ API
|
||||
// ลบข้อมูลรายชื่อ API
|
||||
const deleteData = async (id: string) => {
|
||||
await http
|
||||
.delete(config.API.personsOrder(id))
|
||||
|
|
@ -208,7 +208,7 @@ const deleteData = async (id: string) => {
|
|||
await conditionData();
|
||||
});
|
||||
};
|
||||
// ปรับราชชื่อขึ้น
|
||||
// ปรับรายชื่อขึ้น
|
||||
const swapUp = async (id: string) => {
|
||||
await http
|
||||
.put(config.API.swapUpOrder(id))
|
||||
|
|
@ -220,7 +220,7 @@ const swapUp = async (id: string) => {
|
|||
hideLoader();
|
||||
});
|
||||
};
|
||||
// ปรับราชชื่อลง
|
||||
// ปรับรายชื่อลง
|
||||
const swapDown = async (id: string) => {
|
||||
await http
|
||||
.put(config.API.swapDownOrder(id))
|
||||
|
|
@ -332,7 +332,7 @@ const putSalary = async (salary: any) => {
|
|||
});
|
||||
});
|
||||
};
|
||||
// เปิด popup เพิ่มข้อมูลราชชื่อ
|
||||
// เปิด popup เพิ่มข้อมูลรายชื่อ
|
||||
const modalAddChange = async () => {
|
||||
modalAdd.value = !modalAdd.value;
|
||||
if (modalAdd.value == true) {
|
||||
|
|
@ -392,7 +392,7 @@ const saveModalAdd = () => {
|
|||
});
|
||||
}
|
||||
};
|
||||
// เพิ่มราชชื่อ API
|
||||
// เพิ่มรายชื่อ API
|
||||
const addlist = async (data: Object) => {
|
||||
const id = route.params.orderid
|
||||
? route.params.orderid.toString()
|
||||
|
|
@ -620,7 +620,7 @@ const pagination = ref({
|
|||
@click="save"
|
||||
class="q-px-md"
|
||||
>
|
||||
<q-tooltip>บันทึกข้อมูล</q-tooltip>
|
||||
<q-tooltip>บันทึกข้อมูล</q-tooltip>
|
||||
</q-btn>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -718,7 +718,7 @@ const pagination = ref({
|
|||
:visible-columns="visibleColumns"
|
||||
:filter="filter"
|
||||
row-key="name"
|
||||
:selection="'multiple' "
|
||||
:selection="'multiple'"
|
||||
v-model:selected="selected"
|
||||
>
|
||||
<template v-slot:header="props">
|
||||
|
|
|
|||
|
|
@ -243,7 +243,7 @@ const getData = async (id: string) => {
|
|||
hideLoader();
|
||||
});
|
||||
};
|
||||
// เลือกราชชื่อจากหน่วยงาน
|
||||
// เลือกรายชื่อจากหน่วยงาน
|
||||
const saveData = async () => {
|
||||
const id = route.params.orderid
|
||||
? route.params.orderid.toString()
|
||||
|
|
@ -319,7 +319,7 @@ const nodeTree = async () => {
|
|||
const onSelected = async (id: string) => {
|
||||
await listModal(id);
|
||||
};
|
||||
// ลบข้อมูลราชชื่อ
|
||||
// ลบข้อมูลรายชื่อ
|
||||
const deleteData = async (id: string) => {
|
||||
await http
|
||||
.delete(config.API.copyOrderId(id))
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ const {
|
|||
success,
|
||||
messageError,
|
||||
date2Thai,
|
||||
dialogConfirm,
|
||||
} = mixin;
|
||||
const DataStore = useroleUserDataStore();
|
||||
const { fetchroleUser } = DataStore;
|
||||
|
|
@ -406,15 +407,12 @@ const tagClickPlacement = (tag: string) => {
|
|||
* confirm ก่อนออกจากระบบ
|
||||
*/
|
||||
const doLogout = () => {
|
||||
$q.dialog({
|
||||
title: "ยืนยันการออกจากระบบ",
|
||||
message: `ต้องการออกจากระบบใช้หรือไม่?`,
|
||||
cancel: "ยกเลิก",
|
||||
ok: "ยืนยัน",
|
||||
persistent: true,
|
||||
}).onOk(() => {
|
||||
keycloak.logout();
|
||||
});
|
||||
dialogConfirm(
|
||||
$q,
|
||||
() => keycloak.logout(),
|
||||
"ยืนยันการออกจากระบบ",
|
||||
"ต้องการออกจากระบบใช่หรือไม่?"
|
||||
);
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue