ข้อมูลการประเมิน
This commit is contained in:
parent
d52e37965f
commit
daecd9524a
10 changed files with 106 additions and 176 deletions
|
|
@ -506,21 +506,9 @@ onMounted(async () => {
|
|||
<q-separator />
|
||||
|
||||
<q-card-section class="q-pa-sm">
|
||||
<q-input
|
||||
dense
|
||||
outlined
|
||||
v-model="filterAgency"
|
||||
label="ค้นหา"
|
||||
class="inputgreen"
|
||||
>
|
||||
<q-input dense outlined v-model="filterAgency" label="ค้นหา">
|
||||
<template v-slot:append>
|
||||
<q-icon
|
||||
v-if="filterAgency !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="filterAgency = ''"
|
||||
/>
|
||||
<q-icon v-else name="search" color="grey-5" />
|
||||
<q-icon name="search" />
|
||||
</template>
|
||||
</q-input>
|
||||
<q-tree
|
||||
|
|
@ -530,7 +518,7 @@ onMounted(async () => {
|
|||
node-key="orgTreeId"
|
||||
label-key="labelName"
|
||||
selected-color="primary"
|
||||
:filter="filterAgency"
|
||||
:filter="filterAgency.trim()"
|
||||
no-results-label="ไม่พบข้อมูลที่ค้นหา"
|
||||
no-nodes-label="ไม่มีข้อมูล"
|
||||
v-model:expanded="expandedAgency"
|
||||
|
|
@ -575,21 +563,9 @@ onMounted(async () => {
|
|||
<q-separator />
|
||||
|
||||
<q-card-section class="q-pa-sm">
|
||||
<q-input
|
||||
dense
|
||||
outlined
|
||||
v-model="filter"
|
||||
label="ค้นหา"
|
||||
class="inputgreen"
|
||||
>
|
||||
<q-input dense outlined v-model="filter" label="ค้นหา">
|
||||
<template v-slot:append>
|
||||
<q-icon
|
||||
v-if="filter !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="filter = ''"
|
||||
/>
|
||||
<q-icon v-else name="search" color="grey-5" />
|
||||
<q-icon name="search" />
|
||||
</template>
|
||||
</q-input>
|
||||
<q-tree
|
||||
|
|
@ -599,7 +575,7 @@ onMounted(async () => {
|
|||
selected-color="primary"
|
||||
node-key="id"
|
||||
label-key="name"
|
||||
:filter="filter"
|
||||
:filter="filter.trim()"
|
||||
no-results-label="ไม่พบข้อมูลที่ค้นหา"
|
||||
no-nodes-label="ไม่มีข้อมูล"
|
||||
v-model:expanded="expandedPlan"
|
||||
|
|
|
|||
|
|
@ -91,17 +91,17 @@ const roundOp = ref<DataOption[]>([
|
|||
* @param update อัพเดทค่า
|
||||
* @param refData ดาต้าที่ต้องการฟิลเตอร์
|
||||
*/
|
||||
function filterOption(val: any, update: Function) {
|
||||
function filterOption(val: string, update: Function) {
|
||||
update(() => {
|
||||
positionOp.value = positionMainOp.value.filter(
|
||||
(v: any) => v.name.indexOf(val) > -1
|
||||
(v: DataOption) => v.name.indexOf(val) > -1
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
/** ดึงข้อมูลตำแหน่ง */
|
||||
async function getOptions() {
|
||||
showLoader();
|
||||
// showLoader();
|
||||
await http
|
||||
.get(config.API.orgSalaryPosition)
|
||||
.then((res) => {
|
||||
|
|
@ -126,7 +126,7 @@ async function getOptions() {
|
|||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
// hideLoader();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
@ -438,13 +438,7 @@ onMounted(() => {
|
|||
class="inputgreen"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon
|
||||
v-if="filter !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="filter = ''"
|
||||
/>
|
||||
<q-icon v-else name="search" color="grey-5" />
|
||||
<q-icon name="search" color="grey-5" />
|
||||
</template>
|
||||
</q-input>
|
||||
<q-scroll-area
|
||||
|
|
@ -457,7 +451,7 @@ onMounted(() => {
|
|||
node-key="orgTreeId"
|
||||
label-key="labelName"
|
||||
v-model:expanded="expanded"
|
||||
:filter="filter"
|
||||
:filter="filter.trim()"
|
||||
no-results-label="ไม่พบข้อมูลที่ค้นหา"
|
||||
no-nodes-label="ไม่มีข้อมูล"
|
||||
>
|
||||
|
|
|
|||
|
|
@ -78,7 +78,9 @@ async function fetchList() {
|
|||
await http
|
||||
.get(
|
||||
config.API.kpiCapacity +
|
||||
`/edit?page=${formQuery.page}&pageSize=${formQuery.pageSize}&keyword=${formQuery.keyword}&type=${store.competencyTypeVal}`
|
||||
`/edit?page=${formQuery.page}&pageSize=${
|
||||
formQuery.pageSize
|
||||
}&keyword=${formQuery.keyword.trim()}&type=${store.competencyTypeVal}`
|
||||
)
|
||||
.then(async (res) => {
|
||||
total.value = res.data.result.total;
|
||||
|
|
@ -103,11 +105,12 @@ async function onViewDetailPage(id: string) {
|
|||
}
|
||||
|
||||
function deleteData(id: string) {
|
||||
dialogRemove($q, () => {
|
||||
http
|
||||
showLoader();
|
||||
dialogRemove($q, async () => {
|
||||
await http
|
||||
.delete(config.API.kpiCapacity + `/${id}`)
|
||||
.then(() => {
|
||||
fetchList();
|
||||
.then(async () => {
|
||||
await fetchList();
|
||||
success($q, "ลบข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((err) => {
|
||||
|
|
@ -190,13 +193,7 @@ onMounted(() => {
|
|||
@keyup.enter="fetchNewList()"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon v-if="formQuery.keyword == ''" name="search" />
|
||||
<q-icon
|
||||
v-if="formQuery.keyword !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="(formQuery.keyword = ''), fetchNewList()"
|
||||
/>
|
||||
<q-icon name="search" />
|
||||
</template>
|
||||
</q-input>
|
||||
<q-select
|
||||
|
|
@ -210,7 +207,6 @@ onMounted(() => {
|
|||
map-options
|
||||
:options="columns"
|
||||
option-value="name"
|
||||
|
||||
style="min-width: 140px"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -59,7 +59,9 @@ async function fetchData() {
|
|||
await http
|
||||
.get(
|
||||
config.API.kpiGroup +
|
||||
`/edit?page=${formQuery.page}&pageSize=${formQuery.pageSize}&keyword=${formQuery.keyword}`
|
||||
`/edit?page=${formQuery.page}&pageSize=${
|
||||
formQuery.pageSize
|
||||
}&keyword=${formQuery.keyword.trim()}`
|
||||
)
|
||||
.then(async (res) => {
|
||||
total.value = res.data.result.total;
|
||||
|
|
@ -77,12 +79,13 @@ async function fetchData() {
|
|||
|
||||
/** เพิ่มข้อมูล */
|
||||
async function addData() {
|
||||
showLoader();
|
||||
await http
|
||||
.post(config.API.kpiGroup, {
|
||||
nameGroupKPI: groupName.value,
|
||||
})
|
||||
.then(() => {
|
||||
fetchData();
|
||||
.then(async () => {
|
||||
await fetchData();
|
||||
success($q, "บันทึกข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((err) => {
|
||||
|
|
@ -95,12 +98,13 @@ async function addData() {
|
|||
|
||||
/** save แก้ไขข้อมูล */
|
||||
async function editData(id: string) {
|
||||
showLoader();
|
||||
await http
|
||||
.put(config.API.kpiGroupById(id), {
|
||||
nameGroupKPI: groupName.value,
|
||||
})
|
||||
.then(() => {
|
||||
fetchData();
|
||||
.then(async () => {
|
||||
await fetchData();
|
||||
success($q, "บันทึกข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((err) => {
|
||||
|
|
@ -113,10 +117,11 @@ async function editData(id: string) {
|
|||
|
||||
/** ลบข้อมูล */
|
||||
async function deleteData(id: string) {
|
||||
showLoader();
|
||||
await http
|
||||
.delete(config.API.kpiGroupById(id))
|
||||
.then(() => {
|
||||
fetchData();
|
||||
.then(async () => {
|
||||
await fetchData();
|
||||
success($q, "ลบข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((err) => {
|
||||
|
|
@ -151,7 +156,7 @@ async function onSubmit() {
|
|||
dialogConfirm(
|
||||
$q,
|
||||
async () => {
|
||||
editStatus.value ? editData(editId.value) : addData();
|
||||
editStatus.value ? await editData(editId.value) : await addData();
|
||||
closeDialog();
|
||||
},
|
||||
"ยืนยันการบันทึกข้อมูล",
|
||||
|
|
@ -205,14 +210,7 @@ onMounted(async () => {
|
|||
label="ค้นหา"
|
||||
@keyup.enter="fetchNewList()"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon v-if="formQuery.keyword == ''" name="search" />
|
||||
<q-icon
|
||||
v-if="formQuery.keyword !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="(formQuery.keyword = ''), fetchNewList()"
|
||||
/> </template
|
||||
<template v-slot:append> <q-icon name="search" /> </template
|
||||
></q-input>
|
||||
<q-select
|
||||
v-model="visibleColumns"
|
||||
|
|
@ -225,7 +223,6 @@ onMounted(async () => {
|
|||
map-options
|
||||
:options="columns"
|
||||
option-value="name"
|
||||
|
||||
style="min-width: 140px"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -84,9 +84,6 @@ const {
|
|||
dialogConfirm,
|
||||
} = mixin;
|
||||
|
||||
const competencyType = ref<string>("ID1");
|
||||
const filterKeyword = ref<string>("");
|
||||
|
||||
const visibleColumns = ref<string[]>(["groupName", "positions", "capacitys"]);
|
||||
|
||||
const formQuery = reactive({
|
||||
|
|
@ -102,7 +99,9 @@ async function getData() {
|
|||
http
|
||||
.get(
|
||||
config.API.kpiLink +
|
||||
`/edit?page=${formQuery.page}&pageSize=${formQuery.pageSize}&keyword=${formQuery.keyword}`
|
||||
`/edit?page=${formQuery.page}&pageSize=${
|
||||
formQuery.pageSize
|
||||
}&keyword=${formQuery.keyword.trim()}`
|
||||
)
|
||||
.then((res) => {
|
||||
total.value = res.data.result.total;
|
||||
|
|
@ -116,12 +115,13 @@ async function getData() {
|
|||
}
|
||||
|
||||
async function deleteData(id: string) {
|
||||
showLoader();
|
||||
await http
|
||||
.delete(config.API.kpiLink + `/${id}`)
|
||||
.then(() => {
|
||||
.then(async () => {
|
||||
await getData();
|
||||
success($q, "ลบข้อมูลสำเร็จ");
|
||||
close();
|
||||
getData();
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
|
|
@ -211,7 +211,7 @@ async function onEdit(data: any) {
|
|||
editStatus.value = true;
|
||||
}
|
||||
|
||||
function getDataEdit(id: string) {
|
||||
async function getDataEdit(id: string) {
|
||||
showLoader();
|
||||
http
|
||||
.get(config.API.kpiLink + `/edit/${id}`)
|
||||
|
|
@ -241,14 +241,20 @@ function onSubmit() {
|
|||
positions: position.value,
|
||||
kpiCapacityIds: competency.value?.map((i: any) => i.id),
|
||||
};
|
||||
dialogConfirm($q, () => {
|
||||
dialogConfirm($q, async () => {
|
||||
showLoader();
|
||||
http[editStatus.value ? "put" : "post"](url, body)
|
||||
.then(() => {
|
||||
.then(async () => {
|
||||
await getData();
|
||||
success($q, "บันทึกสำเร็จ");
|
||||
close();
|
||||
getData();
|
||||
})
|
||||
.finally(() => {});
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
|
@ -261,7 +267,7 @@ function close() {
|
|||
competency.value = [];
|
||||
}
|
||||
|
||||
function getOptions() {
|
||||
async function getOptions() {
|
||||
http.get(config.API.orgSalaryPosition).then((res) => {
|
||||
const dataOp = res.data.result;
|
||||
const uniqueNames = new Set();
|
||||
|
|
@ -371,13 +377,7 @@ onMounted(async () => {
|
|||
@keyup.enter="fetchNewList()"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon v-if="formQuery.keyword == ''" name="search" />
|
||||
<q-icon
|
||||
v-if="formQuery.keyword !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="(formQuery.keyword = ''), fetchNewList()"
|
||||
/> </template
|
||||
<q-icon name="search" /> </template
|
||||
></q-input>
|
||||
<q-select
|
||||
v-model="visibleColumns"
|
||||
|
|
@ -390,8 +390,7 @@ onMounted(async () => {
|
|||
map-options
|
||||
:options="columns"
|
||||
option-value="name"
|
||||
|
||||
style="min-width: 140px"
|
||||
style="min-width: 140px"
|
||||
>
|
||||
</q-select>
|
||||
</div>
|
||||
|
|
@ -517,6 +516,8 @@ onMounted(async () => {
|
|||
option-value="id"
|
||||
:options="groupNameOp"
|
||||
use-input
|
||||
hide-selected
|
||||
fill-input
|
||||
@filter="(inputValue:any,doneFn:Function) => filterOptionGroup(inputValue, doneFn) "
|
||||
hide-bottom-space
|
||||
lazy-rules
|
||||
|
|
|
|||
|
|
@ -11,7 +11,8 @@ import { useRoute } from "vue-router";
|
|||
|
||||
const $q = useQuasar();
|
||||
const route = useRoute();
|
||||
const { showLoader, hideLoader, success } = useCounterMixin();
|
||||
const { showLoader, hideLoader, success, dialogConfirm, messageError } =
|
||||
useCounterMixin();
|
||||
|
||||
const dataLevel = ref<any>();
|
||||
const fieldLabels = {
|
||||
|
|
@ -23,28 +24,40 @@ const fieldLabels = {
|
|||
};
|
||||
|
||||
function onSubmit() {
|
||||
const body = {
|
||||
formScore: dataLevel.value.map((item: any) => {
|
||||
const { level, ...rest } = item;
|
||||
return rest;
|
||||
}),
|
||||
};
|
||||
dialogConfirm($q, async () => {
|
||||
showLoader();
|
||||
const body = {
|
||||
formScore: dataLevel.value.map((item: any) => {
|
||||
const { level, ...rest } = item;
|
||||
return rest;
|
||||
}),
|
||||
};
|
||||
|
||||
http
|
||||
.put(config.API.kpiEvaluation, body.formScore)
|
||||
.then((res) => {
|
||||
success($q, "บันทึกสำเร็จ");
|
||||
})
|
||||
.finally(() => {});
|
||||
await http
|
||||
.put(config.API.kpiEvaluation, body.formScore)
|
||||
.then(async () => {
|
||||
await getData();
|
||||
success($q, "บันทึกสำเร็จ");
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
function getData() {
|
||||
async function getData() {
|
||||
showLoader();
|
||||
http
|
||||
.get(config.API.kpiEvaluation + `/edit`)
|
||||
.then((res) => {
|
||||
dataLevel.value = res.data.result.data;
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
});
|
||||
|
|
|
|||
|
|
@ -92,7 +92,10 @@ function fetchList() {
|
|||
showLoader();
|
||||
formFilter.year = formFilter.year ? formFilter.year.toString() : null;
|
||||
http
|
||||
.post(config.API.kpiSpecial + `/search-edit`, formFilter)
|
||||
.post(config.API.kpiSpecial + `/search-edit`, {
|
||||
...formFilter,
|
||||
keyword: formFilter.keyword.trim(),
|
||||
})
|
||||
.then((res: ResAssignment) => {
|
||||
maxPage.value = Math.ceil(res.data.result.total / formFilter.pageSize);
|
||||
totalList.value = res.data.result.total;
|
||||
|
|
@ -258,13 +261,7 @@ onMounted(() => {
|
|||
@keydown.enter="fetchNewList"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon
|
||||
v-if="formFilter.keyword !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="(formFilter.keyword = ''), fetchNewList()"
|
||||
/>
|
||||
<q-icon v-else name="search" color="grey-5" />
|
||||
<q-icon name="search" />
|
||||
</template>
|
||||
</q-input>
|
||||
<q-select
|
||||
|
|
@ -278,7 +275,6 @@ onMounted(() => {
|
|||
map-options
|
||||
:options="columns"
|
||||
option-value="name"
|
||||
|
||||
style="min-width: 140px"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -190,13 +190,7 @@ onMounted(() => {
|
|||
|
||||
<q-input dense outlined v-model="filter" label="ค้นหา">
|
||||
<template v-slot:append>
|
||||
<q-icon
|
||||
v-if="filter !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="filter = ''"
|
||||
/>
|
||||
<q-icon v-else name="search" color="grey-5" />
|
||||
<q-icon name="search" />
|
||||
</template>
|
||||
</q-input>
|
||||
</q-toolbar>
|
||||
|
|
@ -208,7 +202,7 @@ onMounted(() => {
|
|||
:nodes="nodes"
|
||||
node-key="id"
|
||||
label-key="name"
|
||||
:filter="filter"
|
||||
:filter="filter.trim()"
|
||||
no-results-label="ไม่พบข้อมูลที่ค้นหา"
|
||||
no-nodes-label="ไม่มีข้อมูล"
|
||||
v-model:expanded="expanded"
|
||||
|
|
@ -325,6 +319,7 @@ onMounted(() => {
|
|||
<div class="col">
|
||||
<q-input
|
||||
dense
|
||||
class="inputgreen"
|
||||
outlined
|
||||
v-model="strategicName"
|
||||
:label="`ชื่อ${titleDialog}`"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
<script setup lang="ts">
|
||||
import { ref, reactive, onMounted,watch } from "vue";
|
||||
import { ref, reactive, onMounted, watch } from "vue";
|
||||
import { useQuasar, type QTableProps } from "quasar";
|
||||
import { useRouter, useRoute } from "vue-router";
|
||||
|
||||
|
|
@ -87,7 +87,7 @@ function fetchList() {
|
|||
http
|
||||
.post(config.API.kpiPlan + `/search-edit`, {
|
||||
isAll: isAll.value,
|
||||
keyword: nodeData.keyword,
|
||||
keyword: nodeData.keyword.trim(),
|
||||
node: nodeData.node ? nodeData.node : 0,
|
||||
nodeId: nodeData.nodeId,
|
||||
period: nodeData.round,
|
||||
|
|
@ -98,9 +98,9 @@ function fetchList() {
|
|||
.then((res) => {
|
||||
const data = res.data.result.data;
|
||||
totalList.value = Math.ceil(
|
||||
res.data.result.total / pagination.value.rowsPerPage
|
||||
);
|
||||
total.value = res.data.result.total;
|
||||
res.data.result.total / pagination.value.rowsPerPage
|
||||
);
|
||||
total.value = res.data.result.total;
|
||||
rows.value = data;
|
||||
})
|
||||
.catch((err) => {
|
||||
|
|
@ -127,20 +127,6 @@ function onClickView(id: string = "") {
|
|||
router.push(`/masterdata/indicator-plan/view/${id}`);
|
||||
}
|
||||
|
||||
function fetchActive() {
|
||||
// showLoader();
|
||||
// http
|
||||
// .get(config.API.activeOrganization)
|
||||
// .then((res) => {
|
||||
// const data = res.data.result;
|
||||
// // fetchTree(data.activeId);
|
||||
// })
|
||||
// .catch((err) => {
|
||||
// messageError($q, err);
|
||||
// hideLoader();
|
||||
// });
|
||||
}
|
||||
|
||||
/** ดึงข้อมูลโครงสรร้าง */
|
||||
async function fetchTree() {
|
||||
node.value = await fetchStructureTree(route.meta.Key as string, true);
|
||||
|
|
@ -206,7 +192,6 @@ function onClickHistory(id: string) {
|
|||
function updatePagination(newPagination: any) {
|
||||
pagination.value.page = 1;
|
||||
pagination.value.rowsPerPage = newPagination.rowsPerPage;
|
||||
|
||||
}
|
||||
|
||||
function getSearch() {
|
||||
|
|
@ -242,13 +227,7 @@ onMounted(() => {
|
|||
|
||||
<q-input dense outlined v-model="filterMain" label="ค้นหา">
|
||||
<template v-slot:append>
|
||||
<q-icon
|
||||
v-if="filterMain !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="filterMain = ''"
|
||||
/>
|
||||
<q-icon v-else name="search" color="grey-5" />
|
||||
<q-icon name="search" color="grey-5" />
|
||||
</template>
|
||||
</q-input>
|
||||
<q-tree
|
||||
|
|
@ -258,7 +237,7 @@ onMounted(() => {
|
|||
node-key="orgTreeName"
|
||||
label-key="labelName"
|
||||
v-model:expanded="expanded"
|
||||
:filter="filterMain"
|
||||
:filter="filterMain.trim()"
|
||||
no-results-label="ไม่พบข้อมูลที่ค้นหา"
|
||||
no-nodes-label="ไม่มีข้อมูล"
|
||||
v-model:selected="nodeData.nodeId"
|
||||
|
|
@ -329,9 +308,7 @@ onMounted(() => {
|
|||
<template v-if="year" v-slot:append>
|
||||
<q-icon
|
||||
name="cancel"
|
||||
@click.stop.prevent="
|
||||
(year = null),getSearch()
|
||||
"
|
||||
@click.stop.prevent="(year = null), getSearch()"
|
||||
class="cursor-pointer"
|
||||
/>
|
||||
</template>
|
||||
|
|
@ -354,9 +331,7 @@ onMounted(() => {
|
|||
<template v-if="nodeData.round" v-slot:append>
|
||||
<q-icon
|
||||
name="cancel"
|
||||
@click.stop.prevent="
|
||||
(nodeData.round = ''), getSearch()
|
||||
"
|
||||
@click.stop.prevent="(nodeData.round = ''), getSearch()"
|
||||
class="cursor-pointer"
|
||||
/>
|
||||
</template>
|
||||
|
|
@ -393,18 +368,11 @@ onMounted(() => {
|
|||
v-model="nodeData.keyword"
|
||||
ref="filterRef"
|
||||
outlined
|
||||
style="width: 150px"
|
||||
placeholder="ค้นหา"
|
||||
@keydown.enter.prevent="getSearch"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon v-if="nodeData.keyword == ''" name="search" />
|
||||
<q-icon
|
||||
v-if="nodeData.keyword !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="clearFilter"
|
||||
/>
|
||||
<q-icon name="search" />
|
||||
</template>
|
||||
</q-input>
|
||||
<q-select
|
||||
|
|
@ -418,7 +386,6 @@ onMounted(() => {
|
|||
map-options
|
||||
:options="columns"
|
||||
option-value="name"
|
||||
|
||||
style="min-width: 140px"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -103,9 +103,11 @@ const roundOp = ref<DataOption[]>([
|
|||
]);
|
||||
|
||||
async function fetchList() {
|
||||
showLoader();
|
||||
rows.value = [];
|
||||
await http
|
||||
.post(config.API.kpiRoleMainList + `/search-edit`, {
|
||||
keyword: formFilter.keyword,
|
||||
keyword: formFilter.keyword.trim(),
|
||||
position: formFilter.position,
|
||||
period: formFilter.round,
|
||||
node: 0,
|
||||
|
|
@ -407,13 +409,7 @@ onMounted(async () => {
|
|||
@keyup.enter="(formFilter.page = 1), fetchList()"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon v-if="formFilter.keyword == ''" name="search" />
|
||||
<q-icon
|
||||
v-if="formFilter.keyword !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="formFilter.keyword = ''"
|
||||
/>
|
||||
<q-icon name="search" />
|
||||
</template>
|
||||
</q-input>
|
||||
|
||||
|
|
@ -428,7 +424,6 @@ onMounted(async () => {
|
|||
map-options
|
||||
:options="columns"
|
||||
option-value="name"
|
||||
|
||||
style="min-width: 140px"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue