fixing bug
This commit is contained in:
parent
d2e87e2f8b
commit
2b596355eb
2 changed files with 22 additions and 23 deletions
|
|
@ -64,8 +64,7 @@ async function onCilckNextStep() {
|
||||||
const functionCreateDoc: (() => Promise<void>) | null =
|
const functionCreateDoc: (() => Promise<void>) | null =
|
||||||
store.step === 1
|
store.step === 1
|
||||||
? await saveStep1
|
? await saveStep1
|
||||||
:
|
: store.step === 3
|
||||||
store.step === 3
|
|
||||||
? await saveStep3
|
? await saveStep3
|
||||||
: store.step === 7
|
: store.step === 7
|
||||||
? await saveStep7
|
? await saveStep7
|
||||||
|
|
@ -231,7 +230,7 @@ async function updateCheckSpec(data: FormSpec) {
|
||||||
*/
|
*/
|
||||||
function updateFormDetail(data: any) {
|
function updateFormDetail(data: any) {
|
||||||
formDetail.value = data;
|
formDetail.value = data;
|
||||||
console.log("🚀 ~ updateFormDetail ~ data:", data)
|
console.log("🚀 ~ updateFormDetail ~ data:", data);
|
||||||
}
|
}
|
||||||
/** function เช็คการการคุณสมบัติ*/
|
/** function เช็คการการคุณสมบัติ*/
|
||||||
function checkSelectForm() {
|
function checkSelectForm() {
|
||||||
|
|
@ -250,7 +249,7 @@ function checkSelectForm() {
|
||||||
}
|
}
|
||||||
/** function บันทักตรวจสอบคุณสมบัติ*/
|
/** function บันทักตรวจสอบคุณสมบัติ*/
|
||||||
async function saveStep1() {
|
async function saveStep1() {
|
||||||
const salaries = formDetail.value.trainings.map((e: any) => ({
|
const salaries = formDetail.value.salaries.map((e: any) => ({
|
||||||
amount: e.amount,
|
amount: e.amount,
|
||||||
date: e.date,
|
date: e.date,
|
||||||
mouthSalaryAmount: e.mouthSalaryAmount ? e.mouthSalaryAmount : 0,
|
mouthSalaryAmount: e.mouthSalaryAmount ? e.mouthSalaryAmount : 0,
|
||||||
|
|
|
||||||
|
|
@ -75,7 +75,7 @@ async function fetchCheckStep(id: string) {
|
||||||
}
|
}
|
||||||
|
|
||||||
async function saveEvaluation(formSpec: any, detail: any) {
|
async function saveEvaluation(formSpec: any, detail: any) {
|
||||||
const salaries = detail.trainings.map((e: any) => ({
|
const salaries = detail.salaries.map((e: any) => ({
|
||||||
amount: e.amount,
|
amount: e.amount,
|
||||||
date: e.date,
|
date: e.date,
|
||||||
mouthSalaryAmount: e.mouthSalaryAmount ? e.mouthSalaryAmount : 0,
|
mouthSalaryAmount: e.mouthSalaryAmount ? e.mouthSalaryAmount : 0,
|
||||||
|
|
@ -183,23 +183,23 @@ async function nextCheckDoc(type: string) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
async function nextCheckDoc2(data: any) {
|
// async function nextCheckDoc2(data: any) {
|
||||||
const body = {
|
// const body = {
|
||||||
commanderAboveFullnameDoc2: data.commanderAboveFullname,
|
// commanderAboveFullnameDoc2: data.commanderAboveFullname,
|
||||||
commanderAbovePositionDoc2: data.commanderAbovePosition,
|
// commanderAbovePositionDoc2: data.commanderAbovePosition,
|
||||||
commanderFullnameDoc2: data.commanderFullname,
|
// commanderFullnameDoc2: data.commanderFullname,
|
||||||
commanderPositionDoc2: data.commanderPosition,
|
// commanderPositionDoc2: data.commanderPosition,
|
||||||
};
|
// };
|
||||||
showLoader();
|
// showLoader();
|
||||||
await http
|
// await http
|
||||||
.put(config.API.evaluationCheckdocV1(store.evaluateId), body)
|
// .put(config.API.evaluationCheckdocV1(store.evaluateId), body)
|
||||||
.then((res) => {})
|
// .then((res) => {})
|
||||||
.catch((err) => {})
|
// .catch((err) => {})
|
||||||
.finally(() => {
|
// .finally(() => {
|
||||||
hideLoader();
|
// hideLoader();
|
||||||
fetchCheckStatus();
|
// fetchCheckStatus();
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
|
|
||||||
async function nextPrepareDoc2() {
|
async function nextPrepareDoc2() {
|
||||||
showLoader();
|
showLoader();
|
||||||
|
|
@ -218,6 +218,6 @@ export default {
|
||||||
saveEvaluation,
|
saveEvaluation,
|
||||||
nextPrapare,
|
nextPrapare,
|
||||||
nextCheckDoc,
|
nextCheckDoc,
|
||||||
nextCheckDoc2,
|
// nextCheckDoc2,
|
||||||
nextPrepareDoc2,
|
nextPrepareDoc2,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue