Browse Source

补全一户一码信息

shibei_master
zhaoyongnian 3 years ago
parent
commit
b1a2798947
  1. 47
      src/views/modules/base/community/communityTable.vue
  2. 2
      src/views/modules/base/community/roomForm.vue

47
src/views/modules/base/community/communityTable.vue

@ -2,6 +2,12 @@
<div>
<div class="div_btn">
<el-button v-if="showYhymInfo"
style=""
class="diy-button--reset"
size="small"
:loading="yhymLoading"
@click="handleYhymInfo">补全一户一码信息</el-button>
<el-button style=""
class="diy-button--add"
size="small"
@ -204,7 +210,7 @@
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="dialogVisible = false"> </el-button>
<!-- <el-button type="primary" @click="dialogVisible = false"> </el-button> -->
</span>
</el-dialog>
@ -233,6 +239,9 @@ export default {
tableLoading: true,
showImportBtn: false,//
roleList: [],//
showYhymInfo: false, //
yhymLoading: false,
agencyObj: {},//
@ -273,7 +282,13 @@ export default {
async loadTable (fromTree, treeObj) {
console.log(111, this.staffAgencyId)
//
this.roleList = localStorage.getItem('roleList')
if (this.roleList.indexOf('root_manager') > -1 || this.roleList.indexOf('manager') > -1) {
this.showYhymInfo = true
} else {
this.showYhymInfo = false
}
this.tableLoading = true
if (fromTree) {
this.agencyObj = treeObj
@ -357,6 +372,34 @@ export default {
})
},
//
async handleYhymInfo () {
this.yhymLoading = true
const url = "/gov/org/house/createBatchHouseCodeAndUrl"
let params = {}
const { data, code, msg } = await requestPost(url, params)
if (code === 0) {
this.yhymLoading = false
this.$message({
type: "success",
message: "删除成功"
});
} else if (code > 8000) {
this.yhymLoading = false
this.$message({
showClose: true,
message: msg,
duration: 0
})
} else {
this.yhymLoading = false
this.$message.error(msg)
}
},
handleEdit (row) {
this.formTitle = '修改小区'
this.formShow = true

2
src/views/modules/base/community/roomForm.vue

@ -50,7 +50,7 @@
v-model="dataForm.houseCode">
</el-input>
</el-form-item>
<div style="display: flex;flex-direction: column;">
<div v-if="dataForm.houseQrcodeUrl" style="display: flex;flex-direction: column;">
<img style="margin-left: 70px;width: 200px;" :src="dataForm.houseQrcodeUrl">
<a style="margin-left: 80px" :href="dataForm.houseQrcodeUrl" target="_blank">下载</a>
</div>

Loading…
Cancel
Save