Merge branch 'develop' into devTee
This commit is contained in:
commit
cbf94f1daa
13 changed files with 106 additions and 94 deletions
|
|
@ -51,41 +51,41 @@ const menuList = readonly<any[]>([
|
||||||
path: "dashboard",
|
path: "dashboard",
|
||||||
role: "dashboard",
|
role: "dashboard",
|
||||||
},
|
},
|
||||||
{
|
// {
|
||||||
key: 2,
|
// key: 2,
|
||||||
icon: "o_person",
|
// icon: "o_person",
|
||||||
activeIcon: "person",
|
// activeIcon: "person",
|
||||||
label: "ข้อมูลหลัก",
|
// label: "ข้อมูลหลัก",
|
||||||
path: "metadataNew",
|
// path: "metadataNew",
|
||||||
role: "metadata",
|
// role: "metadata",
|
||||||
children: [
|
// children: [
|
||||||
{
|
// {
|
||||||
key: 2.0,
|
// key: 2.0,
|
||||||
label: "ข้อมูลเกี่ยวกับบุคคล",
|
// label: "ข้อมูลเกี่ยวกับบุคคล",
|
||||||
path: "masterPersonal",
|
// path: "masterPersonal",
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: 2.0,
|
// key: 2.0,
|
||||||
label: "ข้อมูลตำแหน่งข้าราชการ ฯ",
|
// label: "ข้อมูลตำแหน่งข้าราชการ ฯ",
|
||||||
path: "masterPosition",
|
// path: "masterPosition",
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: 2.0,
|
// key: 2.0,
|
||||||
label: "ข้อมูลตำแหน่งลูกจ้างประจำ",
|
// label: "ข้อมูลตำแหน่งลูกจ้างประจำ",
|
||||||
path: "masterPositionEmployee",
|
// path: "masterPositionEmployee",
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: 2.0,
|
// key: 2.0,
|
||||||
label: "ข้อมูลปฏิทินวันหยุด",
|
// label: "ข้อมูลปฏิทินวันหยุด",
|
||||||
path: "masterCalendarWork",
|
// path: "masterCalendarWork",
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: 2.0,
|
// key: 2.0,
|
||||||
label: "ข้อมูลเครื่องราชอิสริยาภรณ์",
|
// label: "ข้อมูลเครื่องราชอิสริยาภรณ์",
|
||||||
path: "masterInsignia",
|
// path: "masterInsignia",
|
||||||
},
|
// },
|
||||||
],
|
// ],
|
||||||
},
|
// },
|
||||||
{
|
{
|
||||||
key: 2,
|
key: 2,
|
||||||
icon: "o_person",
|
icon: "o_person",
|
||||||
|
|
|
||||||
|
|
@ -146,7 +146,8 @@ function onSubmit() {
|
||||||
["org" + type + "RankSub"]:
|
["org" + type + "RankSub"]:
|
||||||
level.value !== 0 ? formData.orgLevelSub : undefined,
|
level.value !== 0 ? formData.orgLevelSub : undefined,
|
||||||
[nameId]: rootId,
|
[nameId]: rootId,
|
||||||
responsibility: formData.responsibility,
|
responsibility:
|
||||||
|
formData.responsibility != null ? formData.responsibility : "",
|
||||||
};
|
};
|
||||||
|
|
||||||
if (actionType.value === "ADD") {
|
if (actionType.value === "ADD") {
|
||||||
|
|
|
||||||
|
|
@ -99,9 +99,6 @@
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { useProfileDataStore } from "@/modules/04_registry/store";
|
|
||||||
const profileStore = useProfileDataStore();
|
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
header: {
|
header: {
|
||||||
type: String,
|
type: String,
|
||||||
|
|
|
||||||
|
|
@ -15,8 +15,8 @@ import type { QForm } from "quasar";
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
import HeaderTop from "@/modules/04_registry/components/Information/top.vue";
|
import HeaderTop from "@/modules/03_recruiting/components/top1.vue";
|
||||||
import ProfileTable from "@/modules/04_registry/components/Table.vue";
|
import ProfileTable from "@/modules/03_recruiting/components/Table1.vue";
|
||||||
|
|
||||||
import { useQuasar } from "quasar";
|
import { useQuasar } from "quasar";
|
||||||
|
|
||||||
|
|
@ -130,7 +130,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "lastUpdatedAt",
|
name: "lastUpdatedAt",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "ว้นที่แก้ไขล่าสุด",
|
label: "วันที่แก้ไขล่าสุด",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
|
|
|
||||||
|
|
@ -224,7 +224,7 @@ watchEffect(() => {
|
||||||
:columns="columns2"
|
:columns="columns2"
|
||||||
:rows="rows2"
|
:rows="rows2"
|
||||||
:filter="filterKeyword2"
|
:filter="filterKeyword2"
|
||||||
row-key="personalId"
|
row-key="profileId"
|
||||||
flat
|
flat
|
||||||
:visible-columns="visibleColumns2"
|
:visible-columns="visibleColumns2"
|
||||||
selection="multiple"
|
selection="multiple"
|
||||||
|
|
|
||||||
|
|
@ -241,7 +241,7 @@ watchEffect(() => {
|
||||||
:columns="columns2"
|
:columns="columns2"
|
||||||
:rows="rows2"
|
:rows="rows2"
|
||||||
:filter="filterKeyword2"
|
:filter="filterKeyword2"
|
||||||
row-key="personalId"
|
row-key="profileId"
|
||||||
flat
|
flat
|
||||||
:visible-columns="visibleColumns2"
|
:visible-columns="visibleColumns2"
|
||||||
selection="multiple"
|
selection="multiple"
|
||||||
|
|
|
||||||
|
|
@ -146,7 +146,7 @@ const addOther = async () => {
|
||||||
let pId: string[] = [];
|
let pId: string[] = [];
|
||||||
let Type = props.type as string;
|
let Type = props.type as string;
|
||||||
selected.value.forEach((e: any) => {
|
selected.value.forEach((e: any) => {
|
||||||
pId.push(e.personalId);
|
pId.push(e.profileId);
|
||||||
});
|
});
|
||||||
let data = {
|
let data = {
|
||||||
id: pId,
|
id: pId,
|
||||||
|
|
|
||||||
|
|
@ -224,7 +224,7 @@ watchEffect(() => {
|
||||||
:columns="columns2"
|
:columns="columns2"
|
||||||
:rows="rows2"
|
:rows="rows2"
|
||||||
:filter="filterKeyword2"
|
:filter="filterKeyword2"
|
||||||
row-key="personalId"
|
row-key="id"
|
||||||
flat
|
flat
|
||||||
:visible-columns="visibleColumns2"
|
:visible-columns="visibleColumns2"
|
||||||
selection="multiple"
|
selection="multiple"
|
||||||
|
|
|
||||||
|
|
@ -173,11 +173,14 @@ const columns2 = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "posLevelName",
|
name: "posLevelName",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "ระดับ",
|
label: "ประเภทตำแหน่ง",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "posLevelName",
|
field: "posLevelName",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
format(val, row) {
|
||||||
|
return row.posTypeName + " (" + row.posLevelName + ")";
|
||||||
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "organizationOrganization",
|
name: "organizationOrganization",
|
||||||
|
|
@ -299,21 +302,21 @@ async function filterKeyword2Fn(page: number) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/** fecth profile */
|
/** fecth profile */
|
||||||
async function fecthlistPersonal() {
|
// async function fecthlistPersonal() {
|
||||||
showLoader();
|
// showLoader();
|
||||||
await http
|
// await http
|
||||||
.get(config.API.profileOrganizRoot)
|
// .get(config.API.profileOrganizRoot)
|
||||||
.then((res) => {
|
// .then((res) => {
|
||||||
const id = res.data.result[0].id;
|
// const id = res.data.result[0].id;
|
||||||
if (id !== "") {
|
// if (id !== "") {
|
||||||
findlist(id);
|
// findlist(id);
|
||||||
}
|
// }
|
||||||
})
|
// })
|
||||||
.catch((e) => {
|
// .catch((e) => {
|
||||||
messageError($q, e);
|
// messageError($q, e);
|
||||||
})
|
// })
|
||||||
.finally(() => {});
|
// .finally(() => {});
|
||||||
}
|
// }
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ส่งข้อมูลเพื่อ รับ res
|
* ส่งข้อมูลเพื่อ รับ res
|
||||||
|
|
@ -341,34 +344,34 @@ async function fecthlistProbation(id: string, data: any) {
|
||||||
* ค้นหาข้อมูลตามไอดี
|
* ค้นหาข้อมูลตามไอดี
|
||||||
* @param id string
|
* @param id string
|
||||||
*/
|
*/
|
||||||
async function findlist(id: string) {
|
// async function findlist(id: string) {
|
||||||
let data: CriteriaType[] = [
|
// let data: CriteriaType[] = [
|
||||||
{ criteriaType: "is_retire", criteriaValue: "false" },
|
// { criteriaType: "is_retire", criteriaValue: "false" },
|
||||||
{ criteriaType: "is_probation", criteriaValue: "true" },
|
// { criteriaType: "is_probation", criteriaValue: "true" },
|
||||||
];
|
// ];
|
||||||
let data2: CriteriaType[] = [
|
// let data2: CriteriaType[] = [
|
||||||
{ criteriaType: "is_retire", criteriaValue: "false" },
|
// { criteriaType: "is_retire", criteriaValue: "false" },
|
||||||
{ criteriaType: "is_probation", criteriaValue: "false" },
|
// { criteriaType: "is_probation", criteriaValue: "false" },
|
||||||
];
|
// ];
|
||||||
let response1 = await fecthlistProbation(id, data);
|
// let response1 = await fecthlistProbation(id, data);
|
||||||
let response2 = await fecthlistProbation(id, data2);
|
// let response2 = await fecthlistProbation(id, data2);
|
||||||
|
|
||||||
response1.forEach((e: any) =>
|
// response1.forEach((e: any) =>
|
||||||
probationlist.value.push({ ...e, probation: true })
|
// probationlist.value.push({ ...e, probation: true })
|
||||||
);
|
// );
|
||||||
response2.forEach((e: any) =>
|
// response2.forEach((e: any) =>
|
||||||
probationlist.value.push({ ...e, probation: false })
|
// probationlist.value.push({ ...e, probation: false })
|
||||||
);
|
// );
|
||||||
rows2.value = probationlist.value.map((e: mapData) => ({
|
// rows2.value = probationlist.value.map((e: mapData) => ({
|
||||||
id: e.id,
|
// id: e.id,
|
||||||
fullname: e.fullname,
|
// fullname: e.fullname,
|
||||||
position: e.position,
|
// position: e.position,
|
||||||
level: e.positionEmployeeLevel,
|
// level: e.positionEmployeeLevel,
|
||||||
organizationOrganization: e.oc,
|
// organizationOrganization: e.oc,
|
||||||
status: e.probation,
|
// status: e.probation,
|
||||||
}));
|
// }));
|
||||||
modal.value = true;
|
// modal.value = true;
|
||||||
}
|
// }
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* เพิ่มข้อมูล ผู้ทดลองปฏิบัติหน้าที่ราชการ
|
* เพิ่มข้อมูล ผู้ทดลองปฏิบัติหน้าที่ราชการ
|
||||||
|
|
|
||||||
|
|
@ -184,7 +184,7 @@ async function searchInput() {
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
const data = res.data.result;
|
const data = res.data.result;
|
||||||
const list = data.map((e: ResponsePreson) => ({
|
const list = data.map((e: ResponsePreson) => ({
|
||||||
personId: e.personId,
|
personId: e.id,
|
||||||
idcard: e.idcard,
|
idcard: e.idcard,
|
||||||
prefix: e.prefix,
|
prefix: e.prefix,
|
||||||
firstName: e.firstName,
|
firstName: e.firstName,
|
||||||
|
|
@ -249,6 +249,7 @@ watch(props.data, async () => {
|
||||||
formData.qualification = props.data.qualification;
|
formData.qualification = props.data.qualification;
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<form @submit.prevent.stop="onValidate">
|
<form @submit.prevent.stop="onValidate">
|
||||||
<q-card bordered>
|
<q-card bordered>
|
||||||
|
|
|
||||||
|
|
@ -33,7 +33,8 @@ interface typeOp {
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ResponsePreson {
|
interface ResponsePreson {
|
||||||
personId: string; //id อ้างอิง profile
|
id?: string; //id อ้างอิง profile
|
||||||
|
personId?: string; //id อ้างอิง profile
|
||||||
idcard: string; //เลขประจำตัวประชาชน
|
idcard: string; //เลขประจำตัวประชาชน
|
||||||
prefix: string; //คำนำหน้า
|
prefix: string; //คำนำหน้า
|
||||||
firstName: string; //ชื่อ
|
firstName: string; //ชื่อ
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ import type {
|
||||||
} from "@/modules/11_discipline/interface/request/director";
|
} from "@/modules/11_discipline/interface/request/director";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
import PopupPersonal from "@/components/Dialogs/PopupPersonal.vue";
|
import PopupPersonal from "@/components/Dialogs/PopupPersonalNew.vue";
|
||||||
|
|
||||||
const modalPersonal = ref<boolean>(false);
|
const modalPersonal = ref<boolean>(false);
|
||||||
const personId = ref<string>("");
|
const personId = ref<string>("");
|
||||||
|
|
@ -207,7 +207,7 @@ async function searchInput() {
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
const data = res.data.result;
|
const data = res.data.result;
|
||||||
const list = data.map((e: ResponsePreson) => ({
|
const list = data.map((e: ResponsePreson) => ({
|
||||||
personId: e.personId,
|
personId: e.id,
|
||||||
idcard: e.idcard,
|
idcard: e.idcard,
|
||||||
prefix: e.prefix,
|
prefix: e.prefix,
|
||||||
firstName: e.firstName,
|
firstName: e.firstName,
|
||||||
|
|
|
||||||
|
|
@ -300,12 +300,12 @@ function deletePos(id: string) {
|
||||||
.delete(config.API.orgEmployeePosById(id))
|
.delete(config.API.orgEmployeePosById(id))
|
||||||
.then(() => {
|
.then(() => {
|
||||||
success($q, "ลบข้อมูลสำเร็จ");
|
success($q, "ลบข้อมูลสำเร็จ");
|
||||||
|
searchInput();
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
messageError($q, err);
|
messageError($q, err);
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
searchInput();
|
|
||||||
hideLoader();
|
hideLoader();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
@ -351,6 +351,15 @@ watch(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => modalAdd.value,
|
||||||
|
() => {
|
||||||
|
if (!modalAdd.value) {
|
||||||
|
dataCopy.value = [];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue