ef94474d by zhaoqian

自然幢不动产单元号的更改影响其自然幢下的户的不动产单元号的信息

1 parent f142be6b
...@@ -126,3 +126,13 @@ export function cxlzZrzList(data) { ...@@ -126,3 +126,13 @@ export function cxlzZrzList(data) {
126 }) 126 })
127 } 127 }
128 128
129 /**
130 * 查询权籍_建筑物区分所有权业主共有部分调查表
131 */
132 export function getHCountByZrzbsm(id) {
133 return request({
134 url: '/fw/qjZrz/getHCountByZrzbsm',
135 method: 'get',
136 params: {id}
137 })
138 }
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
14 </td> 14 </td>
15 <td colspan="2" class="tdright"><i class="requisite">*</i>自然幢号</td> 15 <td colspan="2" class="tdright"><i class="requisite">*</i>自然幢号</td>
16 <td colspan="4" class="psr"> 16 <td colspan="4" class="psr">
17 <input class="formInput percent80" ref="zrzh" @blur="inputBlur($event)" :disabled="disabled" maxlength="24" v-model="form.zrzh"> 17 <input class="formInput percent80" ref="zrzh" @blur="inputBlurZrzh($event)" :disabled="disabled" maxlength="24" v-model="form.zrzh">
18 <el-button @click.prevent="generatorCode" type="warning" :disabled="disabled" class="createBtn" size="mini">生成</el-button> 18 <el-button @click.prevent="generatorCode" type="warning" :disabled="disabled" class="createBtn" size="mini">生成</el-button>
19 </td> 19 </td>
20 </tr> 20 </tr>
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
25 </td> 25 </td>
26 <td colspan="2" class="tdright"><i class="requisite">*</i>不动产单元号</td> 26 <td colspan="2" class="tdright"><i class="requisite">*</i>不动产单元号</td>
27 <td colspan="4"> 27 <td colspan="4">
28 <input class="formInput " ref="bdcdyh" @blur="inputBlur($event)" :disabled="disabled" maxlength="28" v-model="form.bdcdyh"> 28 <input class="formInput " ref="bdcdyh" @blur="inputBlur($event)" disabled maxlength="28" v-model="form.bdcdyh">
29 </td> 29 </td>
30 </tr> 30 </tr>
31 31
...@@ -285,7 +285,7 @@ ...@@ -285,7 +285,7 @@
285 <script> 285 <script>
286 import Qlr from "@components/formMenu/qlr"; 286 import Qlr from "@components/formMenu/qlr";
287 import Qlxz from "@components/formMenu/qlxz"; 287 import Qlxz from "@components/formMenu/qlxz";
288 import {getBdcdyh,saveZrzInfo,getZrzDetailByBsm} from "@api/zrz" 288 import {getBdcdyh,saveZrzInfo,getZrzDetailByBsm,getHCountByZrzbsm} from "@api/zrz"
289 import {getQjZdjbxxDetailById} from "@api/zd" 289 import {getQjZdjbxxDetailById} from "@api/zd"
290 import {submit,registerCall} from "@api/common" 290 import {submit,registerCall} from "@api/common"
291 import geoUtils from "@components/lineTree/tx/js/geoUtils"; 291 import geoUtils from "@components/lineTree/tx/js/geoUtils";
...@@ -315,6 +315,12 @@ ...@@ -315,6 +315,12 @@
315 315
316 lx:"zrz", 316 lx:"zrz",
317 bsm:'', 317 bsm:'',
318
319 initZrzh:'',
320 finishZrzh:'',
321 hcount:0,
322 booleanUpdateH:false,
323
318 form:{ 324 form:{
319 zrzbsm:'', //自然幢标识码 325 zrzbsm:'', //自然幢标识码
320 zdbsm:'', //宗地标识码 326 zdbsm:'', //宗地标识码
...@@ -360,6 +366,7 @@ ...@@ -360,6 +366,7 @@
360 glbsm:'', //关联标识码 366 glbsm:'', //关联标识码
361 sx:'', //顺序 367 sx:'', //顺序
362 }], 368 }],
369 booleanUpdateH:false,
363 }, 370 },
364 value: '', 371 value: '',
365 ytTitleRowspan:1, //用途的单元格垂直合并数量 372 ytTitleRowspan:1, //用途的单元格垂直合并数量
...@@ -467,6 +474,10 @@ ...@@ -467,6 +474,10 @@
467 } 474 }
468 }, 475 },
469 onSave(){ 476 onSave(){
477
478 //保存之前的自然幢号,用于判断该自然幢的不动产单元号是否更改,是否更改其下户的不动产单元号
479 this.finishZrzh = this.form.zrzh;
480 this.form.booleanUpdateH =this.booleanUpdateH;
470 //判断自然幢号和不动产单元号是否手动修改过(自然幢号和不动产单元号的前19位是否和宗地代码一致) 481 //判断自然幢号和不动产单元号是否手动修改过(自然幢号和不动产单元号的前19位是否和宗地代码一致)
471 console.log(this.form,'this.form'); 482 console.log(this.form,'this.form');
472 //给校验项赋值 483 //给校验项赋值
...@@ -614,6 +625,7 @@ ...@@ -614,6 +625,7 @@
614 }) 625 })
615 }, 626 },
616 open() { 627 open() {
628 const self = this;
617 this.$confirm('已经存在不动产单元号或者自然幢号, 是否继续?', '提示', { 629 this.$confirm('已经存在不动产单元号或者自然幢号, 是否继续?', '提示', {
618 confirmButtonText: '确定', 630 confirmButtonText: '确定',
619 cancelButtonText: '取消', 631 cancelButtonText: '取消',
...@@ -623,6 +635,16 @@ ...@@ -623,6 +635,16 @@
623 .then((res)=>{ 635 .then((res)=>{
624 this.form.zrzh=res.result.substring(0,24); 636 this.form.zrzh=res.result.substring(0,24);
625 this.form.bdcdyh=res.result; 637 this.form.bdcdyh=res.result;
638 console.log(self.initZrzh,self.hcount,"self")
639 if(self.initZrzh != null && self.initZrzh !== '' && self.hcount>0){
640 self.booleanUpdateH =true;
641 self.$notify({
642 title: '提示',
643 message: '修改自然幢号,可能会影响该自然幢下户的不动产单元号的重新生成!',
644 duration: 0,
645 type: 'warning'
646 });
647 }
626 }); 648 });
627 this.$message({ 649 this.$message({
628 type: 'success', 650 type: 'success',
...@@ -636,6 +658,7 @@ ...@@ -636,6 +658,7 @@
636 }); 658 });
637 }, 659 },
638 generatorCode(){ 660 generatorCode(){
661 const self = this;
639 console.log(this.form,'this.form'); 662 console.log(this.form,'this.form');
640 if((this.form.zrzh!=null&&this.form.zrzh!=='')||(this.form.bdcdyh!=null&&this.form.bdcdyh!=='')){ 663 if((this.form.zrzh!=null&&this.form.zrzh!=='')||(this.form.bdcdyh!=null&&this.form.bdcdyh!=='')){
641 this.open(); 664 this.open();
...@@ -643,8 +666,18 @@ ...@@ -643,8 +666,18 @@
643 } 666 }
644 getBdcdyh(this.form.zddm,"zrz") 667 getBdcdyh(this.form.zddm,"zrz")
645 .then((res)=>{ 668 .then((res)=>{
646 this.form.zrzh=res.result.substring(0,24); 669 self.form.zrzh=res.result.substring(0,24);
647 this.form.bdcdyh=res.result; 670 self.form.bdcdyh=res.result;
671 console.log(self.initZrzh,self.hcount,"self")
672 if(self.initZrzh != null && self.initZrzh !== '' && self.hcount>0){
673 self.booleanUpdateH =true;
674 self.$notify({
675 title: '提示',
676 message: '修改自然幢号,可能会影响该自然幢下户的不动产单元号的重新生成!',
677 duration: 0,
678 type: 'warning'
679 });
680 }
648 }) 681 })
649 }, 682 },
650 683
...@@ -681,6 +714,8 @@ ...@@ -681,6 +714,8 @@
681 }else { 714 }else {
682 this.disabled = true 715 this.disabled = true
683 } 716 }
717 //初始化的自然幢号,用于判断该自然幢的不动产单元号是否更改,是否更改其下户的不动产单元号
718 this.initZrzh = res.result.zrzh;
684 this.$store.state.zrzh = res.result.zrzh; 719 this.$store.state.zrzh = res.result.zrzh;
685 if(this.form.fwjgList.length===0){ 720 if(this.form.fwjgList.length===0){
686 this.form.fwjgList.push({ 721 this.form.fwjgList.push({
...@@ -734,6 +769,27 @@ ...@@ -734,6 +769,27 @@
734 e.target.style.boxSizing = 'border-box'; 769 e.target.style.boxSizing = 'border-box';
735 } 770 }
736 }, 771 },
772 inputBlurZrzh(e){
773 if(this.initZrzh != null && this.initZrzh !== ''&& e.target.value !==''&& this.hcount>0){
774 if(this.initZrzh !== e.target.value){
775 this.booleanUpdateH =true;
776 this.$notify({
777 title: '提示',
778 message: '修改自然幢号,可能会影响该自然幢下户的不动产单元号的重新生成!',
779 duration: 0,
780 type: 'warning'
781 });
782 }else {
783 this.booleanUpdateH =false;
784 }
785 }
786 if(e.target.value!=''){
787 e.target.style.border=""
788 }else{
789 e.target.style.border="1px solid red";
790 e.target.style.boxSizing = 'border-box';
791 }
792 }
737 }, 793 },
738 created(){ 794 created(){
739 //todo 怎么判断进入到该页面是从新建处进来的,还是从右键宗地进来的!如果是从新建进来的就需要把虚拟宗标识码带过来; 795 //todo 怎么判断进入到该页面是从新建处进来的,还是从右键宗地进来的!如果是从新建进来的就需要把虚拟宗标识码带过来;
...@@ -753,6 +809,11 @@ ...@@ -753,6 +809,11 @@
753 } 809 }
754 }, 810 },
755 mounted() { 811 mounted() {
812 getHCountByZrzbsm(this.$route.query.bsm).then((res)=>{
813 if(res.code === 200){
814 this.hcount = res.result;
815 }
816 });
756 this.$nextTick(() => { 817 this.$nextTick(() => {
757 this.mainBoxWidth = this.$refs.mainBox.clientWidth; 818 this.mainBoxWidth = this.$refs.mainBox.clientWidth;
758 }) 819 })
...@@ -775,6 +836,7 @@ ...@@ -775,6 +836,7 @@
775 "form.zrzh":function (val) { 836 "form.zrzh":function (val) {
776 if (val != '') { 837 if (val != '') {
777 this.$refs.zrzh.style.border = ''; 838 this.$refs.zrzh.style.border = '';
839 this.form.bdcdyh = val+"0000";
778 } 840 }
779 }, 841 },
780 "form.fwxzbsm":{ 842 "form.fwxzbsm":{
......