รวมหน้าบรรจุ

This commit is contained in:
Warunee Tamkoo 2023-07-12 14:50:35 +07:00
parent 5533f0512d
commit 8eee779e14
4 changed files with 387 additions and 1447 deletions

View file

@ -3,14 +3,16 @@ const placement = `${env.API_URI}/Placement/placement`
const orgTree = `${env.API_URI_ORG_TREE}`;
export default {
MainDetail: (year: number) => `${placement}/exam/${year}`,
yearOptions: () => `${placement}/fiscal`,
redirectToPage: (examId: string) => `${placement}/pass/${examId}`,
disclaimF: () => `${placement}/pass/disclaim`,
defermentF: () => `${placement}/pass/deferment`,
getStatCard: (examId: string) => `${placement}/pass/stat/${examId}`,
getDatapersonal: (id: string) => `${placement}/personal/${id}`,
putProperty: (id: string) => `${placement}/property/${id}`,
orgTree: orgTree,
placementPass: () => `${placement}/pass`
}
MainDetail: (year: number) => `${placement}/exam/${year}`,
yearOptions: () => `${placement}/fiscal`,
redirectToPage: (examId: string) => `${placement}/pass/${examId}`,
disclaimF: () => `${placement}/pass/disclaim`,
defermentF: () => `${placement}/pass/deferment`,
getStatCard: (examId: string) => `${placement}/pass/stat/${examId}`,
getDatapersonal: (id: string) => `${placement}/personal/${id}`,
putProperty: (id: string) => `${placement}/property/${id}`,
orgTree: orgTree,
placementPass: () => `${placement}/pass`,
placementDefermentInfo: (id: string) => `${placement}/pass/deferment/${id}`,
placementDisclaimInfo: (id: string) => `${placement}/pass/disclaim/${id}`,
};

File diff suppressed because it is too large Load diff

View file

@ -4,26 +4,23 @@ import DialogHeader from "@/modules/05_placement/components/pass/DialogHeader.vu
import { useQuasar } from "quasar";
import DialogFooter from "@/modules/05_placement/components/pass/DialogFooter.vue";
import type { QTableProps } from "quasar";
import type { CheckboxItem } from "@/modules/05_placement/interface/index/Main";
import { useCounterMixin } from "@/stores/mixin";
import http from "@/plugins/http";
import config from "@/app.config";
import { useRoute } from "vue-router";
const mixin = useCounterMixin(); //
const modal = ref<boolean>();
const { success, showLoader, hideLoader, date2Thai, modalConfirm } = mixin;
const save = ref<boolean>(true);
const fullName = ref<any>()
const props = defineProps({
Modal: Boolean,
close: {
type: Function,
default: () => console.log("not function"),
},
getdetail: {
type: Object,
required: true,
personalId: {
type: String,
default: ""
},
validate: {
type: Function,
@ -31,46 +28,6 @@ const props = defineProps({
},
});
// const getDetailbyId = (props.getdetail) => {
// showLoader();
// // personalId API
// try {
// const response = await http.get(config.API.personalId(id));
// const personalId = response.data.personalId;
// // personalId API
// const organizationResponse = await http.get(config.API.organizationName(personalId));
// const data = organizationResponse.data.result;
// // UI
// uid.value = data.personalId;
// idCard.value = data.idCard;
// fullName.value = "tee";
// dateOfBirth.value = new Date(data.dateOfBirth).toLocaleDateString();
// gender.value = data.gender;
// address.value = data.address;
// education.value = data.education;
// pointA.value = data.pointA;
// pointB.value = data.pointB;
// pointC.value = data.pointC;
// pointTotalA.value = data.pointTotalA;
// pointTotalB.value = data.pointTotalB;
// pointTotalC.value = data.pointTotalC;
// point.value = data.point;
// pointTotal.value = data.pointTotal;
// examNumber.value = data.examNumber;
// examRound.value = data.examRound;
// pass.value = data.pass;
// isProperty.value = data.isProperty;
// } catch (error) {
// messageError($q, error);
// } finally {
// hideLoader();
// }
// };
const rows = ref<any[]>([
]);
//--------------------()------------------------------------//
@ -134,7 +91,7 @@ function isRequired(val: any): boolean | string {
watch(props, () => {
if (props.Modal === true) {
console.log(props.getdetail);
// console.log(props.getdetail);
fetchData();
}
});
@ -143,7 +100,7 @@ const validateData = () => {
const selectedIds = personalForm.value.isProperty;
const selectedItems = personalForm.value.isProperty.filter(
(item) => item.value === true
(item: any) => item.value === true
// selectedIds.includes(item.value)
);
return (
@ -172,10 +129,10 @@ const ClickSave = () => {
const fetchData = async () => {
showLoader();
await http
.get(config.API.getDatapersonal("0a846508-4932-40de-9a9e-5b519492217c"))
.get(config.API.getDatapersonal(props.personalId))
.then((res) => {
personalForm.value = res.data.result;
personalForm.value.education.map((e) => {
personalForm.value.education.map((e: any) => {
rows.value.push({
university: e.name,
degree: e.degree,

View file

@ -50,6 +50,6 @@ interface PartialTableName {
bmaOfficer: string;
number: number;
statusId: string;
disclaim: string;
deferment: string;
}
export type { TableName ,PartialTableName};