Merge branch 'nice_dev' into develop
This commit is contained in:
commit
96e463009f
5 changed files with 82 additions and 59 deletions
|
|
@ -3,7 +3,7 @@ import { ref } from "vue";
|
|||
import { useQuasar } from "quasar";
|
||||
import config from "@/app.config";
|
||||
import http from "@/plugins/http";
|
||||
import genReport from "@/plugins/genreport";
|
||||
import genreport from "@/plugins/genreportxlsx";
|
||||
|
||||
/** importType*/
|
||||
import type { QTableProps } from "quasar";
|
||||
|
|
@ -12,7 +12,10 @@ import type {
|
|||
NewPagination,
|
||||
} from "@/modules/02_organizationalNew/interface/index/Main";
|
||||
import type { FilterMaster } from "@/modules/02_organizationalNew/interface/request/organizational";
|
||||
import type { PosMaster2 } from "@/modules/02_organizationalNew/interface/response/organizational";
|
||||
import type {
|
||||
PosMaster2,
|
||||
OrgTree,
|
||||
} from "@/modules/02_organizationalNew/interface/response/organizational";
|
||||
import type { DataPosition } from "@/modules/02_organizationalNew/interface/index/organizational";
|
||||
|
||||
/** importComponents*/
|
||||
|
|
@ -52,6 +55,10 @@ const props = defineProps({
|
|||
require: true,
|
||||
default: () => {},
|
||||
},
|
||||
mainTree: {
|
||||
type: Object,
|
||||
require: true,
|
||||
},
|
||||
});
|
||||
|
||||
const modalSelectPerson = ref<boolean>(false);
|
||||
|
|
@ -396,14 +403,14 @@ function getSummary() {
|
|||
}
|
||||
|
||||
/** function DownloadReport*/
|
||||
async function onClickDownloadReport(val: string) {
|
||||
async function onClickDownloadReport(val: string, name: string) {
|
||||
showLoader();
|
||||
await http
|
||||
.get(config.API.orgReport(val))
|
||||
.then((res) => {
|
||||
const data = res.data.result;
|
||||
if (data) {
|
||||
genReport(data, "name");
|
||||
genreport(data, name);
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
|
|
@ -462,7 +469,7 @@ async function onClickDownloadReport(val: string) {
|
|||
<q-item
|
||||
clickable
|
||||
v-close-popup
|
||||
@click.stop="onClickDownloadReport(item.val)"
|
||||
@click.stop="onClickDownloadReport(item.val, item.name)"
|
||||
>
|
||||
<q-item-section>{{ item.name }}</q-item-section>
|
||||
</q-item>
|
||||
|
|
@ -774,6 +781,7 @@ async function onClickDownloadReport(val: string) {
|
|||
:fetchDataTree="props.fetchDataTree"
|
||||
:type="typeMove"
|
||||
:rowId="rowId"
|
||||
:mainTree="props.mainTree ? props.mainTree : []"
|
||||
/>
|
||||
|
||||
<!-- ประวัติตำแหน่ง -->
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue