แก้ประเภทคำสั่งของวินัย และสีปุ่ม
This commit is contained in:
parent
c32340737d
commit
b13f8c0697
2 changed files with 23 additions and 13 deletions
|
|
@ -82,7 +82,6 @@ const Ordersave = async () => {
|
||||||
const body = {
|
const body = {
|
||||||
id,
|
id,
|
||||||
};
|
};
|
||||||
console.log(body);
|
|
||||||
showLoader();
|
showLoader();
|
||||||
await http
|
await http
|
||||||
.put(config.API.reportresult(type.value as string), body)
|
.put(config.API.reportresult(type.value as string), body)
|
||||||
|
|
@ -123,14 +122,21 @@ const fecthTypeOption = async () => {
|
||||||
await http
|
await http
|
||||||
.get(config.API.typeOrder())
|
.get(config.API.typeOrder())
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
optionsType.value = res.data.result.filter(
|
if (props.title == "ส่งไปออกคำสั่งลงโทษทางวินัย") {
|
||||||
(e: OpType) =>
|
optionsType.value = res.data.result.filter(
|
||||||
e.commandCode === "C-PM-19" ||
|
(e: OpType) =>
|
||||||
e.commandCode === "C-PM-20" ||
|
e.commandCode === "C-PM-19" ||
|
||||||
e.commandCode === "C-PM-27" ||
|
e.commandCode === "C-PM-20" ||
|
||||||
e.commandCode === "C-PM-28" ||
|
e.commandCode === "C-PM-27" ||
|
||||||
e.commandCode === "C-PM-29"
|
e.commandCode === "C-PM-28" ||
|
||||||
);
|
e.commandCode === "C-PM-29"
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
optionsType.value = res.data.result.filter(
|
||||||
|
(e: OpType) =>
|
||||||
|
e.commandCode === "C-PM-30" || e.commandCode === "C-PM-31"
|
||||||
|
);
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
|
|
@ -151,10 +157,14 @@ watchEffect(() => {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
onMounted(async () => {
|
watch(
|
||||||
await fecthTypeOption();
|
() => props.title,
|
||||||
});
|
() => {
|
||||||
|
fecthTypeOption();
|
||||||
|
}
|
||||||
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<q-dialog v-model="props.Modal">
|
<q-dialog v-model="props.Modal">
|
||||||
<q-card style="width: 1200px; max-width: 80vw">
|
<q-card style="width: 1200px; max-width: 80vw">
|
||||||
|
|
|
||||||
|
|
@ -287,7 +287,7 @@ watch(
|
||||||
<q-btn
|
<q-btn
|
||||||
v-if="status === 'DONE'"
|
v-if="status === 'DONE'"
|
||||||
label="ส่งไปออกคำสั่งงดโทษ/เพิ่มโทษ"
|
label="ส่งไปออกคำสั่งงดโทษ/เพิ่มโทษ"
|
||||||
color="public"
|
color="blue-6"
|
||||||
@click="sentIssue('ส่งไปออกคำสั่งงดโทษ/เพิ่มโทษ')"
|
@click="sentIssue('ส่งไปออกคำสั่งงดโทษ/เพิ่มโทษ')"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue