Merge branch 'nice' into develop
This commit is contained in:
commit
08fcc6a351
2 changed files with 27 additions and 2 deletions
|
|
@ -69,4 +69,7 @@ export default {
|
|||
kpiLink,
|
||||
|
||||
profilePosition: () => `${env.API_URI}/org/profile/keycloak/position`,
|
||||
|
||||
/** Report*/
|
||||
kpiReport: () => `${KPI}/report/announcement`,
|
||||
};
|
||||
|
|
|
|||
|
|
@ -84,7 +84,26 @@ function fetchListOrg(id: string) {
|
|||
});
|
||||
}
|
||||
|
||||
function changRound() {}
|
||||
function fetchReport() {
|
||||
if (round.value !== "" && organization.value !== "") {
|
||||
showLoader();
|
||||
const body = {
|
||||
periodId: round.value,
|
||||
root: organization.value,
|
||||
};
|
||||
http
|
||||
.post(config.API.kpiReport(), body)
|
||||
.then((res) => {})
|
||||
.catch((err) => {})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function changOption() {
|
||||
fetchReport();
|
||||
}
|
||||
|
||||
function filterSelector(val: string, update: Function) {
|
||||
update(() => {
|
||||
|
|
@ -183,7 +202,7 @@ onMounted(() => {
|
|||
emit-value
|
||||
map-options
|
||||
:disable="roundOp.length === 0"
|
||||
@update:model-value="changRound"
|
||||
@update:model-value="changOption"
|
||||
/>
|
||||
<q-select
|
||||
:disable="roundOp.length === 0"
|
||||
|
|
@ -193,12 +212,15 @@ onMounted(() => {
|
|||
outlined
|
||||
option-label="name"
|
||||
option-value="id"
|
||||
emit-value
|
||||
map-options
|
||||
v-model="organization"
|
||||
:options="organizationOps"
|
||||
label="หน่วยงาน"
|
||||
use-input
|
||||
@update:model-value="changOption"
|
||||
@filter="(inputValue: string,
|
||||
|
||||
doneFn: Function) => filterSelector(inputValue, doneFn )"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue