no message
This commit is contained in:
parent
9e8516fc0b
commit
b4f269cd94
2 changed files with 21 additions and 18 deletions
|
|
@ -14,6 +14,7 @@ export default {
|
|||
/**ลบ ช่องทางการร้องเรียน
|
||||
* @param id type
|
||||
*/
|
||||
complaintListOp:()=>`${discipline}/complaint_Channel`,
|
||||
complaintChannelbyId: (id: string) => `${discipline}/complaint_Channel/${id}`,
|
||||
complaintAdd: () => `${discipline}/complaint`,
|
||||
complaintbyId: (id: string) => `${discipline}/complaint/${id}`,
|
||||
|
|
|
|||
|
|
@ -127,15 +127,7 @@ const levelConsiderationtoptions = ref<DataOption[]>([
|
|||
{ id: "URGENT", name: "ด่วน" },
|
||||
{ id: "VERY_URGENT", name: "ด่วนมาก" },
|
||||
]);
|
||||
const complaintFromtoptions = ref<DataOption[]>([
|
||||
{ id: "สตง", name: "สตง" },
|
||||
{ id: "ปปช", name: "ปปช" },
|
||||
{ id: "ปปท", name: "ปปท" },
|
||||
{ id: "จดหมาย", name: "จดหมาย" },
|
||||
{ id: "อีเมล", name: "อีเมล" },
|
||||
{ id: "โทรศัพท์", name: "โทรศัพท์" },
|
||||
{ id: "บอกกล่าว", name: "บอกกล่าว" },
|
||||
]);
|
||||
const complaintFromtoptions = ref<DataOption[]>([]);
|
||||
|
||||
/** หัวตาราง */
|
||||
const columns = ref<QTableProps["columns"]>([
|
||||
|
|
@ -410,14 +402,14 @@ function upLoadFileDoc() {
|
|||
})
|
||||
.finally(async () => {
|
||||
hideLoader();
|
||||
formData.documentFile = null
|
||||
formData.documentFile = null;
|
||||
});
|
||||
console.log("file", formData.documentFile, formData.id);
|
||||
}
|
||||
|
||||
async function addPerson(data: any) {
|
||||
toggleModal();
|
||||
console.log(data)
|
||||
console.log(data);
|
||||
await complainstStore.fetchComplainstAdd(data);
|
||||
}
|
||||
|
||||
|
|
@ -434,12 +426,18 @@ function deletePerson(id: string) {
|
|||
|
||||
function removePerson(id: string) {
|
||||
const dataRow = complainstStore.rowsAdd;
|
||||
const updatedRows = dataRow.filter((item: any) => item.id !== id);
|
||||
const updatedRows = dataRow.filter((item: any) => item.personId !== id);
|
||||
complainstStore.rowsAdd = updatedRows;
|
||||
}
|
||||
|
||||
function getList() {
|
||||
http.get(config.API.complaintListOp()).then((res) => {
|
||||
complaintFromtoptions.value = res.data.result.data;
|
||||
});
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
getList();
|
||||
getOc();
|
||||
complainstStore.columns = columns.value;
|
||||
complainstStore.visibleColumns = visibleColumns.value;
|
||||
|
|
@ -589,7 +587,9 @@ onMounted(() => {
|
|||
col.label
|
||||
}}</span>
|
||||
</q-th>
|
||||
<q-th auto-width v-if="formData.status === 'NEW'"></q-th>
|
||||
<q-th
|
||||
auto-width
|
||||
></q-th>
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:body="props">
|
||||
|
|
@ -620,8 +620,12 @@ onMounted(() => {
|
|||
{{ col.value }}
|
||||
</div>
|
||||
</q-td>
|
||||
<q-td auto-width v-if="formData.status === 'NEW'">
|
||||
<q-td auto-width>
|
||||
<q-btn
|
||||
v-if="
|
||||
formData.status === 'NEW' ||
|
||||
formData.status === ''
|
||||
"
|
||||
size="12px"
|
||||
flat
|
||||
round
|
||||
|
|
@ -629,7 +633,7 @@ onMounted(() => {
|
|||
color="red"
|
||||
class="q-ml-sm"
|
||||
icon="mdi-delete-outline"
|
||||
@click="deletePerson(props.row.id)"
|
||||
@click="deletePerson(props.row.personId)"
|
||||
><q-tooltip>ลบผู้ถูกร้องเรียน</q-tooltip></q-btn
|
||||
>
|
||||
</q-td>
|
||||
|
|
@ -1024,9 +1028,7 @@ onMounted(() => {
|
|||
</q-list>
|
||||
</div>
|
||||
<div class="q-px-md q-py-sm" v-if="fileList.length === 0">
|
||||
<q-card class="q-pa-md" bordered>
|
||||
ไม่มีรายการเอกสาร
|
||||
</q-card>
|
||||
<q-card class="q-pa-md" bordered> ไม่มีรายการเอกสาร </q-card>
|
||||
</div>
|
||||
</q-card>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue