แก้ไขชื่อไฟล์ตอน โหลดไฟล
This commit is contained in:
parent
f70a20497d
commit
77e4294ec5
1 changed files with 11 additions and 10 deletions
|
|
@ -66,7 +66,7 @@ const fecthlistRound = async () => {
|
|||
year: e.period_year,
|
||||
name: e.period_name,
|
||||
}));
|
||||
filterOtion.value = optionsList.value
|
||||
filterOtion.value = optionsList.value;
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
|
|
@ -119,7 +119,10 @@ const downloadReport = async (
|
|||
})
|
||||
.then(async (res) => {
|
||||
if (download) {
|
||||
downloadFile(res, `${titleReport} ${selectList.value.name}.${type}`);
|
||||
downloadFile(
|
||||
res,
|
||||
`${titleReport.value} ${selectList.value.name}.${type}`
|
||||
);
|
||||
} else {
|
||||
const url = URL.createObjectURL(new Blob([res.data]));
|
||||
showDocument(url);
|
||||
|
|
@ -135,15 +138,13 @@ const downloadReport = async (
|
|||
const filterSelector = (val: any, update: Function, name: any) => {
|
||||
update(() => {
|
||||
const needle = val.toLowerCase();
|
||||
if (name === 'selectList') {
|
||||
if (name === "selectList") {
|
||||
filterOtion.value = optionsList.value.filter(
|
||||
(v: any) => v.name.toLowerCase().indexOf(needle) > -1
|
||||
);
|
||||
(v: any) => v.name.toLowerCase().indexOf(needle) > -1
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
)
|
||||
}
|
||||
});
|
||||
};
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
|
@ -166,7 +167,7 @@ const filterSelector = (val: any, update: Function, name: any) => {
|
|||
<q-toolbar style="padding: 0">
|
||||
<q-form ref="myForm" class="row items-center">
|
||||
<q-select
|
||||
style="width: 400px;"
|
||||
style="width: 400px"
|
||||
class="q-pa-none"
|
||||
use-input
|
||||
fill-input
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue