no message
This commit is contained in:
commit
d3ec604478
35 changed files with 2452 additions and 729 deletions
|
|
@ -173,7 +173,6 @@ async function onSubmit(data: any) {
|
|||
.put(config.API.complaintbyId(id.value), data)
|
||||
.then((res) => {
|
||||
success($q, "บันทึกข้อมูลสำเร็จ");
|
||||
router.push(`/discipline/complaints`);
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
|
|
@ -217,9 +216,9 @@ function cancelInvestigate() {
|
|||
function confirmEndInvestigate() {
|
||||
showLoader();
|
||||
http
|
||||
.put(config.API.complaintReject(id.value))
|
||||
.get(config.API.complaintReject(id.value))
|
||||
.then((res) => {
|
||||
success($q, "บันทึกข้อมูลสำเร็จ");
|
||||
success($q, "ยุติเรื่องสำเร็จ");
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
|
|
@ -286,7 +285,7 @@ onMounted(() => {
|
|||
class="q-mr-sm"
|
||||
@click="$router.push(`/discipline/complaints`)"
|
||||
/>
|
||||
<div class="q-ma-none">แก้ไขเรื่องร้องเรียน {{ id }}#id</div>
|
||||
<div class="q-ma-none">แก้ไขเรื่องร้องเรียน</div>
|
||||
<q-space />
|
||||
<div class="q-gutter-x-sm">
|
||||
<q-btn
|
||||
|
|
|
|||
|
|
@ -72,8 +72,6 @@ const props = defineProps({
|
|||
},
|
||||
});
|
||||
|
||||
|
||||
|
||||
const fileListOj = reactive<ArrayFileList>({
|
||||
id: "",
|
||||
pathName: "",
|
||||
|
|
@ -96,12 +94,11 @@ const formData = reactive<FormData>({
|
|||
appellant: "",
|
||||
documentFile: null,
|
||||
status: "",
|
||||
result: '',
|
||||
result: "",
|
||||
persons: [],
|
||||
disciplineComplaintDocs: fileList.value ?? null,
|
||||
});
|
||||
|
||||
|
||||
/** maping ref เข้าตัวแปรเพื่อเตรียมตรวจสอบ */
|
||||
const objectComplaintsRef: MyObjectComplaintsRef = {
|
||||
respondentType: respondentTypeRef,
|
||||
|
|
@ -142,6 +139,15 @@ const complaintFromtoptions = ref<DataOption[]>([
|
|||
|
||||
/** หัวตาราง */
|
||||
const columns = ref<QTableProps["columns"]>([
|
||||
{
|
||||
name: "info",
|
||||
align: "left",
|
||||
label: "",
|
||||
sortable: false,
|
||||
field: "info",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "no",
|
||||
align: "left",
|
||||
|
|
@ -218,6 +224,7 @@ const columns = ref<QTableProps["columns"]>([
|
|||
|
||||
/** หัวข้อที่เเสดงในตาราง */
|
||||
const visibleColumns = ref<string[]>([
|
||||
"info",
|
||||
"no",
|
||||
"idcard",
|
||||
"name",
|
||||
|
|
@ -228,6 +235,22 @@ const visibleColumns = ref<string[]>([
|
|||
"organization",
|
||||
]);
|
||||
|
||||
/**
|
||||
* รับค่าผู้ถูกร้องเรียน
|
||||
* @param val บุคคล หน่วยงาน กทม
|
||||
*/
|
||||
async function selectComplainant(val: string) {
|
||||
formData.organizationId = "";
|
||||
formData.consideredAgency = "";
|
||||
|
||||
if (val === "1") {
|
||||
await fetchOffice(); // ถ้าเลือกหน่วยงานจะเรียก function fetchOffice เรียกโครงสร้างสำนักงาน
|
||||
}
|
||||
}
|
||||
|
||||
/** เรียกโครงสร้างสำนักงาน */
|
||||
async function fetchOffice() {}
|
||||
|
||||
/**
|
||||
* ฟังชั่นอัปโหลดไฟล์
|
||||
* @param documentFile ไฟล์ที่รับมา
|
||||
|
|
@ -564,7 +587,15 @@ onMounted(() => {
|
|||
<div v-if="col.name == 'no'">
|
||||
{{ props.rowIndex + 1 }}
|
||||
</div>
|
||||
<div>
|
||||
<div v-else-if="col.name == 'info'">
|
||||
<router-link :to="`/registry/${props.row.personId}`"
|
||||
><q-icon name="info" color="info" size="sm"
|
||||
><q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||
</q-icon></router-link
|
||||
>
|
||||
{{ col.value }}
|
||||
</div>
|
||||
<div v-else>
|
||||
{{ col.value }}
|
||||
</div>
|
||||
</q-td>
|
||||
|
|
@ -602,7 +633,7 @@ onMounted(() => {
|
|||
v-model="formData.description"
|
||||
:rules="[(val) => !!val || 'กรุณาการข้อมูล']"
|
||||
lazy-rules
|
||||
label="รายละเอียดที่เกี่นวข้องกับเรื่องที่ต้องการจะข้อเรียน"
|
||||
label="รายละเอียดเรื่องร้องเรียน"
|
||||
type="textarea"
|
||||
rows="5"
|
||||
/>
|
||||
|
|
|
|||
|
|
@ -3,8 +3,6 @@ import { ref, onMounted, watch } from "vue";
|
|||
import { useRouter } from "vue-router";
|
||||
import { useQuasar } from "quasar";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
// import type
|
||||
import type { DataList } from "@/modules/11_discipline/interface/response/complaint";
|
||||
// importStroe
|
||||
import { useComplainstDataStore } from "@/modules/11_discipline/store/ComplaintsStore";
|
||||
// impoet Components
|
||||
|
|
@ -29,10 +27,10 @@ const maxPage = ref<number>(1);
|
|||
const page = ref<number>(1);
|
||||
const rowsPerPage = ref<number>(10);
|
||||
|
||||
async function updatePagingProp(rowPerpage:number,pageCurrent:number) {
|
||||
rowsPerPage.value = rowPerpage
|
||||
page.value = pageCurrent
|
||||
await getList()
|
||||
async function updatePagingProp(rowPerpage: number, pageCurrent: number) {
|
||||
rowsPerPage.value = rowPerpage;
|
||||
page.value = pageCurrent;
|
||||
await getList();
|
||||
}
|
||||
|
||||
async function getList() {
|
||||
|
|
@ -44,11 +42,10 @@ async function getList() {
|
|||
rowsPerPage.value,
|
||||
filterKeyword.value
|
||||
)
|
||||
|
||||
)
|
||||
//
|
||||
//
|
||||
.then((res) => {
|
||||
maxPage.value = Math.ceil(res.data.result.total/ rowsPerPage.value);
|
||||
maxPage.value = Math.ceil(res.data.result.total / rowsPerPage.value);
|
||||
const data = res.data.result.data;
|
||||
fetchComplainst(data);
|
||||
})
|
||||
|
|
@ -62,7 +59,7 @@ async function getList() {
|
|||
|
||||
/** ไปยังหน้าเพิ่มข้อมูล */
|
||||
function redirectToPageadd() {
|
||||
complainstStore.fetchComplainstAdd([])
|
||||
complainstStore.fetchComplainstAdd([]);
|
||||
router.push(`/discipline/complaints/add`);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -45,27 +45,27 @@ const columns = ref<QTableProps["columns"]>([
|
|||
{
|
||||
name: "title",
|
||||
align: "left",
|
||||
label: "เรื่อง",
|
||||
label: "เรื่องร้องเรียน",
|
||||
sortable: true,
|
||||
field: "title",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "description",
|
||||
name: "dateReceived",
|
||||
align: "left",
|
||||
label: "รายละเอียด",
|
||||
label: "วันที่รับเรื่อง",
|
||||
sortable: true,
|
||||
field: "description",
|
||||
field: "dateReceived",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "appellant",
|
||||
name: "respondentType",
|
||||
align: "left",
|
||||
label: "ผู้ถูกร้องเรียน",
|
||||
sortable: true,
|
||||
field: "appellant",
|
||||
field: "respondentType",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
|
|
@ -78,15 +78,6 @@ const columns = ref<QTableProps["columns"]>([
|
|||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "createdAt",
|
||||
align: "left",
|
||||
label: "วันที่สร้างเรื่องร้องเรียน",
|
||||
sortable: true,
|
||||
field: "createdAt",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "levelConsideration",
|
||||
align: "left",
|
||||
|
|
@ -108,7 +99,7 @@ const columns = ref<QTableProps["columns"]>([
|
|||
{
|
||||
name: "status",
|
||||
align: "left",
|
||||
label: "สถานะเรื่องร้องเรียน",
|
||||
label: "สถานะ",
|
||||
sortable: true,
|
||||
field: "status",
|
||||
headerStyle: "font-size: 14px",
|
||||
|
|
@ -120,8 +111,8 @@ const columns = ref<QTableProps["columns"]>([
|
|||
const visibleColumns = ref<string[]>([
|
||||
"no",
|
||||
"title",
|
||||
"description",
|
||||
"appellant",
|
||||
"dateReceived",
|
||||
"respondentType",
|
||||
"offenseDetails",
|
||||
"createdAt",
|
||||
"levelConsideration",
|
||||
|
|
@ -216,11 +207,6 @@ watch(
|
|||
<div v-if="col.name == 'no'">
|
||||
{{ props.rowIndex + 1 }}
|
||||
</div>
|
||||
<div v-if="col.name == 'description'">
|
||||
<div class="table_ellipsis">
|
||||
{{ props.row.description }}
|
||||
</div>
|
||||
</div>
|
||||
<div v-else>
|
||||
{{ col.value }}
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue