|
@@ -146,8 +146,13 @@
|
|
|
</el-button>
|
|
|
</el-col>
|
|
|
<el-col :span="1.5">
|
|
|
- <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleImport"
|
|
|
- v-hasPermi="['gljt:admin:import']">导入
|
|
|
+ <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleImport(false)"
|
|
|
+ v-hasPermi="['gljt:admin:import']">admin导入
|
|
|
+ </el-button>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="1.5">
|
|
|
+ <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleImport(true)" v-hasPermi="['gljt:temp:exprot']"
|
|
|
+ >导入
|
|
|
</el-button>
|
|
|
</el-col>
|
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
@@ -490,7 +495,7 @@
|
|
|
:limit="1"
|
|
|
accept=".xlsx, .xls"
|
|
|
:headers="upload.headers"
|
|
|
- :action="upload.url"
|
|
|
+ :action="isUser? upload.url2:upload.url"
|
|
|
:data="upload.form"
|
|
|
:disabled="upload.isUploading"
|
|
|
:on-progress="handleFileUploadProgress"
|
|
@@ -506,7 +511,18 @@
|
|
|
</el-upload>
|
|
|
|
|
|
<el-form-item label="行政区划" prop="xzqh">
|
|
|
+
|
|
|
+ <RegionCascaderSelect
|
|
|
+ v-if="isUser"
|
|
|
+ v-model="upload.form.xzqh"
|
|
|
+ style="width: 100%"
|
|
|
+ valueProp="code"
|
|
|
+ :checkStrictly="false"
|
|
|
+ :isDataRoot="true"
|
|
|
+ >
|
|
|
+ </RegionCascaderSelect>
|
|
|
<el-input
|
|
|
+ v-else
|
|
|
v-model="upload.form.xzqh"
|
|
|
placeholder="请输入行政区划编码"
|
|
|
clearable
|
|
@@ -544,6 +560,7 @@
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
+ isUser:false,
|
|
|
pickerOptions: {
|
|
|
shortcuts: [{
|
|
|
text: '最近一周',
|
|
@@ -585,7 +602,8 @@
|
|
|
xzqh: '', // 行政区划编码
|
|
|
},
|
|
|
// 上传的地址
|
|
|
- url: process.env.VUE_APP_BASE_API + '/gljt/gljtLr/importData'
|
|
|
+ url: process.env.VUE_APP_BASE_API + '/gljt/gljtLr/importData',
|
|
|
+ url2: process.env.VUE_APP_BASE_API + '/gljt/gljtLr/importData2'
|
|
|
},
|
|
|
// 补贴标准
|
|
|
parmarBtbz: {
|
|
@@ -692,7 +710,8 @@
|
|
|
this.getList();
|
|
|
},
|
|
|
methods: {
|
|
|
- handleImport() {
|
|
|
+ handleImport(is) {
|
|
|
+ this.isUser=is;
|
|
|
this.upload.form.xzqh = '';
|
|
|
this.upload.submitLoading = false;
|
|
|
this.upload.open = true;
|
|
@@ -716,6 +735,10 @@
|
|
|
this.$message.warning('请输入行政区划编码');
|
|
|
return;
|
|
|
}
|
|
|
+ console.log(this.upload.form.xzqh,'this.upload.form.xzqh');
|
|
|
+ if(this.isUser){
|
|
|
+ this.upload.form.xzqh=this.upload.form.xzqh[this.upload.form.xzqh.length-1]
|
|
|
+ }
|
|
|
this.upload.submitLoading = true;
|
|
|
this.$refs.upload.submit();
|
|
|
},
|