API PosEmpTemp

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2025-02-20 15:21:53 +07:00
parent 28b25d31e2
commit 4ef4d225b9
9 changed files with 52 additions and 36 deletions

View file

@ -64,8 +64,8 @@ async function onSubmit() {
showLoader();
try {
const url = !isEditCheck.value
? config.API.orgEmployeePos
: config.API.orgEmployeePosById(props?.data?.id);
? config.API.orgEmployeePosTemp
: config.API.orgEmployeePosByIdTemp(props?.data?.id);
await http[!isEditCheck.value ? "post" : "put"](url, body);
await props.emitSearch?.(formDataPos.posName, "positionName");
await success($q, "บันทีกข้อมูลสำเร็จ");
@ -95,7 +95,7 @@ function close() {
async function fetchType() {
showLoader();
await http
.get(config.API.orgEmployeeType)
.get(config.API.orgEmployeeTypeTemp)
.then((res) => {
posTypeMain.value = res.data.result;
posTypeOp.value = res.data.result.map((e: OptionType) => ({