|
@@ -1,11 +1,25 @@
|
|
|
<template>
|
|
|
<div class="filel-wrapper">
|
|
|
- <div style="text-align:left;padding:5px 0;margin-left:20px;">
|
|
|
- <el-button type="primary" size="small" @click="openImport('A')">导 入 动 态 数 据</el-button>
|
|
|
- <el-button type="primary" size="small" style="position: relative;" >数 据 模 板
|
|
|
- <a style="position: absolute;width: 100%;height: 100%;left: 0;top: 0; opacity: 0;z-index: 9;" href="/static/excel/temp.xlsx" download="数据模板.xlsx">数据模板</a>
|
|
|
- </el-button>
|
|
|
+ <div style="text-align:left; padding:5px 0; margin-left:20px;">
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-button type="primary" size="small" @click="openImport('A')">导 入 动 态 数 据</el-button>
|
|
|
+ <el-button type="primary" size="small" style="position: relative;">数 据 模 板
|
|
|
+ <a style="position: absolute; width: 100%; height: 100%; left: 0; top: 0; opacity: 0; z-index: 9;" href="/static/excel/temp.xlsx" download="数据模板.xlsx">数据模板</a>
|
|
|
+ </el-button>
|
|
|
+ <el-button type="primary" size="small" @click="reloadTable()">刷新</el-button>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12" style="text-align: right ; padding-right: 24px;">
|
|
|
+ <el-input
|
|
|
+ style="width: 200px;"
|
|
|
+ placeholder="请输入内容"
|
|
|
+ v-model="fileName">
|
|
|
+ </el-input>
|
|
|
+ <el-button type="primary" size="small" @click="search()">查询</el-button>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
</div>
|
|
|
+
|
|
|
<div class="nb-table">
|
|
|
<el-table
|
|
|
:data="filesList.result"
|
|
@@ -49,6 +63,7 @@ export default {
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
+ fileName: '',
|
|
|
beforePayload: {
|
|
|
page: 1,
|
|
|
pageSize: 20,
|
|
@@ -77,6 +92,13 @@ export default {
|
|
|
openImport() {
|
|
|
this.$store.commit("set_import_on", true);
|
|
|
},
|
|
|
+ search() {
|
|
|
+ this.loadFLTable({ page: 1, pageSize: 20});
|
|
|
+ },
|
|
|
+ reloadTable() {
|
|
|
+ this.fileName = '';
|
|
|
+ this.loadFLTable({ page: 1, pageSize: 20});
|
|
|
+ },
|
|
|
loadFLTable(payload) {
|
|
|
const loading = this.$loading({
|
|
|
lock: true,
|
|
@@ -85,6 +107,9 @@ export default {
|
|
|
background: "rgba(0, 0, 0, 0.7)"
|
|
|
});
|
|
|
payload.generated = "false";
|
|
|
+ if(this.fileName) {
|
|
|
+ payload.fileName = this.fileName
|
|
|
+ }
|
|
|
this.beforePayload = payload;
|
|
|
try {
|
|
|
this.$store
|