ลูกจ้างชั่วคราว => ออกคำสั่่ง
This commit is contained in:
parent
ba64953315
commit
79caf784ac
2 changed files with 28 additions and 2 deletions
|
|
@ -28,6 +28,12 @@ const { statusText } = useRegistryEmp();
|
||||||
|
|
||||||
/**props*/
|
/**props*/
|
||||||
const modal = defineModel<boolean>("modal", { required: true });
|
const modal = defineModel<boolean>("modal", { required: true });
|
||||||
|
const props = defineProps({
|
||||||
|
fetchData: {
|
||||||
|
type: Function,
|
||||||
|
require: true,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
const filter = ref<string>("");
|
const filter = ref<string>("");
|
||||||
const rows = ref<DataEmployee[]>([]);
|
const rows = ref<DataEmployee[]>([]);
|
||||||
|
|
@ -165,7 +171,27 @@ function onClickSendOrder() {
|
||||||
dialogConfirm(
|
dialogConfirm(
|
||||||
$q,
|
$q,
|
||||||
() => {
|
() => {
|
||||||
closeDialog();
|
showLoader();
|
||||||
|
let pId: string[] = [];
|
||||||
|
selected.value.forEach((e: any) => {
|
||||||
|
pId.push(e.id);
|
||||||
|
});
|
||||||
|
let data = {
|
||||||
|
id: pId,
|
||||||
|
};
|
||||||
|
http
|
||||||
|
.post(config.API.organizationEmployeeSendOrder, data)
|
||||||
|
.then(() => {
|
||||||
|
success($q, "บันทึกสำเร็จ");
|
||||||
|
closeDialog();
|
||||||
|
props?.fetchData?.();
|
||||||
|
})
|
||||||
|
.catch((err) => {
|
||||||
|
messageError($q, err);
|
||||||
|
})
|
||||||
|
.finally(async () => {
|
||||||
|
hideLoader();
|
||||||
|
});
|
||||||
},
|
},
|
||||||
"ยื่นยันการส่งรายชื่อไปออกคำสั่ง",
|
"ยื่นยันการส่งรายชื่อไปออกคำสั่ง",
|
||||||
"ต้องการยืนยันการส่งรายชื่อไปออกคำสั่งนี้หรือไม่ ?"
|
"ต้องการยืนยันการส่งรายชื่อไปออกคำสั่งนี้หรือไม่ ?"
|
||||||
|
|
|
||||||
|
|
@ -488,5 +488,5 @@ onMounted(() => {
|
||||||
:fetchData="fetchList"
|
:fetchData="fetchList"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<DialogSendOrder v-model:modal="modalSendOrder" />
|
<DialogSendOrder v-model:modal="modalSendOrder" :fetchData="fetchList" />
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue