|
@@ -1,17 +1,17 @@
|
|
|
<template>
|
|
|
<fullscreen :fullscreen.sync="fullscreen" class="container" style="margin: 0;">
|
|
|
<div class="container-box">
|
|
|
- <div class="search">
|
|
|
+ <div class="search" v-if="!provincialCompany">
|
|
|
<mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
|
|
|
- <div v-if="!provincialCompany">
|
|
|
+ <div>
|
|
|
<el-button class="btn-check" plain size="medium" type="primary" @click="downloadTemplate">下载模板
|
|
|
</el-button>
|
|
|
- <myUpload style="display:inline-block;" :fileInfo="fileInfo" @onChange="onChange"
|
|
|
+ <myUpload style="display:inline-block;" :fileInfo="fileInfo" @onSuccess="onSuccess"
|
|
|
:fileList="fileInfo.fileList"></myUpload>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="tabbox">
|
|
|
- <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData"
|
|
|
+ <el-table :key="key" :height="height" class="com-table" ref="multipleTable" :data="tableData"
|
|
|
tooltip-effect="dark" size="small" border style="width: 100%" :header-cell-style="headerStyleFun" :cell-style="cellStyle">
|
|
|
<el-table-column align="center" :label="toolTit">
|
|
|
<el-table-column prop="cityName" align="center" label="地市" >
|
|
@@ -85,13 +85,13 @@
|
|
|
typexz:"xlsx"
|
|
|
},
|
|
|
provincialCompany:false,
|
|
|
+ height:'calc(100% - 40px)',
|
|
|
+ key:0
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
- onChange(file, fileList){
|
|
|
- if (file.status === 'success'){
|
|
|
- this.searchInfo([this.searchList[0].value], 1);
|
|
|
- }
|
|
|
+ onSuccess(file){
|
|
|
+ this.searchInfo([this.searchList[0].value], 1);
|
|
|
},
|
|
|
headerStyleFun({row, column, rowIndex, columnIndex}){
|
|
|
if (rowIndex === 0){
|
|
@@ -187,7 +187,11 @@
|
|
|
flag = true
|
|
|
}
|
|
|
}
|
|
|
- this.provincialCompany = !flag
|
|
|
+ if (!flag){
|
|
|
+ this.provincialCompany = true
|
|
|
+ this.height = "calc(100%)"
|
|
|
+ this.key += 1
|
|
|
+ }
|
|
|
}
|
|
|
},
|
|
|
mounted() {
|
|
@@ -202,7 +206,7 @@
|
|
|
},
|
|
|
created() {
|
|
|
|
|
|
- }
|
|
|
+ },
|
|
|
}
|
|
|
</script>
|
|
|
<style scoped lang="scss">
|