api get,delete listOrder
This commit is contained in:
parent
482e44815e
commit
d6c5aef69e
4 changed files with 97 additions and 208 deletions
|
|
@ -511,9 +511,10 @@ const clickEditRow = () => (editRow.value = true);
|
|||
onMounted(async () => {
|
||||
if (orderId) {
|
||||
await fetchdetailOrder();
|
||||
} else {
|
||||
fecthTypeOption();
|
||||
fecthExamRoundOption();
|
||||
}
|
||||
fecthTypeOption();
|
||||
fecthExamRoundOption();
|
||||
|
||||
// const data = localStorage.getItem("formData");
|
||||
// if (data) {
|
||||
|
|
@ -537,6 +538,20 @@ onMounted(async () => {
|
|||
const fetchdetailOrder = async () => {
|
||||
showLoader();
|
||||
console.log(orderId);
|
||||
let orderIdString = orderId.toString();
|
||||
await http
|
||||
.get(config.API.detailOrder(orderIdString))
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
fecthTypeOption();
|
||||
fecthExamRoundOption();
|
||||
});
|
||||
};
|
||||
const fecthTypeOption = async () => {
|
||||
await http
|
||||
|
|
@ -567,7 +582,7 @@ const submit = async () => {
|
|||
orderBy: byOrder.value,
|
||||
signatoryBy: nameCommand.value,
|
||||
signatoryPosition: positionCommand.value,
|
||||
examRound: test.value,
|
||||
examRound: examRound.value,
|
||||
registerPosition: position.value,
|
||||
conclusionRegisterNo: register.value,
|
||||
conclusionRegisterDate: dateRegister.value,
|
||||
|
|
@ -586,9 +601,7 @@ const submit = async () => {
|
|||
persistent: true,
|
||||
}).onOk(async () => {
|
||||
showLoader();
|
||||
// localStorage.setItem("formData", JSON.stringify(formdata));
|
||||
createListOrder(formdata);
|
||||
// next();
|
||||
});
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue