Browse Source

Merge branch 'dev-220309' of http://git.elinkit.com.cn:7070/r/epmet-oper-gov into dev-220309

shibei_master
dai 3 years ago
parent
commit
a4b9538966
  1. 25
      src/views/components/resiSearch.vue
  2. 10
      src/views/modules/base/resi.vue
  3. 15
      src/views/modules/communityParty/elegant/index.vue
  4. 33
      src/views/modules/communityService/sqzzz/index.vue
  5. 2
      src/views/modules/workSys/demandCate.vue

25
src/views/components/resiSearch.vue

@ -52,6 +52,7 @@
placeholder="楼号"
size="small"
clearable
style="width: 120px;"
class="resi-cell-select"
:disabled="changeVDisabled"
@clear="handleClearBuild"
@ -65,12 +66,13 @@
>
</el-option>
</el-select>
<!-- <el-select
<el-select
v-model.trim="form.UNIT_ID"
:disabled="changeBDisabled"
placeholder="单元"
size="small"
clearable
style="width: 120px;"
class="resi-cell-select"
@click="handleClearDan"
@change="handleChangeD"
@ -86,9 +88,10 @@
<el-select
v-model.trim="form.HOME_ID"
:disabled="changeDDisabled"
placeholder="号"
placeholder="号"
size="small"
clearable
style="width: 120px;"
class="resi-cell-select"
>
<el-option
@ -98,7 +101,7 @@
:value="item.value"
>
</el-option>
</el-select> -->
</el-select>
</div>
</div>
</el-col>
@ -190,6 +193,7 @@
</el-col> -->
<el-col :span="24">
<el-button type="primary" size="small" @click="handleSearch">查询</el-button>
<el-button class="diy-button--reset" size="small" @click="resetForm">重置</el-button>
</el-col>
</el-row>
<div class="resi-down" @click="handleOpenSearch">
@ -372,6 +376,12 @@ export default {
this.form.UNIT_ID = ''
this.form.HOME_ID = ''
},
resetForm(formName) {
for(const n in this.form) {
this.form[n] = ''
}
this.handleSearch()
},
handleSearch() {
// console.log('formmmmm---', this.form)
const itemTypes = ['daterange', 'timerange']
@ -435,9 +445,13 @@ export default {
if (n === val) {
if (this.fixedList.length > 0) {
let _item = {}
let hasVal = false
this.fixedList.forEach((item, index) => {
if (item.columnName === val) {
if (item.columnName == val) {
hasVal = true
item.columnValue[0] = this.form[val]
if (!this.form[val]) this.fixedList.splice(index, 1)
console.log('fixedList----val', this.fixedList)
} else {
_item = {
queryType: 'equal',
@ -445,10 +459,11 @@ export default {
columnName: val,
columnValue: [this.form[val]]
}
console.log('fixedList----else', _item)
// this.$set(this.fixedList, index, _item)
}
})
if (Object.keys(_item).length > 0) this.fixedList.push(_item)
if (Object.keys(_item).length > 0 && !hasVal) this.fixedList.push(_item)
} else {
this.$set(this.fixedList, 0, {
queryType: 'equal',

10
src/views/modules/base/resi.vue

@ -12,11 +12,12 @@
@click="handleAdd">新增</el-button>
<el-button class="diy-button--export"
size="small"
@click="handleExportModule('room')">下载人口模板</el-button>
@click="handleExportModule('room')">下载模板</el-button>
<el-upload ref="upload"
class="upload-demo"
action="uploadUlr"
:limit="1"
:accept="'.xls,xlsx'"
:with-credentials="true"
:show-file-list="false"
:auto-upload="true"
@ -62,7 +63,8 @@
align="center"
:fixed="item.columnName == 'NAME' ? 'left' : false"
:show-overflow-tooltip="true"
:width="item.itemType === 'radio' ? computedWidth(item.label) : 180">
>
<!-- :width="item.itemType === 'radio' ? computedWidth(item.label) : 180" -->
<template slot-scope="scope">
<a v-if="item.columnName == 'NAME'"
class="name-a"
@ -277,7 +279,7 @@ export default {
return {
exportBtn: false,
exportBtnTitle: '导出',
importBtnTitle: '导入人员数据',
importBtnTitle: '导入',
importLoading: false,
rowVisible: false,
tableLoading: false,
@ -659,7 +661,7 @@ export default {
// this.$message.error('')
// })
this.importLoading = false
this.importBtnTitle = '导入人员数据'
this.importBtnTitle = '导入'
this.$refs.upload.clearFiles()
},
handleClick (tab, event) {

15
src/views/modules/communityParty/elegant/index.vue

@ -48,6 +48,10 @@
<div class="resi-row-btn">
<el-button class="diy-button--add" size="small" @click="handleAdd">新增</el-button>
<el-button
class="diy-button--export"
size="small"
@click="handleExportModule('room')">下载模板</el-button>
<el-upload
ref="upload"
class="upload-demo"
@ -63,10 +67,7 @@
<el-button size="small" class="diy-button--delete" :loading="importLoading">{{importBtnTitle}}</el-button>
</el-upload>
<el-button class="diy-button--reset" size="small" :loading="exportBtn" @click="handleExport">{{ exportBtnTitle }}</el-button>
<!-- <el-button
class="diy-button--export"
size="small"
@click="handleExportModule('room')">下载模板</el-button> -->
</div>
<el-table
@ -236,7 +237,7 @@ export default {
data() {
return {
uploadUlr: window.SITE_CONFIG['apiURL'] + '/oss/file/uploadqrcodeV2',
importBtnTitle: '导入数据',
importBtnTitle: '导入',
importLoading: false,
exportBtn: false,
exportBtnTitle: '导出',
@ -381,7 +382,7 @@ export default {
this.unloadPencent = Number(file.percentage.toFixed(0))
},
async handleExportModule () {
let url = "/resi/partymember/import/template-download"
let url = "/resi/partymember/icpartymemberstyle/import/template-download"
let params = {}
@ -477,7 +478,7 @@ export default {
// this.$message.error('')
// })
this.importLoading = false
this.importBtnTitle = '导入数据'
this.importBtnTitle = '导入'
this.$refs.upload.clearFiles()
},
async handleExport() {

33
src/views/modules/communityService/sqzzz/index.vue

@ -35,6 +35,10 @@
<el-button class="diy-button--add" size="small" @click="handleAdd"
>新增</el-button
>
<el-button
class="diy-button--export"
size="small"
@click="handleExportModule('room')">下载模板</el-button>
<el-upload
ref="upload"
class="upload-btn"
@ -232,6 +236,35 @@ export default {
this.getTableData();
},
methods: {
async handleExportModule () {
let url = "/heart/iccommunityselforganization/import-template-download"
let params = {}
await this.$http
.post(url, params)
.then(res => {
// this.download(res.data, title + '.xls')
if (res.headers["content-disposition"]) {
let fileName = window.decodeURI(res.headers["content-disposition"].split(";")[1].split("=")[1])
console.log('filename', fileName)
let blob = new Blob([res.data], { type: 'application/vnd.ms-excel' })
var url = window.URL.createObjectURL(blob)
var aLink = document.createElement('a')
aLink.style.display = 'none'
aLink.href = url
aLink.setAttribute('download', fileName)
document.body.appendChild(aLink)
aLink.click()
document.body.removeChild(aLink) //
window.URL.revokeObjectURL(url) //blob
} else this.$message.error('下载失败')
})
.catch(err => {
console.log('err', err)
return this.$message.error('网络错误')
})
},
//
handleExcelSuccess(res, file) {
if (res.code === 0 && res.msg === "success") {

2
src/views/modules/workSys/demandCate.vue

@ -32,7 +32,7 @@
<div class="resi-row-btn">
<el-button class="diy-button--add"
size="small"
@click="handleAdd('1', 'add')">新增分类</el-button>
@click="handleAdd('1', 'add')">新增</el-button>
</div>
<el-table :data="tableData"

Loading…
Cancel
Save