fix: 分摊明细导出调整参数
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<!-- <fvSearchForm :searchConfig="searchConfig" @search="search" style="margin-left: 16px"></fvSearchForm>-->
|
||||
<fvSearchForm :searchConfig="searchConfig" @search="search" style="margin-left: 16px"></fvSearchForm>
|
||||
<!-- <el-button color="#DED0B2" style="float: left;margin: 0 10px 10px 0" @click="exportTable">导出</el-button>-->
|
||||
|
||||
<fvTable ref="tableIns" :tableConfig="tableConfig" @headBtnClick="headBtnClick" style="margin-top: 15px" @selectionChange="selectionChange">
|
||||
@@ -10,6 +10,8 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="jsx">
|
||||
import fvSelect from '@/fvcomponents/fvSelect/index.vue'
|
||||
|
||||
import { getSubCompOpt } from '@/api/user/user.js';
|
||||
import {reactive, ref} from "vue";
|
||||
import {shareDetailExport, shareExportExcel} from "@/api/expense-manage";
|
||||
@@ -17,38 +19,39 @@ import {ElMessage} from "element-plus";
|
||||
const router = useRouter()
|
||||
const route = useRoute()
|
||||
const searchConfig = reactive([
|
||||
// {
|
||||
// label: '分摊名称',
|
||||
// prop: 'shareName',
|
||||
// component: 'el-input',
|
||||
// props: {
|
||||
// placeholder: '请输入分摊名称查询',
|
||||
// clearable: true,
|
||||
// filterable: true,
|
||||
// checkStrictly: true
|
||||
// }
|
||||
// },
|
||||
{
|
||||
label: '支付月份',
|
||||
prop: 'apportionmentMonth',
|
||||
component: 'el-date-picker',
|
||||
label: '子项目',
|
||||
prop: 'subProjectName',
|
||||
component: 'el-input',
|
||||
props: {
|
||||
placeholder: '请选择支付月份',
|
||||
placeholder: '请输入子项目查询',
|
||||
clearable: true,
|
||||
type:'month',
|
||||
format: 'YYYY-MM',
|
||||
valueFormat:"YYYY-MM"
|
||||
},
|
||||
colProps: {}
|
||||
filterable: true,
|
||||
checkStrictly: true
|
||||
}
|
||||
},
|
||||
// {
|
||||
// label: '状态',
|
||||
// prop: 'state',
|
||||
// label: '支付月份',
|
||||
// prop: 'apportionmentMonth',
|
||||
// component: 'el-date-picker',
|
||||
// props: {
|
||||
// placeholder: '请选择支付月份',
|
||||
// clearable: true,
|
||||
// type:'month',
|
||||
// format: 'YYYY-MM',
|
||||
// valueFormat:"YYYY-MM"
|
||||
// },
|
||||
// colProps: {}
|
||||
// },
|
||||
// {
|
||||
// label: '人员性质',
|
||||
// prop: 'personnelNature',
|
||||
// component: shallowRef(fvSelect),
|
||||
// props: {
|
||||
// placeholder: '请选择状态',
|
||||
// placeholder: '请选择人员性质',
|
||||
// clearable: true,
|
||||
// cacheKey: 'special_fund'
|
||||
// filterable: true,
|
||||
// cacheKey: 'nature_of_personnel'
|
||||
// }
|
||||
// },
|
||||
])
|
||||
@@ -165,7 +168,7 @@ const headBtnClick = (key) => {
|
||||
|
||||
const selectionChange = (data) => {
|
||||
console.log('data', data)
|
||||
selectData.value=data
|
||||
selectData.value=data.map(item=>item.allocationId)
|
||||
}
|
||||
const exportTable = () => {
|
||||
console.log('selectData',selectData.value)
|
||||
@@ -173,7 +176,7 @@ const exportTable = () => {
|
||||
ElMessage.warning('请选择要导出的费用分摊')
|
||||
return
|
||||
}
|
||||
shareDetailExport(selectData.value[0]).then(res => {
|
||||
shareDetailExport(selectData.value).then(res => {
|
||||
console.log(res)
|
||||
let fileName = `科技研发项目工时及成本分摊汇总表.xlsx`
|
||||
const blob = new Blob([res.data])
|
||||
|
||||
Reference in New Issue
Block a user