-
+
ส่งไปออกคำสั่งแต่งตั้ง-เลื่อน-ย้าย
-
+
-
+
-
+
-
+
@@ -286,27 +342,60 @@ onMounted(() => {
-
+
{{ props.rowIndex + 1 }}
-
+
{{ props.row.citizenId }}
-
+
{{ props.row.fullname }}
-
-
+
+
- {{ props.row.orgName !== null ? props.row.orgName : "-" }}
- {{ props.row.organizationShortName !== null ? `(${props.row.organizationShortName})` : "" }}
+ {{
+ props.row.orgName !== null ? props.row.orgName : "-"
+ }}
+ {{
+ props.row.organizationShortName !== null
+ ? `(${props.row.organizationShortName})`
+ : ""
+ }}
- {{ props.row.positionPath !== null ? props.row.positionPath : "-" }}
- {{ props.row.positionNumber !== null ? `(${props.row.positionNumber})` : "" }}
+ {{
+ props.row.positionPath !== null
+ ? props.row.positionPath
+ : "-"
+ }}
+ {{
+ props.row.positionNumber !== null
+ ? `(${props.row.positionNumber})`
+ : ""
+ }}
@@ -316,29 +405,73 @@ onMounted(() => {
-
+
{{ props.row.birthday }}
-
+
{{ props.row.createdAt }}
-
+
{{ props.row.status }}
-
-
+
+
-
-
-
+
+
+
เลือกหน่วยงาน/ตำแหน่ง
-
-
+
+
ลบข้อมูล
@@ -366,6 +499,11 @@ onMounted(() => {
:nextPage="nextPage"
:fecthlistappointment="fecthlistappointment"
/>
-
+
diff --git a/src/modules/05_placement/components/Main.vue b/src/modules/05_placement/components/Main.vue
index af79afc85..9ba46025c 100644
--- a/src/modules/05_placement/components/Main.vue
+++ b/src/modules/05_placement/components/Main.vue
@@ -425,7 +425,7 @@ function filterFnYear(val: string, update: any) {
-import { ref, computed,watchEffect } from "vue";
+import { ref, computed, watchEffect } from "vue";
import { useQuasar } from "quasar";
import { useCounterMixin } from "@/stores/mixin";
import type { QTableProps } from "quasar";
@@ -25,8 +25,8 @@ const props = defineProps({
fecthlistOthet: Function,
optionsType: Array,
rows2: Array,
- filterKeyword2:String,
- type:String,
+ filterKeyword2: String,
+ type: String,
});
const visibleColumns2 = ref([
"no",
@@ -96,7 +96,6 @@ const emit = defineEmits([
"update:filterKeyword2",
"update:type",
"update:selected",
-
]);
const updateInput = (value: any) => {
emit("update:filterKeyword2", value);
@@ -107,7 +106,7 @@ const updateInputType = (value: any) => {
};
//รีเซ็ตค่าในช่องค้นหา
const Reset = () => {
- emit("update:filterKeyword2", "");
+ emit("update:filterKeyword2", "");
};
//เปิด modal ยืนยัน
const clickAddlist = () => {
@@ -117,7 +116,7 @@ const clickAddlist = () => {
//อัพเดต ส่งไปออกคำสั่ง
const addOther = async () => {
let pId: string[] = [];
- let Type = props.type as string
+ let Type = props.type as string;
selected.value.forEach((e: any) => {
pId.push(e.personalId);
});
@@ -136,7 +135,7 @@ const addOther = async () => {
.finally(() => {
props.fecthlistOthet?.();
selected.value = [];
- props.clickClose?.()
+ props.clickClose?.();
});
};
watchEffect(() => {
@@ -144,6 +143,23 @@ watchEffect(() => {
selected.value = [];
}
});
+// filter OptionsType
+const OptionsTypeFn = ref([]);
+function filterFnOptionsType(val: string, update: any) {
+ if (val == "") {
+ update(() => {
+ OptionsTypeFn.value = props.optionsType;
+ });
+ } else {
+ update(() => {
+ if (props.optionsType) {
+ OptionsTypeFn.value = props.optionsType.filter(
+ (e: any) => e.name.search(val) !== -1
+ );
+ }
+ });
+ }
+}
@@ -160,14 +176,23 @@ watchEffect(() => {
dense
:model-value="type"
@update:model-value="updateInputType"
- :options="optionsType"
+ :options="OptionsTypeFn"
label="ประเภทคำสั่ง"
style="width: 400px; max-width: auto"
emit-value
map-options
option-label="name"
option-value="id"
- />
+ use-input
+ @filter="filterFnOptionsType"
+ >
+
+
+ ไม่มีข้อมูล
+
+
+
+
@@ -232,7 +257,6 @@ watchEffect(() => {
-
{
status: r.status ?? "-",
statustext: statusText(r.status ?? ""),
fullname: `${r.prefix ?? ""}${r.firstname ?? ""} ${r.lastname ?? ""}`,
+ amountOld: r.amountOld,
+ positionDate: r.positionDate,
}));
rows2.value = rows.value.filter(
- (e: listMain) => e.status !== "REPORT" && e.status !== "DONE"
+ (e: listMain) =>
+ e.status !== "REPORT" &&
+ e.status !== "DONE" &&
+ e.organizationPositionOld &&
+ e.positionTypeOld &&
+ e.positionLevelOld &&
+ e.positionNumberOld &&
+ e.amountOld !== null &&
+ e.positionDate
);
})
.catch((e) => {
diff --git a/src/modules/05_placement/components/Receive/receiveMain.vue b/src/modules/05_placement/components/Receive/receiveMain.vue
index db91c6dfb..ef738b93e 100644
--- a/src/modules/05_placement/components/Receive/receiveMain.vue
+++ b/src/modules/05_placement/components/Receive/receiveMain.vue
@@ -52,8 +52,15 @@ const popup = () => {
(r.status == "WAITTING" ||
r.status == "PENDING" ||
r.status == "APPROVE") &&
- r.positionNumber != null
+ r.positionNumber != null &&
+ r.educationOld &&
+ r.organizationPositionOld &&
+ r.positionTypeOld &&
+ r.positionLevelOld &&
+ r.positionNumberOld &&
+ r.amountOld !== null
);
+
rows2.value = row;
modal.value = true;
};
@@ -147,27 +154,28 @@ const columns = ref([
},
]);
- //save file
+//save file
const SaveData = async () => {
myForm.value.validate().then((result: boolean) => {
if (result) {
- const formData = new FormData();
- formData.append("File", files.value);
- showLoader();
- http
- .put(config.API.receiveFile(personalId.value), formData)
- .then(() => {
- success($q, "บันทึกข้อมูลสำเร็จ");
- })
- .catch((e) => {
- messageError($q, e);
- })
- .finally(async () => {
- await clickCloseUpload();
- hideLoader();
-
- });
-}})};
+ const formData = new FormData();
+ formData.append("File", files.value);
+ showLoader();
+ http
+ .put(config.API.receiveFile(personalId.value), formData)
+ .then(() => {
+ success($q, "บันทึกข้อมูลสำเร็จ");
+ })
+ .catch((e) => {
+ messageError($q, e);
+ })
+ .finally(async () => {
+ await clickCloseUpload();
+ hideLoader();
+ });
+ }
+ });
+};
const fecthlistRecevice = async () => {
showLoader();
@@ -175,6 +183,7 @@ const fecthlistRecevice = async () => {
.get(config.API.receiveData())
.then((res: any) => {
const response = res.data.result;
+
listRecevice.value = response;
let list: ResponseRow[] = [];
response.map((e: ResponseData) => {
@@ -194,12 +203,23 @@ const fecthlistRecevice = async () => {
organizationShortName: e.organizationShortName,
positionNumber: e.positionNumber,
positionPath: e.positionPath,
- birthday: e.dateOfBirth == null ? "-" : date2Thai(e.dateOfBirth) &&
- e.dateOfBirth.toString() === "0001-01-01T00:00:00" ? "-" : date2Thai(e.dateOfBirth),
+ birthday:
+ e.dateOfBirth == null
+ ? "-"
+ : date2Thai(e.dateOfBirth) &&
+ e.dateOfBirth.toString() === "0001-01-01T00:00:00"
+ ? "-"
+ : date2Thai(e.dateOfBirth),
status: e.status,
statusText: statusText(e.status ?? ""),
createdAt: e.createdAt !== null ? new Date(e.createdAt) : null,
dateText: e.createdAt !== null ? date2Thai(e.createdAt) : "-",
+ educationOld: e.educationOld ?? "",
+ organizationPositionOld: e.organizationPositionOld ?? "",
+ positionTypeOld: e.positionTypeOld,
+ positionLevelOld: e.positionLevelOld,
+ positionNumberOld: e.positionNumberOld,
+ amountOld: e.amountOld,
});
});
rows.value = list;
@@ -231,7 +251,7 @@ const clickClose = () => {
// ปิดโมเดลอัปเดตไฟล์
const clickCloseUpload = () => {
modalupload.value = false;
- files.value = null
+ files.value = null;
};
// ปิดโมเดลโครงสร้าง
const openModalTree = (id: string) => {
@@ -292,26 +312,62 @@ onMounted(() => {
เพิ่มข้อมูล
-
+
ส่งไปออกคำสั่งรับโอน
-
+
-
+
-
+
-
+
@@ -322,25 +378,60 @@ onMounted(() => {
-
+
{{ props.rowIndex + 1 }}
-
+
{{ props.row.citizenId }}
-
+
{{ props.row.fullname }}
-
-
+
+
- {{ props.row.orgName !== null ? props.row.orgName : "-" }}
- {{ props.row.organizationShortName !== null ? `(${props.row.organizationShortName})` : "" }}
+ {{
+ props.row.orgName !== null ? props.row.orgName : "-"
+ }}
+ {{
+ props.row.organizationShortName !== null
+ ? `(${props.row.organizationShortName})`
+ : ""
+ }}
- {{ props.row.positionPath !== null ? props.row.positionPath : "-" }}
- {{ props.row.positionNumber !== null ? `(${props.row.positionNumber})` : "" }}
+ {{
+ props.row.positionPath !== null
+ ? props.row.positionPath
+ : "-"
+ }}
+ {{
+ props.row.positionNumber !== null
+ ? `(${props.row.positionNumber})`
+ : ""
+ }}
@@ -350,46 +441,119 @@ onMounted(() => {
-
+
{{ props.row.birthday }}
-
+
{{ props.row.dateText }}
-
+
{{ props.row.statusText }}
-
-
+
+
-
-
-
+
+
+
เลือกหน่วยงานที่รับโอน
-
-
-
+
+
+
อัปโหลดเอกสาร
-
-
+
+
ลบข้อมูล
@@ -423,8 +587,18 @@ onMounted(() => {
-
+
@@ -435,7 +609,13 @@ onMounted(() => {
-
+
บันทึก
diff --git a/src/modules/05_placement/components/Repatriate/RepatriateMain.vue b/src/modules/05_placement/components/Repatriate/RepatriateMain.vue
index d4de1077f..0faa5a41d 100644
--- a/src/modules/05_placement/components/Repatriate/RepatriateMain.vue
+++ b/src/modules/05_placement/components/Repatriate/RepatriateMain.vue
@@ -155,9 +155,17 @@ const openModalOrder = () => {
openModal();
const row = rows.value.filter(
(item: officerType) =>
- item.status == "WAITTING" ||
- item.status == "PENDING" ||
- item.status == "APPROVE"
+ (item.status == "WAITTING" ||
+ item.status == "PENDING" ||
+ item.status == "APPROVE") &&
+ item.organizationPositionOld &&
+ item.positionTypeOld &&
+ item.positionLevelOld &&
+ item.positionNumberOld &&
+ item.salary !== null &&
+ item.organization &&
+ item.date &&
+ item.dateRepatriation
);
rows2.value = row;
};
@@ -187,6 +195,7 @@ const getData = async () => {
positionNumberOld: item.positionNumberOld,
organizationPositionOld: item.organizationPositionOld,
isActive: item.isActive,
+ dateRepatriation: item.dateRepatriation,
}));
})
.catch((e) => {})
@@ -224,26 +233,63 @@ onMounted(async () => {
-
-
+
ส่งไปออกคำสั่งส่งตัวกลับ
-
+
-
+
-
+
-
+
@@ -252,45 +298,89 @@ onMounted(async () => {
-
+
{{ props.rowIndex + 1 }}
-
+
{{ props.row.fullname }}
-
+
{{ props.row.posNo }}
-
+
{{ props.row.position }}
-
+
{{ props.row.positionLevel }}
-
+
{{ props.row.organizationPositionOld }}
-
+
{{ props.row.organization }}
-
+
{{ props.row.createdAt }}
-
+
{{ props.row.statusText }}
-
+ :disable="
+ props.row.status == 'REPORT' || props.row.status == 'DONE'
+ "
+ >
ลบข้อมูล
diff --git a/src/modules/05_placement/components/Transfer/transferMain.vue b/src/modules/05_placement/components/Transfer/transferMain.vue
index aaa5ddc31..418c70bcd 100644
--- a/src/modules/05_placement/components/Transfer/transferMain.vue
+++ b/src/modules/05_placement/components/Transfer/transferMain.vue
@@ -26,7 +26,7 @@ const rows = ref([]);
const rows2 = ref([]);
const filters = ref([]);
- //ค้นหา คอลัมน์ คอลัมน์ที่แสดง
+//ค้นหา คอลัมน์ คอลัมน์ที่แสดง
const visibleColumns = ref([
"no",
"fullname",
@@ -135,20 +135,30 @@ const columns = ref([
},
]);
-
const openModal = () => (modal.value = true);
const closeModal = () => {
- modal.value = false
- filterKeyword2.value = ""
+ modal.value = false;
+ filterKeyword2.value = "";
};
-
// เปิดโมเดล
const openModalOrder = () => {
+ console.log(filters.value);
+
openModal();
const row = filters.value.filter(
(r: ResponseData) =>
- r.status == "WAITTING" || r.status == "PENDING" || r.status == "APPROVE"
+ (r.status == "WAITTING" ||
+ r.status == "PENDING" ||
+ r.status == "APPROVE") &&
+ r.createdAt &&
+ r.organizationPositionOld &&
+ r.positionTypeOld &&
+ r.positionLevel &&
+ r.posNo &&
+ r.salary !== null &&
+ r.organization &&
+ r.createdAt
);
rows2.value = row;
};
diff --git a/src/modules/05_placement/components/helpgovernment/mainHelp.vue b/src/modules/05_placement/components/helpgovernment/mainHelp.vue
index 6f542e119..6bda234e8 100644
--- a/src/modules/05_placement/components/helpgovernment/mainHelp.vue
+++ b/src/modules/05_placement/components/helpgovernment/mainHelp.vue
@@ -170,16 +170,20 @@ const openDetail = (id: string) => {
};
const openModal = () => (modal.value = true);
const closeModal = () => {
- modal.value = false
+ modal.value = false;
filterKeyword2.value = "";
};
const openModalOrder = () => {
openModal();
const row = rows.value.filter(
(item: officerType) =>
- item.status == "WAITTING" ||
- item.status == "PENDING" ||
- item.status == "APPROVE"
+ (item.status == "WAITTING" ||
+ item.status == "PENDING" ||
+ item.status == "APPROVE") &&
+ item.organizationPositionOld &&
+ item.organization &&
+ item.dateStart &&
+ item.dateEnd
);
rows2.value = row;
};
@@ -213,7 +217,7 @@ const getData = async () => {
}));
})
.catch((e) => {})
- .finally(() => {
+ .finally(() => {
hideLoader();
});
};
@@ -246,21 +250,53 @@ onMounted(async () => {
-
+
ส่งไปออกคำสั่งช่วยราชการ
-
+
-
+
-
+
@@ -291,42 +327,90 @@ onMounted(async () => {
>
{{ props.row.fullname }}
-
+
{{ props.row.posNo }}
-
+
{{ props.row.position }}
-
+
{{ props.row.positionLevel }}
-
+
{{ props.row.organizationPositionOld }}
-
+
{{ props.row.organization }}
-
+
{{ props.row.dateStart }}
-
+
{{ props.row.dateEnd }}
-
+
{{ props.row.createdAt }}
-
+
{{ props.row.statusText }}
-
+ :disable="
+ props.row.status == 'REPORT' || props.row.status == 'DONE'
+ "
+ >
ลบข้อมูล
diff --git a/src/modules/05_placement/components/probation/MainProbation.vue b/src/modules/05_placement/components/probation/MainProbation.vue
index 33367fe6a..3669b9d93 100644
--- a/src/modules/05_placement/components/probation/MainProbation.vue
+++ b/src/modules/05_placement/components/probation/MainProbation.vue
@@ -393,7 +393,7 @@ function filterFn(val: string, update: any) {
{
openModal();
const row = filters.value.filter(
(r: ResponseItems) =>
- r.status == "PENDING" || r.status == "APPROVE" || r.status == "REJECT"
+ r.status == "WAITTING" || r.status == "PENDING" || r.status == "APPROVE"
);
rows2.value = row;
};
diff --git a/src/modules/06_retirement/views/Main.vue b/src/modules/06_retirement/views/Main.vue
index ee3a43109..39f6afdee 100644
--- a/src/modules/06_retirement/views/Main.vue
+++ b/src/modules/06_retirement/views/Main.vue
@@ -72,19 +72,17 @@ const columns = ref([
// ข้อมูลตาราง (จำลอง)
const currentYear = new Date().getFullYear();
const rows = ref([]);
-const yearOptions = ref([]);
+const yearOptions = ref([{ id: "", year: "ทั้งหมด" }]);
-onMounted(() => {
- filteryear();
+onMounted(async () => {
+ await fetchRetirement(type.value, currentYear);
+ // await fetchRetirement(type.value, currentYear);
});
// หาปีปัจจุบัน
const filteryear = () => {
- yearOptions.value = [{ id: currentYear, name: currentYear + 543 }];
- yearOptions.value.push({ id: currentYear, name: currentYear + 543 });
- // fiscalyear.value = yearOptions[0].id;
-
- yearOptionsFilter.value = [{ id: currentYear, name: currentYear + 543 }];
- yearOptionsFilter.value.push({ id: currentYear, name: currentYear + 543 });
+ // yearOptions.value.push({ id: currentYear, name: currentYear + 543 });
+ // yearOptionsFilter.value = [{ id: currentYear, name: currentYear + 543 }];
+ // yearOptionsFilter.value.push({ id: currentYear, name: currentYear + 543 });
fetchRetirement(type.value, currentYear);
};
// ประกาศเกษียณอายุราชการ
@@ -98,7 +96,7 @@ const fetchRetirement = async (type: string, year: any) => {
rows.value = data.map((items: any) => ({
id: items.id,
Date: date2Thai(items.createdAt),
- year: items.year,
+ year: items.year + 543,
retireNumber: items.round,
total: items.total,
round: items.round,
@@ -106,6 +104,19 @@ const fetchRetirement = async (type: string, year: any) => {
json: items.json,
document: items.document,
}));
+ let option: any[] = [];
+ data.map((items: any) => {
+ option.push({
+ id: items.year,
+ year: (items.year + 543).toString(),
+ typeReport: typeReportChangeName(items.typeReport), // เปลี่ยนสถานะ
+ });
+ });
+ yearOptions.value = [{ id: 0, year: "ทั้งหมด" }];
+ yearOptions.value.push(...option);
+
+ yearOptionsFilter.value = yearOptions.value;
+
actionOption.value = rows.value;
rows.value.sort((a, b) => a.round - b.round); // เรียงรอบมากไปน้อย
checkststus(rows.value);
@@ -144,10 +155,10 @@ const pagination = ref({
rowsPerPage: 10,
});
-const filterSelector = (val: any, update: Function, year: any) => {
+const filterSelector = (val: any, update: Function) => {
update(() => {
yearOptions.value = yearOptionsFilter.value.filter(
- (v: any) => v.name.valueOf(val.toLowerCase()) > -1
+ (v: any) => v.year.indexOf(val) > -1
);
});
};
@@ -219,18 +230,28 @@ const typeReportChangeName = (val: string) => {
map-options
:options="yearOptions"
option-value="id"
- option-label="name"
+ option-label="year"
lazy-rules
+ use-input
hide-bottom-space
:readonly="false"
:borderless="false"
:outlined="true"
+ @filter="(inputValue:any,
+ doneFn:Function) => filterSelector(inputValue, doneFn
+ ) "
:hide-dropdown-icon="false"
style="min-width: 150px"
- @filter="(inputValue:any,
- doneFn:Function) => filterSelector(inputValue, doneFn,'yearOptions'
- ) "
- />
+ >
+
+
+
+ ไม่มีข้อมูล
+
+
+
+
+
{
};
// เรียก file รายชื่อข้าราชการสามัญฯ
const downloadFileexcel = async () => {
+ const findInsigniaId = DataStore.dataInsigniaType.find(
+ (e: any) => e.name == DataStore.typeinsignia
+ );
+
showLoader();
await http
- .get(config.API.insigniaDowanload(DataStore.requestId), {
+ .put(config.API.insigniaDowanload(DataStore.requestId), {
responseType: "blob",
+ profileType:
+ DataStore.employeeClass == "all" ? null : DataStore.employeeClass,
+ InsigniaId: DataStore.typeinsignia == "all" ? null : findInsigniaId.id,
})
.then(async (res) => {
await downloadFile(
@@ -656,33 +663,29 @@ const clickShowWarn = (
const filterSelector = (val: any, update: Function, name: any) => {
update(() => {
const needle = val.toLowerCase();
- if (name === 'typeinsigniaOptions') {
- DataStore.typeinsignia = ''
- typeinsigniaOptions.value = DataStore.typeinsigniaOptions.filter(
- (v: any) => v.name.toLowerCase().indexOf(needle) > -1
- );
- }
- else if(name === 'employeeClassOps'){
- DataStore.employeeClass = ''
- employeeClassOps.value = DataStore.employeeClassOps.filter(
- (v: any) => v.name.toLowerCase().indexOf(needle) > -1
- );
- }
- else if(name === 'filterOrganizationOP'){
+ if (name === "typeinsigniaOptions") {
+ DataStore.typeinsignia = "";
+ typeinsigniaOptions.value = DataStore.typeinsigniaOptions.filter(
+ (v: any) => v.name.toLowerCase().indexOf(needle) > -1
+ );
+ } else if (name === "employeeClassOps") {
+ DataStore.employeeClass = "";
+ employeeClassOps.value = DataStore.employeeClassOps.filter(
+ (v: any) => v.name.toLowerCase().indexOf(needle) > -1
+ );
+ } else if (name === "filterOrganizationOP") {
filterOrganizationOP.value = organizationOptions.value.filter(
- (v: any) => v.name.toLowerCase().indexOf(needle) > -1
- );
+ (v: any) => v.name.toLowerCase().indexOf(needle) > -1
+ );
}
-
- }
- )
-}
+ });
+};
const clearInsigniaFilters = (name: string) => {
if (name === "typeinsigniaOptions") {
DataStore.typeinsignia = "all";
typeinsigniaOptions.value = DataStore.typeinsigniaOptions;
- } else if (name === 'employeeClassOps') {
+ } else if (name === "employeeClassOps") {
DataStore.employeeClass = "all";
employeeClassOps.value = DataStore.employeeClassOps;
}
@@ -694,7 +697,7 @@ const clearInsigniaFilters = (name: string) => {
{
) "
/>
{
(false); //model แก้ไข
onMounted(async () => {
tab.value = DataStore.mainTab;
await fecthlistRound();
+ DataStore.dataInsigniaType.length === 0 && (await fecthInsignia());
});
//เรียกรอบการเสนอขอพระราชทานเครื่อง
@@ -123,6 +124,18 @@ const fecthType = async () => {
messageError($q, err);
});
};
+// เรียกประเภทเครื่องราช
+const fecthInsignia = async () => {
+ await http
+ .get(config.API.insignia)
+ .then((res) => {
+ let data = res.data.result;
+ DataStore.fetchInsigniaType(data);
+ })
+ .catch((err) => {
+ messageError($q, err);
+ });
+};
//เลือกรอบการแสดง
const changround = async () => {
diff --git a/src/modules/07_insignia/store.ts b/src/modules/07_insignia/store.ts
index 982c425ac..9f1dc5269 100644
--- a/src/modules/07_insignia/store.ts
+++ b/src/modules/07_insignia/store.ts
@@ -37,6 +37,7 @@ export const useInsigniaDataStore = defineStore("insignia", () => {
{ id: '44', title: 'บัญชีแสดงจำนวนชั้นตราเครื่องราชฯ' }
])
const mainTab = ref("pending");
+ const dataInsigniaType = ref([])
// เรียกราชชื่อการเสนอขอ
const fetchData = async (data: any) => {
if (data !== null) {
@@ -124,6 +125,10 @@ export const useInsigniaDataStore = defineStore("insignia", () => {
rows.value = listinsignia.value;
}
};
+ // ประเภทเครื่องราช
+ function fetchInsigniaType(data: any) {
+ dataInsigniaType.value = data
+ }
// ประเภทลูกจ้าง
const profileType = (val: string) => {
@@ -167,11 +172,13 @@ export const useInsigniaDataStore = defineStore("insignia", () => {
employeeClass,
employeeClassOps,
fetchDataInsignia,
+ fetchInsigniaType,
isLock,
requestId,
roleUser,
requestStatus,
optionReport,
- convertStatus
+ convertStatus,
+ dataInsigniaType,
};
});
diff --git a/src/modules/08_registryEmployee/components/DialogSendToCommand.vue b/src/modules/08_registryEmployee/components/DialogSendToCommand.vue
index 47d37e976..5dc935268 100644
--- a/src/modules/08_registryEmployee/components/DialogSendToCommand.vue
+++ b/src/modules/08_registryEmployee/components/DialogSendToCommand.vue
@@ -1,403 +1,476 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ props.rowIndex + 1 }}
+
+
+ {{ props.row.fullname }}
+
+
+
+
+
+ {{ props.row.draftOrganizationOrganization ?? "-" }}
+
+
+ {{ props.row.draftPositionEmployee ?? "-" }}
+
+
+
+
+
+
+
+ {{ props.row.oc ?? "-" }}
+
+
+ {{ props.row.position ?? "-" }}
+
+
+
-
-
-
-
-
-
-
-
-
+
+ {{ props.row.amount }}
+
+
+ {{ props.row.govAge }}
+
+
+ {{ props.row.dateAppoint }}
+
+
+ {{ props.row.dateStart }}
+
+
+ {{ props.row.salaryDate }}
+
+
+ {{ props.row.refSalary }}
+
+
+ {{ props.row.age }}
+
+
+ {{ props.row.fullnameOld }}
+
+
+ {{ props.row.createdAt }}
+
+
+ {{ props.row.isLeave }}
+
-
- {{ props.rowIndex + 1 }}
-
-
- {{ props.row.fullname }}
-
-
-
-
-
- {{ props.row.draftOrganizationOrganization ?? "-" }}
-
-
- {{ props.row.draftPositionEmployee ?? "-" }}
-
-
-
-
-
-
-
- {{ props.row.oc ?? "-" }}
-
-
- {{ props.row.position ?? "-" }}
-
-
-
+
+ {{ props.row.leaveDateOrder }}
+
+
+ {{ props.row.statustext }}
+
+
+
+
+
-
- {{ props.row.amount }}
-
-
- {{ props.row.govAge }}
-
-
- {{ props.row.dateAppoint }}
-
-
- {{ props.row.dateStart }}
-
-
- {{ props.row.salaryDate }}
-
-
- {{ props.row.refSalary }}
-
-
- {{ props.row.age }}
-
-
- {{ props.row.fullnameOld }}
-
-
- {{ props.row.createdAt }}
-
-
- {{ props.row.isLeave }}
-
-
-
- {{ props.row.leaveDateOrder }}
-
-
- {{ props.row.statustext }}
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+
+
+
+
+
+
diff --git a/src/modules/08_registryEmployee/views/Main.vue b/src/modules/08_registryEmployee/views/Main.vue
index f80d1d0e3..be6e43e2e 100644
--- a/src/modules/08_registryEmployee/views/Main.vue
+++ b/src/modules/08_registryEmployee/views/Main.vue
@@ -310,7 +310,7 @@ const deleteData = async (id: string) => {
// **** เริ่มในส่วนของการเลือกตำแหน่ง ***//
const rowsPosition = ref
([]); // รายการข้อมูลในตารางกำหนดตำแหน่ง
const filters = ref([]);
-const filterKeyword2 = ref("");
+const filterKeyword2 = ref("");
const modal = ref(false); // เปิด-ปิด dialod กำหนดตำแหน่ง
const selectedPosition = ref([]); // เก็บตำแหน่งที่เลือก
@@ -970,7 +970,7 @@ const showEmployeeTemp = async () => {
dense
ref="filterRef"
debounce="300"
- :model-value="filterKeyword2"
+ v-model="filterKeyword2"
placeholder="ค้นหา"
style="width: 850px; max-width: auto"
>
diff --git a/src/modules/10_order/store.ts b/src/modules/10_order/store.ts
index 1a7f9e7da..168f0f029 100644
--- a/src/modules/10_order/store.ts
+++ b/src/modules/10_order/store.ts
@@ -45,13 +45,19 @@ export const useOrderPlacementDataStore = defineStore("placementOrder", () => {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
(item) => item.orderTypeValue === filter_1
);
- } else if (filter_1 !== "" && filter_2 !== "ทั้งหมด" && filterYear === null) {
+ } else if (
+ filter_1 !== "" &&
+ filter_2 !== "ทั้งหมด" &&
+ filterYear === null
+ ) {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
- (item) => item.orderTypeValue === filter_1 && item.OrderStatus === filter_2
+ (item) =>
+ item.orderTypeValue === filter_1 && item.OrderStatus === filter_2
);
} else if (filter_1 !== "" && filter_2 === "ทั้งหมด" && filterYear !== 0) {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
- (item) => item.orderTypeValue === filter_1 && item.fiscalYear === filterYear
+ (item) =>
+ item.orderTypeValue === filter_1 && item.fiscalYear === filterYear
);
} else if (filter_1 === "" && filter_2 !== "ทั้งหมด" && filterYear === 0) {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
@@ -61,27 +67,32 @@ export const useOrderPlacementDataStore = defineStore("placementOrder", () => {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
(item) => item.fiscalYear === filterYear
);
- } else if (filter_1 === "" && filter_2 !== "ทั้งหมด" && filterYear !== null) {
+ } else if (
+ filter_1 === "" &&
+ filter_2 !== "ทั้งหมด" &&
+ filterYear !== null
+ ) {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
(item) =>
item.OrderStatus === filter_2 && item.fiscalYear === filterYear
);
} else if (filter_1 !== "" && filter_2 !== "ทั้งหมด" && filterYear === 0) {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
- (item) => item.OrderStatus === filter_2 && item.orderTypeValue === filter_1
+ (item) =>
+ item.OrderStatus === filter_2 && item.orderTypeValue === filter_1
);
- } else if (filter_1 !== "" && filter_2 !== "ทั้งหมด" && filterYear !== null) {
+ } else if (
+ filter_1 !== "" &&
+ filter_2 !== "ทั้งหมด" &&
+ filterYear !== null
+ ) {
DataMainUpdateOrder.value = DataMainOrigOrder.value.filter(
(item) =>
item.orderTypeValue === filter_1 &&
item.OrderStatus === filter_2 &&
item.fiscalYear === filterYear
);
- } else if (
- filter_1 == "" &&
- filter_2 == "ทั้งหมด" &&
- filterYear !== null
- ) {
+ } else if (filter_1 == "" && filter_2 == "ทั้งหมด" && filterYear !== null) {
DataMainUpdateOrder.value = DataMainOrigOrder.value;
}
};
@@ -144,6 +155,6 @@ export const useOrderPlacementDataStore = defineStore("placementOrder", () => {
DataUpdateOrder,
DataMainYearSetOrder,
DataMainOrder,
- nameOrderFilter
+ nameOrderFilter,
};
-});
\ No newline at end of file
+});
diff --git a/src/modules/10_order/views/Main.vue b/src/modules/10_order/views/Main.vue
index 275398d09..d712763f9 100644
--- a/src/modules/10_order/views/Main.vue
+++ b/src/modules/10_order/views/Main.vue
@@ -18,15 +18,6 @@ const mixin = useCounterMixin();
const { showLoader, hideLoader, messageError, date2Thai } = mixin;
const DataStore = useOrderPlacementDataStore();
-const OpsFilterYear = ref({
- fiscalyearOP: [],
-});
-const OpsFilterOrderType = ref({
- OrderTypeOption: [],
-});
-const OpsFilterOrderStatus = ref({
- OrderStatusOption: [],
-});
const pagination = ref({
descending: true,
page: 1,
@@ -153,16 +144,6 @@ const OriginalDataFetch = async () => {
OrderType: e.orderTypeName,
orderTypeValue: e.orderTypeValue,
}));
- // OpsFilterYear.value.fiscalYear = res.data.result.map((e: any) => ({
- // fiscalYear: Number(e.fiscalYear),
- // }));
- OpsFilterOrderStatus.value.OrderStatus = res.data.result.map(
- (e: any) => ({
- OrderStatus: e.orderStatusName,
- })
- );
- console.log(fiscalyear.value);
- console.log(OrderStatus.value);
})
.catch((e: any) => {
messageError($q, e);
@@ -199,22 +180,26 @@ const redirectToPage = (id?: string, status?: string) => {
const clickAdd = () => {
router.push({ name: "OrderAdd" });
};
-const Ops = ref({
- fiscalyearOP: [],
-});
// รายการข้อมูลปีงบประมาณ
const fiscalyear = ref(0);
-const fiscalyearOP = ref([{ id: 0, name: "ทั้งหมด" }]);
+const fiscalyearOP = ref([{ id: 0, name: "ทั้งหมด" }]);
const fiscalyearFilter1 = ref([]);
const fiscalYearFilter = async () => {
await http.get(config.API.yearOptionsOrder()).then((res) => {
const response = res.data.result;
fiscalyearOP.value = [{ id: 0, name: "ทั้งหมด" }];
- fiscalyearOP.value.push(...response);
+ response.map((r: any) => {
+ fiscalyearOP.value.push({ id: r.id, name: r.name.toString() });
+ });
fiscalyearFilter1.value = [{ id: 0, name: "ทั้งหมด" }];
- fiscalyearFilter1.value.push(...response);
+ response.map((r: any) => {
+ fiscalyearFilter1.value.push({
+ id: r.id,
+ name: r.name.toString(),
+ });
+ });
});
};
@@ -300,7 +285,7 @@ const filterSelector = (val: any, update: Function, refData: string) => {
case "fiscalyearOP":
update(() => {
fiscalyearOP.value = fiscalyearFilter1.value.filter(
- (v: any) => v.name.valueOf(val) > -1
+ (v: any) => v.name.indexOf(val) > -1
);
});
break;
@@ -347,6 +332,7 @@ const paginationLabel = (start: string, end: string, total: string) => {
option-value="id"
option-label="name"
lazy-rules
+ use-input
hide-bottom-space
:readonly="false"
:borderless="false"
@@ -356,7 +342,13 @@ const paginationLabel = (start: string, end: string, total: string) => {
@filter="(inputValue:any,
doneFn:Function) => filterSelector(inputValue, doneFn,'fiscalyearOP'
) "
- />
+ >
+
+
+ ไม่มีข้อมูล
+
+
+
{
@filter="(inputValue:any,
doneFn:Function) => filterSelector(inputValue, doneFn,'OrderTypeOption'
) "
- />
+ >
+
+
+
+ ไม่มีข้อมูล
+
+
+
+
{
@filter="(inputValue:any,
doneFn:Function) => filterSelector(inputValue, doneFn,'OrderStatusOption'
) "
- />
+ >
+
+
+
+ ไม่มีข้อมูล
+
+
+
+