เพิม interface row
This commit is contained in:
parent
c42400e57c
commit
d94531204a
12 changed files with 99 additions and 133 deletions
|
|
@ -19,7 +19,15 @@ const myFormPosition = ref<any>();
|
||||||
const selected = ref<string>("");
|
const selected = ref<string>("");
|
||||||
const selectedFile = ref<string>("");
|
const selectedFile = ref<string>("");
|
||||||
const dataRespone = ref<any>();
|
const dataRespone = ref<any>();
|
||||||
|
const personal = ref<any>();
|
||||||
|
const expanded = ref<string[]>([]);
|
||||||
|
const treeData = ref<Array<any>>([]);
|
||||||
|
const placementPosition = ref<any>([]);
|
||||||
|
const search = ref<string>("");
|
||||||
|
const filterRef = ref<any>(null);
|
||||||
|
const id = ref<string>("");
|
||||||
|
|
||||||
|
const editDataStatus = ref<boolean>(false);
|
||||||
// Set form field
|
// Set form field
|
||||||
let dataForm = reactive({
|
let dataForm = reactive({
|
||||||
personalId: "",
|
personalId: "",
|
||||||
|
|
@ -53,7 +61,7 @@ const fetchPublishFile = async () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
// โหลดข้อมูลโครงสร้างจาก json
|
// โหลดข้อมูลโครงสร้างจาก json
|
||||||
const treeData = ref<Array<any>>([]);
|
|
||||||
const loadTreeData = async () => {
|
const loadTreeData = async () => {
|
||||||
expanded.value = [];
|
expanded.value = [];
|
||||||
await http
|
await http
|
||||||
|
|
@ -75,7 +83,6 @@ const loadTreeData = async () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
function filterByPersonIdNull(obj: any) {
|
function filterByPersonIdNull(obj: any) {
|
||||||
// console.log(obj);
|
|
||||||
if (obj.name === null && obj.isCondition != true) {
|
if (obj.name === null && obj.isCondition != true) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
@ -87,7 +94,7 @@ function filterByPersonIdNull(obj: any) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// โหลด position
|
// โหลด position
|
||||||
const placementPosition = ref<any>([]);
|
|
||||||
const fetchplacementPosition = async () => {
|
const fetchplacementPosition = async () => {
|
||||||
await http
|
await http
|
||||||
.get(config.API.apppointmentPosition())
|
.get(config.API.apppointmentPosition())
|
||||||
|
|
@ -99,13 +106,7 @@ const fetchplacementPosition = async () => {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const search = ref<string>("");
|
|
||||||
//reset Tree Filter
|
|
||||||
const filterRef = ref<any>(null);
|
|
||||||
// const resetFilter = () => {
|
|
||||||
// search.value = "";
|
|
||||||
// filterRef.value.focus();
|
|
||||||
// };
|
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
personalId: String,
|
personalId: String,
|
||||||
|
|
@ -121,23 +122,19 @@ const myFilterMethod = (node: any, filter: string) => {
|
||||||
const filt = filter;
|
const filt = filter;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
// ((node.name && node.name == null) || !node.name) &&
|
|
||||||
(node.name && node.name.indexOf(filt) > -1) ||
|
(node.name && node.name.indexOf(filt) > -1) ||
|
||||||
(node.organizationName && node.organizationName.indexOf(filt) > -1) ||
|
(node.organizationName && node.organizationName.indexOf(filt) > -1) ||
|
||||||
(node.positionNum && node.positionNum.indexOf(filt) > -1) ||
|
(node.positionNum && node.positionNum.indexOf(filt) > -1) ||
|
||||||
(node.positionName && node.positionName.indexOf(filt) > -1) ||
|
(node.positionName && node.positionName.indexOf(filt) > -1) ||
|
||||||
(node.governmentCode &&
|
(node.governmentCode && node.governmentCode.toString().indexOf(filt) > -1) ||
|
||||||
node.governmentCode.toString().indexOf(filt) > -1) ||
|
|
||||||
(node.agency && node.agency.indexOf(filt) > -1) ||
|
(node.agency && node.agency.indexOf(filt) > -1) ||
|
||||||
(node.government && node.government.indexOf(filt) > -1) ||
|
(node.government && node.government.indexOf(filt) > -1) ||
|
||||||
(node.department && node.department.indexOf(filt) > -1) ||
|
(node.department && node.department.indexOf(filt) > -1) ||
|
||||||
(node.pile && node.pile.indexOf(filt) > -1) ||
|
(node.pile && node.pile.indexOf(filt) > -1) ||
|
||||||
(node.organizationShortName &&
|
(node.organizationShortName && node.organizationShortName.indexOf(filt) > -1) ||
|
||||||
node.organizationShortName.indexOf(filt) > -1) ||
|
|
||||||
(node.positionSideName && node.positionSideName.indexOf(filt) > -1) ||
|
(node.positionSideName && node.positionSideName.indexOf(filt) > -1) ||
|
||||||
(node.executivePosition && node.executivePosition.indexOf(filt) > -1) ||
|
(node.executivePosition && node.executivePosition.indexOf(filt) > -1) ||
|
||||||
(node.executivePositionSide &&
|
(node.executivePositionSide && node.executivePositionSide.indexOf(filt) > -1) ||
|
||||||
node.executivePositionSide.indexOf(filt) > -1) ||
|
|
||||||
(node.positionLevel && node.positionLevel.indexOf(filt) > -1)
|
(node.positionLevel && node.positionLevel.indexOf(filt) > -1)
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
@ -150,17 +147,14 @@ const validateData = async () => {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
const id = ref<string>("");
|
|
||||||
const saveAppoint = async () => {
|
|
||||||
console.log("save", dataForm);
|
|
||||||
|
|
||||||
|
const saveAppoint = async () => {
|
||||||
myFormPosition.value.validate().then(async (result: boolean) => {
|
myFormPosition.value.validate().then(async (result: boolean) => {
|
||||||
if (props.personalId !== undefined) {
|
if (props.personalId !== undefined) {
|
||||||
id.value = props.personalId.toString();
|
id.value = props.personalId.toString();
|
||||||
}
|
}
|
||||||
if (result) {
|
if (result) {
|
||||||
const dataAppoint = await {
|
const dataAppoint = await {
|
||||||
// personalId: props.personalId,
|
|
||||||
recruitDate: dataForm.containDate,
|
recruitDate: dataForm.containDate,
|
||||||
posNoId: dataForm.posNoId,
|
posNoId: dataForm.posNoId,
|
||||||
positionId: dataForm.positionId,
|
positionId: dataForm.positionId,
|
||||||
|
|
@ -168,16 +162,11 @@ const saveAppoint = async () => {
|
||||||
positionLineId: dataForm.positionLineId,
|
positionLineId: dataForm.positionLineId,
|
||||||
positionPathSideId: dataForm.positionPathSideId,
|
positionPathSideId: dataForm.positionPathSideId,
|
||||||
positionTypeId: dataForm.positionTypeId,
|
positionTypeId: dataForm.positionTypeId,
|
||||||
// salaryAmount: dataForm.salaryAmount,
|
|
||||||
// mouthSalaryAmount: dataForm.mouthSalaryAmount,
|
|
||||||
// positionSalaryAmount: dataForm.positionSalaryAmount,
|
|
||||||
};
|
};
|
||||||
console.log("save appoint===>", dataAppoint);
|
|
||||||
showLoader();
|
showLoader();
|
||||||
await http
|
await http
|
||||||
.put(config.API.appointmentPosition(id.value), dataAppoint)
|
.put(config.API.appointmentPosition(id.value), dataAppoint)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
console.log("respone=>", res);
|
|
||||||
success($q, "บันทึกสำเร็จ");
|
success($q, "บันทึกสำเร็จ");
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
|
|
@ -185,7 +174,6 @@ const saveAppoint = async () => {
|
||||||
})
|
})
|
||||||
.finally(async () => {
|
.finally(async () => {
|
||||||
await closeAndClear();
|
await closeAndClear();
|
||||||
// await resetFilter();
|
|
||||||
await fetchPublishFile();
|
await fetchPublishFile();
|
||||||
await loadTreeData();
|
await loadTreeData();
|
||||||
await fetchplacementPosition();
|
await fetchplacementPosition();
|
||||||
|
|
@ -195,10 +183,7 @@ const saveAppoint = async () => {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const editDataStatus = ref<boolean>(false);
|
|
||||||
const clickEditRow = () => {
|
|
||||||
editDataStatus.value = true;
|
|
||||||
};
|
|
||||||
const closeModal = () => {
|
const closeModal = () => {
|
||||||
if (editDataStatus.value == true) {
|
if (editDataStatus.value == true) {
|
||||||
dialogConfirm(
|
dialogConfirm(
|
||||||
|
|
@ -227,9 +212,6 @@ const closeAndClear = async () => {
|
||||||
dataForm.positionLineId = "";
|
dataForm.positionLineId = "";
|
||||||
dataForm.positionPathSideId = "";
|
dataForm.positionPathSideId = "";
|
||||||
dataForm.positionTypeId = "";
|
dataForm.positionTypeId = "";
|
||||||
// dataForm.salaryAmount = null;
|
|
||||||
// dataForm.mouthSalaryAmount = null;
|
|
||||||
// dataForm.positionSalaryAmount = null;
|
|
||||||
};
|
};
|
||||||
// ตำแหน่งเลขที่
|
// ตำแหน่งเลขที่
|
||||||
const posNoOptions = ref<Object[]>([
|
const posNoOptions = ref<Object[]>([
|
||||||
|
|
@ -275,9 +257,7 @@ const positionLevelOptions = ref<Object[]>([
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const selectedPosition = async (data: any) => {
|
const selectedPosition = async (data: any) => {
|
||||||
console.log("selecteds", data);
|
|
||||||
if (data.name == null && selected.value != data.keyId) {
|
if (data.name == null && selected.value != data.keyId) {
|
||||||
// console.log("selecteds", data);
|
|
||||||
|
|
||||||
editDataStatus.value = true;
|
editDataStatus.value = true;
|
||||||
selected.value = data.keyId;
|
selected.value = data.keyId;
|
||||||
|
|
@ -359,51 +339,40 @@ const selectedPosition = async (data: any) => {
|
||||||
dataForm.positionPathSideId = "";
|
dataForm.positionPathSideId = "";
|
||||||
dataForm.positionTypeId = "";
|
dataForm.positionTypeId = "";
|
||||||
}
|
}
|
||||||
console.log("dataForm", dataForm);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const checkPosition = (val: string) => {
|
const checkPosition = (val: string) => {
|
||||||
const num = placementPosition.value.findIndex((e: string) => e === val);
|
const num = placementPosition.value.findIndex((e: string) => e === val);
|
||||||
return num;
|
return num;
|
||||||
};
|
};
|
||||||
const personal = ref<any>();
|
|
||||||
const expanded = ref<string[]>([]);
|
|
||||||
|
|
||||||
watch(props, () => {
|
watch(props, () => {
|
||||||
expanded.value = [];
|
expanded.value = [];
|
||||||
const dataPersonal = props.personal;
|
const dataPersonal = props.personal;
|
||||||
console.log(props.personal);
|
|
||||||
|
|
||||||
if (dataPersonal) {
|
if (dataPersonal) {
|
||||||
dataPersonal.map((data: any) => {
|
dataPersonal.map((data: any) => {
|
||||||
personal.value = data;
|
personal.value = data;
|
||||||
});
|
});
|
||||||
console.log("personal", personal.value);
|
|
||||||
}
|
}
|
||||||
// console.log("draft===>", personal.value.draft);
|
|
||||||
|
|
||||||
if (personal.value) {
|
if (personal.value) {
|
||||||
// const findData = dataRespone.value.find(findByPerson);
|
|
||||||
let findData: any = null;
|
let findData: any = null;
|
||||||
dataRespone.value.map((x: any) => {
|
dataRespone.value.map((x: any) => {
|
||||||
findData = findByPerson(x);
|
findData = findByPerson(x);
|
||||||
// console.log(findData);
|
|
||||||
|
|
||||||
if (findData != null) {
|
if (findData != null) {
|
||||||
// console.log("findData===>", findData);
|
|
||||||
selectedPosition(findData);
|
selectedPosition(findData);
|
||||||
for (let i = 3; i <= findData.keyId.length; i += 2) {
|
for (let i = 3; i <= findData.keyId.length; i += 2) {
|
||||||
expanded.value.push(findData.keyId.slice(0, i));
|
expanded.value.push(findData.keyId.slice(0, i));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// loadTreeData();
|
|
||||||
// selectedPosition(findData.children.children.children)
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
function findByPerson(element: any): any {
|
function findByPerson(element: any): any {
|
||||||
// console.log("searchTree element===>", element)
|
|
||||||
if (
|
if (
|
||||||
element.positionNumId &&
|
element.positionNumId &&
|
||||||
element.positionLineId === personal.value.positionLineId &&
|
element.positionLineId === personal.value.positionLineId &&
|
||||||
|
|
@ -472,10 +441,6 @@ function findByPerson(element: any): any {
|
||||||
<div class="text-weight-medium">
|
<div class="text-weight-medium">
|
||||||
{{ prop.node.organizationName }}
|
{{ prop.node.organizationName }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!--แสดง Total Count PositionNum-->
|
|
||||||
<!-- <q-badge rounded color="grey-2" text-color="dark"
|
|
||||||
:label="prop.node.totalPositionCount" /> -->
|
|
||||||
<q-badge
|
<q-badge
|
||||||
v-if="prop.node.totalPositionVacant > 0"
|
v-if="prop.node.totalPositionVacant > 0"
|
||||||
rounded
|
rounded
|
||||||
|
|
@ -605,8 +570,7 @@ function findByPerson(element: any): any {
|
||||||
:model-value="
|
:model-value="
|
||||||
date2Thai(new Date(dataForm.containDate))
|
date2Thai(new Date(dataForm.containDate))
|
||||||
"
|
"
|
||||||
:rules="[ (val: string) =>!!val ||`${'วันที่รายงานตัว'}`,
|
:rules="[ (val: string) =>!!val ||`${'วันที่รายงานตัว'}`]"
|
||||||
]"
|
|
||||||
:label="`${'วันที่รายงานตัว'}`"
|
:label="`${'วันที่รายงานตัว'}`"
|
||||||
hide-bottom-space
|
hide-bottom-space
|
||||||
>
|
>
|
||||||
|
|
@ -711,55 +675,6 @@ function findByPerson(element: any): any {
|
||||||
map-options
|
map-options
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="col-sx-12 col-sm-12 col-md-12">
|
|
||||||
<q-separator inset size="2px" class="q-my-md" />
|
|
||||||
</div> -->
|
|
||||||
<!-- <div class="col-xs-6 col-sm-6 col-md-6">
|
|
||||||
<q-input
|
|
||||||
outlined
|
|
||||||
dense
|
|
||||||
lazy-rules
|
|
||||||
v-model="dataForm.salaryAmount"
|
|
||||||
:rules="[(val) => !!val || `${'กรุณากรอกเงินเดือน'}`]"
|
|
||||||
:label="`${'เงินเดือน'}`"
|
|
||||||
@update:modelValue="clickEditRow"
|
|
||||||
type="number"
|
|
||||||
hide-bottom-space
|
|
||||||
/>
|
|
||||||
</div> -->
|
|
||||||
|
|
||||||
<!-- <div class="col-xs-6 col-sm-6 col-md-6">
|
|
||||||
<q-input
|
|
||||||
outlined
|
|
||||||
dense
|
|
||||||
lazy-rules
|
|
||||||
v-model="dataForm.positionSalaryAmount"
|
|
||||||
:rules="[
|
|
||||||
(val) => !!val || `${'กรุณากรอกเงินประจำตำแหน่ง'}`,
|
|
||||||
]"
|
|
||||||
:label="`${'เงินประจำตำแหน่ง'}`"
|
|
||||||
@update:modelValue="clickEditRow"
|
|
||||||
type="number"
|
|
||||||
hide-bottom-space
|
|
||||||
/>
|
|
||||||
</div> -->
|
|
||||||
|
|
||||||
<!-- <div class="col-xs-6 col-sm-6 col-md-6">
|
|
||||||
<q-input
|
|
||||||
outlined
|
|
||||||
dense
|
|
||||||
lazy-rules
|
|
||||||
v-model="dataForm.mouthSalaryAmount"
|
|
||||||
:rules="[
|
|
||||||
(val) =>
|
|
||||||
!!val || `${'กรุณากรอกเงินค่าตอบแทนรายเดือน'}`,
|
|
||||||
]"
|
|
||||||
:label="`${'เงินค่าตอบแทนรายเดือน'}`"
|
|
||||||
@update:modelValue="clickEditRow"
|
|
||||||
type="number"
|
|
||||||
hide-bottom-space
|
|
||||||
/>
|
|
||||||
</div> -->
|
|
||||||
</div>
|
</div>
|
||||||
</q-scroll-area>
|
</q-scroll-area>
|
||||||
</q-card>
|
</q-card>
|
||||||
|
|
@ -793,6 +708,5 @@ function findByPerson(element: any): any {
|
||||||
background: #a3d3fb48 !important;
|
background: #a3d3fb48 !important;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
border: 1px solid rgba(175, 185, 196, 0.217);
|
border: 1px solid rgba(175, 185, 196, 0.217);
|
||||||
/* box-shadow: 1px 1px 7px 1px rgba(41, 95, 255, 0.15) !important; */
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,8 @@ import { useCounterMixin } from "@/stores/mixin";
|
||||||
import { useTransferDataStore } from "@/modules/05_placement/store"
|
import { useTransferDataStore } from "@/modules/05_placement/store"
|
||||||
import Dialogbody from "@/modules/05_placement/components/AppointMent/Dialogbody.vue"
|
import Dialogbody from "@/modules/05_placement/components/AppointMent/Dialogbody.vue"
|
||||||
import DialogOrgTree from "@/modules/05_placement/components/AppointMent/AppointmentModal.vue";
|
import DialogOrgTree from "@/modules/05_placement/components/AppointMent/AppointmentModal.vue";
|
||||||
|
import type { listAppointType,resData,orgFilter } from "@/modules/05_placement/interface/response/AppointMent"
|
||||||
|
import type { OpType } from "@/modules/05_placement/interface/response/Main"
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
|
||||||
|
|
@ -26,16 +27,16 @@ const {
|
||||||
} = mixin;
|
} = mixin;
|
||||||
|
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const rows = ref<any>([]);
|
const rows = ref<listAppointType[]>([]);
|
||||||
const rows2 = ref<any>([]);
|
const rows2 = ref<listAppointType[]>([]);
|
||||||
const modalTree = ref<boolean>(false);
|
const modalTree = ref<boolean>(false);
|
||||||
const personal = ref<any[]>([]);
|
const personal = ref<any[]>([]);
|
||||||
const personalId = ref<string>("");
|
const personalId = ref<string>("");
|
||||||
const filterKeyword = ref<string>("");
|
const filterKeyword = ref<string>("");
|
||||||
const filterKeyword2 = ref<string>("");
|
const filterKeyword2 = ref<string>("");
|
||||||
const filterRef = ref<any>(null);
|
const filterRef = ref<any>(null);
|
||||||
const listRecevice = ref<any>([]);
|
const listRecevice = ref<resData[]>([]);
|
||||||
const optionsType = ref<any[]>([]);
|
const optionsType = ref<OpType[]>([]);
|
||||||
const type = ref<string>("");
|
const type = ref<string>("");
|
||||||
|
|
||||||
const visibleColumns = ref<string[]>([
|
const visibleColumns = ref<string[]>([
|
||||||
|
|
@ -147,7 +148,7 @@ const fecthlistappointment = async () => {
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
let response = res.data.result;
|
let response = res.data.result;
|
||||||
listRecevice.value = response;
|
listRecevice.value = response;
|
||||||
rows.value = response.map((e: any) => ({
|
rows.value = response.map((e: resData) => ({
|
||||||
personalId: e.id,
|
personalId: e.id,
|
||||||
citizenId: e.citizenId,
|
citizenId: e.citizenId,
|
||||||
fullname: e.prefix + e.firstname + " " + e.lastname,
|
fullname: e.prefix + e.firstname + " " + e.lastname,
|
||||||
|
|
@ -165,11 +166,10 @@ const fecthlistappointment = async () => {
|
||||||
positionPath: e.positionPath,
|
positionPath: e.positionPath,
|
||||||
status: statusText(e.status),
|
status: statusText(e.status),
|
||||||
createdAt: date2Thai(e.createdAt),
|
createdAt: date2Thai(e.createdAt),
|
||||||
|
|
||||||
birthday: e.dateOfBirth == null ? "-" : date2Thai(e.dateOfBirth),
|
birthday: e.dateOfBirth == null ? "-" : date2Thai(e.dateOfBirth),
|
||||||
}));
|
}));
|
||||||
rows2.value = rows.value.filter(
|
rows2.value = rows.value.filter(
|
||||||
(e: any) =>
|
(e: orgFilter) =>
|
||||||
e.orgName !== null &&
|
e.orgName !== null &&
|
||||||
e.status !== "ส่งรายชื่อไปออกคำสั่ง" &&
|
e.status !== "ส่งรายชื่อไปออกคำสั่ง" &&
|
||||||
e.status !== "ออกคำสั่งเสร็จแล้ว"
|
e.status !== "ออกคำสั่งเสร็จแล้ว"
|
||||||
|
|
@ -189,7 +189,7 @@ const fecthTypeOption = async () => {
|
||||||
.get(config.API.typeOrder())
|
.get(config.API.typeOrder())
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
optionsType.value = res.data.result.filter(
|
optionsType.value = res.data.result.filter(
|
||||||
(e: any) =>
|
(e: OpType) =>
|
||||||
e.commandCode === "C-PM-05" ||
|
e.commandCode === "C-PM-05" ||
|
||||||
e.commandCode === "C-PM-06" ||
|
e.commandCode === "C-PM-06" ||
|
||||||
e.commandCode === "C-PM-07"
|
e.commandCode === "C-PM-07"
|
||||||
|
|
@ -203,7 +203,7 @@ const fecthTypeOption = async () => {
|
||||||
// เปิดโครงสร้าง
|
// เปิดโครงสร้าง
|
||||||
const openModalTree = (id: string) => {
|
const openModalTree = (id: string) => {
|
||||||
personalId.value = id;
|
personalId.value = id;
|
||||||
personal.value = listRecevice.value.filter((e: any) => e.id === id);
|
personal.value = listRecevice.value.filter((e) => e.id === id);
|
||||||
modalTree.value = true;
|
modalTree.value = true;
|
||||||
};
|
};
|
||||||
//เเจ้งเตือนลบข้อมูล
|
//เเจ้งเตือนลบข้อมูล
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,8 @@ import { useRouter } from "vue-router";
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
import { useTransferDataStore } from "@/modules/05_placement/store"
|
import { useTransferDataStore } from "@/modules/05_placement/store"
|
||||||
import type { QTableProps } from "quasar";
|
import type { QTableProps } from "quasar";
|
||||||
import type { listMain,listMainAPI,OpType } from "@/modules/05_placement/interface/response/OhterMain"
|
import type { listMain,listMainAPI } from "@/modules/05_placement/interface/response/OhterMain"
|
||||||
|
import type { OpType } from "@/modules/05_placement/interface/response/Main"
|
||||||
|
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
|
|
||||||
|
|
@ -31,7 +31,7 @@ const filterKeyword = ref<string>("");
|
||||||
const filterKeyword2 = ref<string>("");
|
const filterKeyword2 = ref<string>("");
|
||||||
const filterRef = ref<any>(null);
|
const filterRef = ref<any>(null);
|
||||||
const files = ref<any>();
|
const files = ref<any>();
|
||||||
const listRecevice = ref<any[]>([]);
|
const listRecevice = ref<ResponseData[]>([]);
|
||||||
const filters = ref<ResponseRow[]>([]);
|
const filters = ref<ResponseRow[]>([]);
|
||||||
const rows = ref<ResponseRow[]>([]);
|
const rows = ref<ResponseRow[]>([]);
|
||||||
const mixin = useCounterMixin(); //เรียกฟังก์ชันกลาง
|
const mixin = useCounterMixin(); //เรียกฟังก์ชันกลาง
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ const filterKeyword2 = ref<string>("");
|
||||||
const filterRef = ref<any>(null);
|
const filterRef = ref<any>(null);
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const rows = ref<officerType[]>([]);
|
const rows = ref<officerType[]>([]);
|
||||||
const rows2 = ref<any>([]);
|
const rows2 = ref<officerType[]>([]);
|
||||||
const modal = ref<boolean>(false);
|
const modal = ref<boolean>(false);
|
||||||
|
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@ const filterRef = ref<any>(null);
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
|
||||||
const rows = ref<officerType[]>([]);
|
const rows = ref<officerType[]>([]);
|
||||||
const rows2 = ref<any>([]);
|
const rows2 = ref<officerType[]>([]);
|
||||||
const modal = ref<boolean>(false);
|
const modal = ref<boolean>(false);
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const {
|
const {
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import { useCounterMixin } from "@/stores/mixin";
|
||||||
import { useQuasar } from "quasar";
|
import { useQuasar } from "quasar";
|
||||||
import { useTransferDataStore } from "@/modules/05_placement/store"
|
import { useTransferDataStore } from "@/modules/05_placement/store"
|
||||||
import type { QTableProps } from "quasar";
|
import type { QTableProps } from "quasar";
|
||||||
import type { FormMainProbation, FormMainProbation2 } from "@/modules/05_placement/interface/request/Main";
|
import type { FormMainProbation, FormMainProbation2,mapData } from "@/modules/05_placement/interface/request/Main";
|
||||||
|
|
||||||
import DialogHeader from "@/modules/04_registry/components/DialogHeader.vue";
|
import DialogHeader from "@/modules/04_registry/components/DialogHeader.vue";
|
||||||
import router from "@/router";
|
import router from "@/router";
|
||||||
|
|
@ -296,7 +296,7 @@ const findlist = async (id: string) => {
|
||||||
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: any) => ({
|
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,
|
||||||
|
|
|
||||||
|
|
@ -65,9 +65,20 @@ interface FormProbationPersonal {
|
||||||
order_number: string,
|
order_number: string,
|
||||||
probation_status: string
|
probation_status: string
|
||||||
}
|
}
|
||||||
export type { FormPlacementMainData };
|
interface mapData {
|
||||||
export type { FormOrderPlacementMainData };
|
id:string
|
||||||
export type { FormMainProbation };
|
fullname:string
|
||||||
export type { FormMainProbation2 };
|
position:string
|
||||||
export type { FormProbationDetail };
|
positionEmployeeLevel:string
|
||||||
export type { FormProbationPersonal };
|
oc:string
|
||||||
|
probation:string
|
||||||
|
}
|
||||||
|
export type {
|
||||||
|
FormPlacementMainData,
|
||||||
|
FormOrderPlacementMainData,
|
||||||
|
FormMainProbation,
|
||||||
|
FormMainProbation2,
|
||||||
|
FormProbationDetail,
|
||||||
|
FormProbationPersonal,
|
||||||
|
mapData,
|
||||||
|
};
|
||||||
|
|
|
||||||
38
src/modules/05_placement/interface/response/AppointMent.ts
Normal file
38
src/modules/05_placement/interface/response/AppointMent.ts
Normal file
|
|
@ -0,0 +1,38 @@
|
||||||
|
interface listAppointType {
|
||||||
|
personalId:string
|
||||||
|
citizenId:number
|
||||||
|
fullname:string
|
||||||
|
organizationName:string
|
||||||
|
orgName:string
|
||||||
|
organizationShortName:string
|
||||||
|
positionNumber:string
|
||||||
|
positionPath:string
|
||||||
|
status:string
|
||||||
|
createdAt:string
|
||||||
|
birthday:string
|
||||||
|
}
|
||||||
|
|
||||||
|
interface resData {
|
||||||
|
id:string
|
||||||
|
citizenId:number
|
||||||
|
prefix:string
|
||||||
|
firstname:string
|
||||||
|
lastname:string
|
||||||
|
organizationName:string
|
||||||
|
organizationShortName:string
|
||||||
|
positionNumber:string
|
||||||
|
positionPath:string
|
||||||
|
status:string
|
||||||
|
createdAt:Date
|
||||||
|
dateOfBirth:Date
|
||||||
|
}
|
||||||
|
interface orgFilter{
|
||||||
|
orgName:string
|
||||||
|
status:string
|
||||||
|
}
|
||||||
|
|
||||||
|
export type {
|
||||||
|
listAppointType,
|
||||||
|
resData,
|
||||||
|
orgFilter
|
||||||
|
}
|
||||||
|
|
@ -1 +1,6 @@
|
||||||
export type {};
|
interface OpType {
|
||||||
|
commandCode:string
|
||||||
|
}
|
||||||
|
export type {
|
||||||
|
OpType
|
||||||
|
};
|
||||||
|
|
|
||||||
|
|
@ -44,11 +44,9 @@ interface listMainAPI {
|
||||||
statustext:string
|
statustext:string
|
||||||
createdAt:Date
|
createdAt:Date
|
||||||
}
|
}
|
||||||
interface OpType {
|
|
||||||
commandCode:string
|
|
||||||
}
|
|
||||||
export type {
|
export type {
|
||||||
listMain,
|
listMain,
|
||||||
listMainAPI,
|
listMainAPI,
|
||||||
OpType
|
|
||||||
}
|
}
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
interface officerType {
|
interface officerType {
|
||||||
no: number;
|
|
||||||
id: string;
|
id: string;
|
||||||
prefix: string;
|
prefix: string;
|
||||||
firstName: string;
|
firstName: string;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue