ปรับโครงสร้างและเปลี่ยนสถานะทดลองงาน

This commit is contained in:
Warunee Tamkoo 2024-06-20 11:44:17 +07:00
parent 8d438e9bc7
commit 4c0c0551f8
3 changed files with 37 additions and 29 deletions

View file

@ -327,22 +327,22 @@ async function filterKeyword2Fn(page: number) {
* @param id string
* @param data type
*/
async function fecthlistProbation(id: string, data: any) {
try {
probationlist.value = [];
const res = await http.post(
config.API.profileSearchNewOcIdType(id, "officer"),
{
criterias: data,
}
);
return res.data.result;
} catch (err) {
messageError($q, err);
} finally {
hideLoader();
}
}
// async function fecthlistProbation(id: string, data: any) {
// try {
// probationlist.value = [];
// const res = await http.post(
// config.API.profileSearchNewOcIdType(id, "officer"),
// {
// criterias: data,
// }
// );
// return res.data.result;
// } catch (err) {
// messageError($q, err);
// } finally {
// hideLoader();
// }
// }
/**
* นหาขอมลตามไอด
@ -389,9 +389,16 @@ function clickAdd(data: any) {
await http
.post(config.API.personalAdd(), data)
.then(() => {
getpersonalList();
success($q, "เพิ่มข้อมูลสำเร็จ");
.then(async () => {
await http
.get(config.API.orgProfileStatus(data.id))
.then((res) => {
getpersonalList();
success($q, "เพิ่มข้อมูลสำเร็จ");
})
.catch((e) => {
messageError($q, e);
});
})
.catch((e) => {
messageError($q, e);