feat(AppEarTag): 添加耳标登记导出功能
- 在 etList 组件中引入 AiDownload组件 - 在搜索栏中添加导出按钮,实现耳标登记数据导出功能
This commit is contained in:
		| @@ -1,5 +1,6 @@ | |||||||
| <script> | <script> | ||||||
| import {mapState} from "vuex" | import {mapState} from "vuex" | ||||||
|  | import AiDownload from "dui/packages/tools/AiDownload.vue"; | ||||||
|  |  | ||||||
| const columns = [ | const columns = [ | ||||||
|   {label: "序号", type: "index"}, |   {label: "序号", type: "index"}, | ||||||
| @@ -12,6 +13,7 @@ const columns = [ | |||||||
| ] | ] | ||||||
| export default { | export default { | ||||||
|   name: "etList", |   name: "etList", | ||||||
|  |   components: {AiDownload}, | ||||||
|   props: { |   props: { | ||||||
|     instance: Function, |     instance: Function, | ||||||
|     dict: Object, |     dict: Object, | ||||||
| @@ -92,6 +94,7 @@ export default { | |||||||
|     <ai-search-bar> |     <ai-search-bar> | ||||||
|       <template #left> |       <template #left> | ||||||
|         <el-button type="primary" icon="iconfont iconAdd" @click="$router.push({hash:'#add'})">新增</el-button> |         <el-button type="primary" icon="iconfont iconAdd" @click="$router.push({hash:'#add'})">新增</el-button> | ||||||
|  |         <ai-download :instance="instance" url="/api/breed/earTag/export" :params="{...search,...page}" :fileName="`耳标登记导出表-${Date.now()}`"/> | ||||||
|       </template> |       </template> | ||||||
|     </ai-search-bar> |     </ai-search-bar> | ||||||
|     <ai-table :tableData="tableData" :colConfigs="columns" :dict="dict" @getList="getTableData" |     <ai-table :tableData="tableData" :colConfigs="columns" :dict="dict" @getList="getTableData" | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user