diff --git a/src/views/modules/base/community/buildForm.vue b/src/views/modules/base/community/buildForm.vue index c0e9208f..c53b55ce 100644 --- a/src/views/modules/base/community/buildForm.vue +++ b/src/views/modules/base/community/buildForm.vue @@ -28,7 +28,7 @@ prop="type" label-width="150px" style="display: block"> - + 商品房 自建房 @@ -120,6 +120,7 @@ export default { formType: 'add', //表单操作类型 add新增,edit编辑,detail详情 buildingId: '', //楼栋ID + buildType: "1", dataForm: { agencyId: '', // 所属组织ID agencyName: '', @@ -130,7 +131,7 @@ export default { totalUnitNum: 0,//单元数 totalFloorNum: 0,//层数 totalHouseNum: 0,//户数 - type: '1',//房屋类型 + type: '',//房屋类型 location: '', //坐标位置 longitude: '', //经度 latitude: '' //纬度 @@ -160,7 +161,9 @@ export default { if (row) { this.buildingId = row.buildingId this.dataForm = row + this.buildType = row.buildingTypeKey } + console.log(row) }, @@ -173,13 +176,14 @@ export default { this.dataForm.buildingId = this.buildingId } + this.dataForm.type = this.buildType const { data, code, msg } = await requestPost(url, this.dataForm) if (code === 0) { this.$message({ type: 'success', - message: '添加楼栋成功' + message: '操作成功' }) this.resetData() this.$emit('dialogOk') diff --git a/src/views/modules/base/community/buildTable.vue b/src/views/modules/base/community/buildTable.vue index 9557b448..e9ffd683 100644 --- a/src/views/modules/base/community/buildTable.vue +++ b/src/views/modules/base/community/buildTable.vue @@ -32,15 +32,15 @@
导出 新增楼宇 下载楼宇模板 导入小区数据 + type="red">导入小区数据
@@ -83,9 +83,7 @@ - - + { + this.$refs.ref_form.initForm('edit', row, this.agencyObj) + }) }, addFormCancle () { @@ -442,6 +442,26 @@ export default { }