แก้วินัย
This commit is contained in:
parent
dd9d4de08a
commit
18e1e0d2bd
4 changed files with 277 additions and 211 deletions
|
|
@ -3,7 +3,12 @@ import { onMounted, reactive, ref } from "vue";
|
|||
import Form from "@/modules/11_discipline/components/2_InvestigateFacts/Form.vue";
|
||||
import type { FormData } from "@/modules/11_discipline/interface/request/investigate";
|
||||
import { useRouter, useRoute } from "vue-router";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useQuasar } from "quasar";
|
||||
|
||||
const $q = useQuasar()
|
||||
const mixin = useCounterMixin()
|
||||
const { dialogConfirm } = mixin
|
||||
const router = useRouter();
|
||||
const route = useRoute();
|
||||
const id = ref<string>(route.params.id as string);
|
||||
|
|
@ -45,7 +50,6 @@ const fetchData = async () => {
|
|||
data.daysExtend = null;
|
||||
data.statusResult = "ไม่ระบุ";
|
||||
data.causeText = "";
|
||||
data.complaintStatus = "NEW";
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -58,6 +62,16 @@ async function onSubmit(id:string){
|
|||
router.push(`/discipline/investigatefacts`);
|
||||
};
|
||||
|
||||
/** ยืนยัน ส่งไปสอบสวน */
|
||||
function sentInvestigate(){
|
||||
dialogConfirm($q,()=> confirmSentInvestigate(),'ยืนยันส่งไปสอบสวน','ต้องการยืนยันส่งไปสอบสวนใช่หรือไม่?')
|
||||
}
|
||||
|
||||
/** ฟังชั่น ส่งไปสอบสวน*/
|
||||
function confirmSentInvestigate(){
|
||||
console.log('sent')
|
||||
}
|
||||
|
||||
/** โหลดข้อมูลเมื่อเข้าหน้านี้ */
|
||||
onMounted(() => {
|
||||
fetchData();
|
||||
|
|
@ -81,19 +95,9 @@ onMounted(() => {
|
|||
<q-space />
|
||||
<div class="q-gutter-x-sm">
|
||||
<q-btn
|
||||
v-if="data.complaintStatus === 'NEW'"
|
||||
label="มีมูลส่งไปออกคำสั่ง"
|
||||
label="ส่งไปสอบสวน"
|
||||
color="public"
|
||||
/>
|
||||
<q-btn
|
||||
v-if="data.complaintStatus === 'NEW'"
|
||||
label="ยุติเรื่อง"
|
||||
color="red-7"
|
||||
/>
|
||||
<q-btn
|
||||
v-if="data.complaintStatus === 'STOP'"
|
||||
label="ยกเลิกการยุติเรื่อง"
|
||||
color="red-7"
|
||||
@click="sentInvestigate"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue