diff --git a/src/modules/05_placement/components/probation/FormAssign.vue b/src/modules/05_placement/components/probation/FormAssign.vue index 7077f3c97..de45c7617 100644 --- a/src/modules/05_placement/components/probation/FormAssign.vue +++ b/src/modules/05_placement/components/probation/FormAssign.vue @@ -21,10 +21,7 @@ const dataEdit = async (id: string) => { const data = putDataEdit(id); await http .put(config.API.saveEditAssign(id), data) - .then((res) => { - // console.log("success put==>",res) - // console.log("save") - }) + .then((res) => {}) .catch((e) => {}) .finally(async () => { status.value = false; @@ -37,7 +34,6 @@ const saveEdit = (id: string) => { }; const edit = () => { status.value = true; - // console.log(status.value); }; const cancel = () => { status.value = false; @@ -305,12 +301,8 @@ const getAssignNew = async (id: string) => { value: data.assign_month, label: `${data.assign_month} เดือน`, }; - // console.log("Assign-New", data); monthOp.push(monthOption); monthSelect.value = `${data.assign_month} เดือน`; - // OPcaretaker.value = data.mentors; - // OPcommander.value = [data.commander]; - // OPchairman.value = [data.chairman]; fullname.value = data.person.name; position.value = data.person.OrganizationOrganization; }); @@ -685,7 +677,6 @@ const getAssign = async () => { await http.get(config.API.probationsGetAssign(assignId.value)).then((res) => { status.value = false; const data = res.data.data; - // console.log("ASSIGN-list ==>", data); fullname.value = data.profile.name; position.value = data.profile.OrganizationOrganization; date_start.value = data.assign.date_start; diff --git a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluate.vue b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluate.vue index f85c64750..88ae71e04 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluate.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluate.vue @@ -34,7 +34,6 @@ const saveEdit = (id: string) => { const edit = () => { status.value = true; - // console.log(status.value); }; const cancel = () => { @@ -104,10 +103,6 @@ const list2_3 = [ ]; onMounted(async () => { - // if (props.action == 'add') { - // fecthFormdata(); - // } - // console.log("props===>", props) if (props.tab && props.action == "edit") { evaluate_no.value = Number(props.tab.charAt(4)); dataArr.value = await props.data; @@ -120,19 +115,9 @@ watch(props, async () => { evaluate_no.value = Number(props.tab.charAt(4)); dataArr.value = await props.data; fecthAssign(); - // console.log("props===>", props); } }); -// onMounted(async () => { -// if (props.tab !== undefined) { -// round.value = props.tab.charAt(4); -// // fetchEvaluate(assignId.value, round.value); -// } -// fecthAssign(assignId.value); -// // console.log(round.value); -// // console.log(assignId.value); -// }); const fecthAssign = async () => { showLoader(); await http @@ -149,11 +134,6 @@ const fecthAssign = async () => { start_date.value = res.data.data.start_date; date_finish.value = res.data.data.end_date; } - // console.log(props.tab, res.data.data.evaluate_no); - - // if (res.data.data.evaluate_no > evaluate_no.value) { - // await fetchEvaluate(assignId.value, evaluate_no.value); - // } }) .catch((e) => { messageError($q, e); @@ -166,13 +146,6 @@ const fecthAssign = async () => { }); }; const fetchEvaluate = async () => { - // showLoader(); - // await http - // .get(config.API.evaluatecommader(assignId.value, evaluate_no.value)) - // .then((res: any) => { - // console.log(res); - // let data = res.data.data.evaluate; - // console.log(data); let data = await dataArr.value; evaluate_id.value = data.id; start_date.value = data.date_start; @@ -215,22 +188,8 @@ const fetchEvaluate = async () => { etc2.value = true; } else etc2.value = false; status.value = false; - // }) - // .catch((e) => { - // console.log(e); - - // if (e.data.message !== "Data not found!") { - // messageError($q, e); - // } - // }) - // .finally(() => { - // hideLoader(); - // }); }; -// const dateToday = ref(new Date("10-10-2023")); -// const dateEnd = ref(new Date("12-10-2023")); -// const period = ref(1); const Autherise = ref(null); const dateAutherise = ref(new Date()); const option = ref([]); @@ -348,7 +307,6 @@ const save = () => { data ) .then((res: any) => { - // console.log(res); status.value = false; success($q, "บันทึกสำเร็จ"); }) diff --git a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateAdd.vue b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateAdd.vue index ea8562145..a1def3014 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateAdd.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateAdd.vue @@ -92,7 +92,6 @@ const fecthAssign = async (id: string) => { await http .get(config.API.evaluateCreate(id)) .then(async (res: any) => { - console.log(res); person.value = res.data.data.person; assign.value = res.data.data.assign; commander.value = res.data.data.commander; @@ -223,7 +222,6 @@ const putformData = () => { await http .post(config.API.createformCommader(assignId.value), data) .then((res: any) => { - // console.log(res); success($q, "บันทึกสำเร็จ"); router.push( `/probation/detail/${personalId.value}/${assignId.value}` @@ -233,30 +231,6 @@ const putformData = () => { messageError($q, e); }); }); - - // $q.dialog({ - // title: "ยืนยันการบันทึกข้อมูล", - // message: "ต้องการบันทึกข้อมูลนี้ใช่หรือไม่ ?", - // cancel: { - // flat: true, - // color: "negative", - // }, - // persistent: true, - // }) - // .onOk(async () => { - // console.log("บันทึกข้อมูล", data); - // await http - // .post(config.API.createformCommader(assignId.value), data) - // .then((res: any) => { - // console.log(res); - // success($q, "บันทึกสำเร็จ"); - // }) - // .catch((e: any) => { - // messageError($q, e); - // }); - // }) - // .onCancel(() => {}) - // .onDismiss(() => {}); }; diff --git a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScore.vue b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScore.vue index 65c790917..c5502b13a 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScore.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScore.vue @@ -31,7 +31,6 @@ const saveEdit = (id: string) => { }; const edit = () => { status.value = true; - // console.log(status.value); }; const cancel = () => { status.value = false; @@ -57,10 +56,6 @@ const props = defineProps({ }); onMounted(async () => { - // if (props.action == 'add') { - // fecthFormdata(); - // } - // console.log("props===>", props) if (props.tab && props.action == "edit") { evaluate_no.value = Number(props.tab.charAt(4)); dataArr.value = await props.data; @@ -73,24 +68,16 @@ watch(props, async () => { evaluate_no.value = Number(props.tab.charAt(4)); dataArr.value = await props.data; fecthAssign(); - // console.log("props===>", props); } }); -// onMounted(() => { -// if (props.tab !== undefined) { -// round.value = props.tab.charAt(4); -// // fetchEvaluate(assignId.value, round.value); -// } -// fecthAssign(assignId.value); -// }); + const fecthAssign = async () => { showLoader(); await http .get(config.API.evaluateChairman(assignId.value)) .then(async (res: any) => { - // console.log(res); if (props.action == "add") { assign.value = res.data.data.assign; evaluate_no.value = res.data.data.evaluate_no; @@ -114,11 +101,6 @@ const fecthAssign = async () => { const fetchEvaluate = async () => { showLoader(); - // await http - // .get(config.API.evaluateRoundChairman(assignId.value, evaluate_no.value)) - // .then((res: any) => { - // let data = res.data.data.evaluate; - // console.log(data); let data = await dataArr.value; evaluate_id.value = data.id; @@ -447,14 +429,12 @@ const putformData = () => { }; dialogConfirm($q, async () => { - console.log("data==>", data); await http .put( config.API.editFormEvaluateChairman(assignId.value, evaluate_id.value), data ) .then((res: any) => { - // console.log(res); status.value = false; success($q, "บันทึกสำเร็จ"); router.push(`/probation/detail/${personalId.value}/${assignId.value}`); @@ -463,33 +443,6 @@ const putformData = () => { messageError($q, e); }); }); - // $q.dialog({ - // title: "ยืนยันการบันทึกข้อมูล", - // message: "ต้องการบันทึกข้อมูลนี้ใช่หรือไม่ ?", - // cancel: { - // flat: true, - // color: "negative", - // }, - // persistent: true, - // }) - // .onOk(async () => { - // console.log("บันทึกข้อมูล", data); - // await http - // .post(config.API.createformChairman(assignId.value), data) - // .then((res: any) => { - // console.log(res); - // success($q, "บันทึกสำเร็จ"); - // }) - // .catch((e: any) => { - // console.log(e); - // messageError($q, e); - // }) - // .finally(() => { - // fetchEvaluate(assignId.value, round.value); - // }); - // }) - // .onCancel(() => {}) - // .onDismiss(() => {}); }; diff --git a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScoreAdd.vue b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScoreAdd.vue index 677ac3270..e62370d5a 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScoreAdd.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/FormEvaluateScoreAdd.vue @@ -49,7 +49,6 @@ const fecthAssign = async (id: string) => { await http .get(config.API.evaluateChairman(id)) .then(async (res: any) => { - console.log(res); person.value = res.data.data.person; assign.value = res.data.data.assign; evaluate_no.value = res.data.data.evaluate_no; @@ -343,7 +342,6 @@ const putformData = () => { await http .post(config.API.createformChairman(assignId.value), data) .then((res: any) => { - // console.log(res); success($q, "บันทึกสำเร็จ"); router.push( `/probation/detail/${personalId.value}/${assignId.value}` diff --git a/src/modules/05_placement/components/probation/FormEvaluation/FormReport.vue b/src/modules/05_placement/components/probation/FormEvaluation/FormReport.vue index 6718c86ad..518c7ef97 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/FormReport.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/FormReport.vue @@ -27,13 +27,12 @@ const assign = ref([]); const mentors = ref([]); const commander = ref([]); const status = ref(true); -// const evaluate = ref([]); + const saveEdit = (id: string) => { dialogConfirm($q, () => console.log("save")); }; const edit = () => { status.value = true; - // console.log(status.value); }; const cancel = () => { status.value = false; @@ -48,7 +47,6 @@ const fecthAssign = async (id: string) => { await http .get(config.API.evaluateReportcreate(id)) .then((res) => { - console.log(res); assign.value = res.data.data.assign; mentors.value = res.data.data.mentors; date_start.value = assign.value.date_start; @@ -62,7 +60,6 @@ const fecthAssign = async (id: string) => { optionDirector.value = mentors.value; }) .catch((e) => { - console.log(e); messageError($q, e); }) .finally(() => { @@ -74,7 +71,7 @@ const date_finish = ref(); const develop = ref(); const result = ref(); const reson = ref(""); -const chairman_dated = ref(""); +const chairman_dated = ref(); const director1_dated = ref(""); const director2_dated = ref(""); const fullname = ref("") @@ -83,7 +80,6 @@ const fecthResult = async (id: string) => { .get(config.API.createformReport(id)) .then((res: any) => { let data = res.data.data.evaluate; - console.log(data); fullname.value = res.data.data.profile.name; date_start.value = data.date_start; date_finish.value = data.date_finish; @@ -97,7 +93,6 @@ const fecthResult = async (id: string) => { action.value = "edit"; }) .catch((e) => { - console.log(e); }); }; @@ -162,8 +157,6 @@ const postData = async () => { director1_dated: director1_dated.value, director2_dated: director2_dated.value, }; - - // console.log("postData===>", data); await http .post(config.API.createformReport(assignId.value), data) .then(() => { @@ -171,7 +164,6 @@ const postData = async () => { router.push(`/probation/detail/${personalId.value}/${assignId.value}`); }) .catch((e: any) => { - console.log(e); messageError($q, e); }); }; diff --git a/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResult.vue b/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResult.vue index 7e2506f56..89282d810 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResult.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResult.vue @@ -42,7 +42,6 @@ const checkArray = ref(0); const edit = () => { status.value = true; - // console.log(status.value); }; const cancel = () => { @@ -70,9 +69,7 @@ watch(props, async () => { if (props.tab && props.action == "edit") { evaluate_no.value = Number(props.tab.charAt(4)); dataArr.value = await props.data; - console.log(dataArr.value) fecthFormdata(); - // console.log("props===>", props.data); } }); @@ -80,7 +77,6 @@ const fecthFormdata = async () => { await http .get(config.API.formevaluateRecord(assignId.value)) .then(async (res: any) => { - // console.log(res); if (props.action == "add") { evaluate_no.value = res.data.data.evaluate_no; start_date.value = res.data.data.start_date; @@ -112,7 +108,6 @@ const fecthFormdata = async () => { // } }) .catch((e: any) => { - console.log(e); }) .finally(() => { if (props.action == "edit") { @@ -123,12 +118,6 @@ const fecthFormdata = async () => { const fecthFormRound = async () => { showLoader(); try { - console.log(dataArr.value); - - // await http - // .get(config.API.formevaluateround(assignId.value, round.value)) - // .then(async(res: any) => { - // console.log("dataArr===>", dataArr.value); let data = await dataArr.value; evaluate_id.value = data.id; start_date.value = data.date_start; @@ -181,15 +170,6 @@ const fecthFormRound = async () => { } status.value = false; - console.log(etc.value); - - // }) - // .catch((e) => { - // console.log(e); - // }) - // .finally(() => { - // hideLoader(); - // }); setTimeout(() => { hideLoader(); }, 1000); @@ -442,7 +422,6 @@ const saveformdata = async (data: any) => { await http .post(config.API.createformevaluate(assignId.value), data) .then((res: any) => { - // console.log(res); success($q, "บันทึกสำเร็จ"); router.push(`/probation/detail/${personalId.value}/${assignId.value}`); }) diff --git a/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResultAdd.vue b/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResultAdd.vue index 082509b7f..1f08ae5ca 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResultAdd.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/FormSaveResultAdd.vue @@ -42,7 +42,6 @@ const fecthFormdata = async (id: string) => { await http .get(config.API.formevaluateRecord(id)) .then((res: any) => { - console.log(res); evaluate_no.value = res.data.data.evaluate_no; start_date.value = res.data.data.start_date; date_finish.value = res.data.data.end_date; @@ -57,18 +56,17 @@ const fecthFormdata = async (id: string) => { res.data.data.assign_output.forEach((e: any) => { list1_2.push({ id: "", label: "" }) }); - evaluate_expenct_level.value = res.data.data.assign_output.map((e) => ({ + evaluate_expenct_level.value = res.data.data.assign_output.map((e:any) => ({ id: e.id, labal: e.output_desc, })); - evaluate_ouptut.value = res.data.data.assign_output.map((e) => ({ + evaluate_ouptut.value = res.data.data.assign_output.map((e:any) => ({ id: e.id, text: "", })); checkArray.value = list1_1.value.length; }) .catch((e: any) => { - console.log(e); }); }; @@ -305,7 +303,6 @@ const saveformdata = async (data: any) => { await http .post(config.API.createformevaluate(assignId.value), data) .then((res: any) => { - // console.log(res); success($q, "บันทึกสำเร็จ"); router.push( `/probation/detail/${personalId.value}/${assignId.value}` diff --git a/src/modules/05_placement/components/probation/FormEvaluation/Template1.vue b/src/modules/05_placement/components/probation/FormEvaluation/Template1.vue index db4e8ecf3..3913719a7 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/Template1.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/Template1.vue @@ -47,7 +47,6 @@ const fecthAssign = async (id: string) => { dataArrayNumber.value = 1; }) .catch((e: any) => { - // console.log(e); messageError($q, e); }) .finally(() => { diff --git a/src/modules/05_placement/components/probation/FormEvaluation/Template2.vue b/src/modules/05_placement/components/probation/FormEvaluation/Template2.vue index 2665f4fea..6f27dd2bc 100644 --- a/src/modules/05_placement/components/probation/FormEvaluation/Template2.vue +++ b/src/modules/05_placement/components/probation/FormEvaluation/Template2.vue @@ -50,10 +50,8 @@ const fecthAssign = async (id: string) => { fullname.value = res.data.data.person.name; tabs.value = evaluate.value; dataArrayNumber.value = 1; - console.log(fullname.value); }) .catch((e: any) => { - // console.log(e); messageError($q, e); }) .finally(() => { diff --git a/src/modules/05_placement/components/probation/MainProbation.vue b/src/modules/05_placement/components/probation/MainProbation.vue index 1bfaca722..951ce7300 100644 --- a/src/modules/05_placement/components/probation/MainProbation.vue +++ b/src/modules/05_placement/components/probation/MainProbation.vue @@ -230,7 +230,6 @@ const getpersonalList = async () => { order_number: item.order_number, probation_status: item.probation_status, })); - console.log("(data)", data); }) .catch(() => {}) .finally(() => { @@ -266,7 +265,6 @@ const findlist = async (id: string) => { criterias: data, }) .then((res) => { - // console.log("res:", res); rows2.value = res.data.result.map((e: any) => ({ id: e.id, fullname: e.fullname, @@ -307,11 +305,9 @@ const clickAdd = (id: string) => { const postData = { personal_id: id, }; - // console.log("postData:", postData); await http .post(config.API.personalAdd(), postData) .then((res) => { - // console.log("res:", res); getpersonalList(); }) .catch((e) => { diff --git a/src/modules/05_placement/components/probation/ProbationDetail.vue b/src/modules/05_placement/components/probation/ProbationDetail.vue index be02db5f5..960f6a2eb 100644 --- a/src/modules/05_placement/components/probation/ProbationDetail.vue +++ b/src/modules/05_placement/components/probation/ProbationDetail.vue @@ -91,7 +91,6 @@ const rows = ref([]); const clickAdd = () => {}; const clickSelect = (id: string) => { - // console.log(route.fullPath); router.push(`${route.fullPath}/${id}`); }; @@ -115,7 +114,6 @@ const getAssignList = async () => { await http .get(config.API.probationGetAssignList(personalId.value)) .then((res) => { - console.log("LIST ===>", res.data.data); const data = res.data.data; rows.value = data.map((item: FormProbationDetail) => ({ id: item.id, @@ -143,8 +141,6 @@ const getpersonalList = async () => { position_level.value = data.position_level; organization.value = data.organization; probation_status.value = data.probation_status; - - console.log("(data)", data); }) .catch(() => {}) .finally(() => { diff --git a/src/modules/05_placement/components/probation/SummaryScore.vue b/src/modules/05_placement/components/probation/SummaryScore.vue index 12a79c496..b1cfeebf2 100644 --- a/src/modules/05_placement/components/probation/SummaryScore.vue +++ b/src/modules/05_placement/components/probation/SummaryScore.vue @@ -68,7 +68,6 @@ const saveEdit = (id: string) => { }; const edit = () => { status.value = true; - // console.log(status.value); }; const cancel = () => { status.value = false; @@ -110,28 +109,6 @@ const getReportScore = async () => { onMounted(() => { getReportScore(); }); - -// const fecthResult = async (id: string) => { -// await http -// .get(config.API.createformReport(id)) -// .then((res: any) => { -// let data = res.data.data.evaluate; -// console.log(data); -// date_start.value = data.date_start; -// date_finish.value = data.date_finish; -// develop.value = Number(data.develop_complete); -// result.value = Number(data.pass_result); -// reson.value = data.reson; -// chairman_dated.value = data.chairman_dated; -// director1_dated.value = data.director1_dated; -// director2_dated.value = data.director2_dated; -// status.value = false; -// action.value = 'edit'; -// }) -// .catch((e) => { -// console.log(e); -// }); -// };