29e92088 by 杨威

优化楼盘表渲染,户权属状态图标click冒泡处理

1 parent 80e074a9
...@@ -488,13 +488,15 @@ export default { ...@@ -488,13 +488,15 @@ export default {
488 //清空已选中层户 488 //清空已选中层户
489 this.cbsmList = []; 489 this.cbsmList = [];
490 this.bsms = []; 490 this.bsms = [];
491 console.log(this.$refs.lpbContent.$refs.cBsm,'this.$refs.lpbContent.$refs.cBsm');
492 this.$nextTick(()=>{ 491 this.$nextTick(()=>{
492 //户
493 this.$refs.lpbContent.$refs.hBsm.forEach(item=>{ 493 this.$refs.lpbContent.$refs.hBsm.forEach(item=>{
494 item.style.borderColor = 'rgb(230, 230, 230)';
494 if (item.className == "tdSelect") { 495 if (item.className == "tdSelect") {
495 item.className = ""; 496 item.className = "";
496 } 497 }
497 }); 498 });
499 //层
498 this.$refs.lpbContent.$refs.cBsm.forEach(item=>{ 500 this.$refs.lpbContent.$refs.cBsm.forEach(item=>{
499 console.log(item.className,'item.className'); 501 console.log(item.className,'item.className');
500 item.className = "floor"; 502 item.className = "floor";
...@@ -579,12 +581,10 @@ export default { ...@@ -579,12 +581,10 @@ export default {
579 } else { 581 } else {
580 //单击 TO DO 582 //单击 TO DO
581 } 583 }
582 console.log(this.bsms);
583 }, 584 },
584 //获取选中层bsmlist 585 //获取选中层bsmlist
585 getCbsm(data){ 586 getCbsm(data){
586 this.cbsmList = data; 587 this.cbsmList = data;
587 console.log(this.cbsmList);
588 }, 588 },
589 //不动产单元号输入框事件 589 //不动产单元号输入框事件
590 inputFocus() { 590 inputFocus() {
......
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
21 ref="ljz" 21 ref="ljz"
22 v-for="(ljzs, ljzIndex) in lpbData.ljzs" 22 v-for="(ljzs, ljzIndex) in lpbData.ljzs"
23 :key="ljzIndex" 23 :key="ljzIndex"
24 :style="{'marginTop':ljzs.zdys.length > 0 ? '-30px':0}"
24 > 25 >
25 <!-- <div class="ljz-zdy-wrap" :style="{'min-height':ljzzdyHeight+40+'px'}"> --> 26 <!-- <div class="ljz-zdy-wrap" :style="{'min-height':ljzzdyHeight+40+'px'}"> -->
26 <!-- 循环逻辑幢下的幢单元 --> 27 <!-- 循环逻辑幢下的幢单元 -->
...@@ -65,9 +66,9 @@ ...@@ -65,9 +66,9 @@
65 @contextmenu.prevent="openMenu($event, hs, 'h')" 66 @contextmenu.prevent="openMenu($event, hs, 'h')"
66 > 67 >
67 {{ hs.shbw }} 68 {{ hs.shbw }}
68 <span class="hqszt lin" v-show="hs.qszt == '0'"></span> 69 <span @click.stop="qsztClick" class="hqszt lin" v-show="hs.qszt == '0'"></span>
69 <span class="hqszt zheng" v-show="hs.qszt == '1'"></span> 70 <span @click.stop="qsztClick" class="hqszt zheng" v-show="hs.qszt == '1'"></span>
70 <span class="hqszt xian" v-show="hs.qszt == '2'"></span> 71 <span @click.stop="qsztClick" class="hqszt xian" v-show="hs.qszt == '2'" ></span>
71 </td> 72 </td>
72 </tr> 73 </tr>
73 </table> 74 </table>
...@@ -119,9 +120,9 @@ ...@@ -119,9 +120,9 @@
119 @contextmenu.prevent="openMenu($event, hs, 'h')" 120 @contextmenu.prevent="openMenu($event, hs, 'h')"
120 > 121 >
121 {{ hs.shbw }} 122 {{ hs.shbw }}
122 <span class="hqszt lin" v-show="hs.qszt == '0'"></span> 123 <span @click.stop="qsztClick" class="hqszt lin" v-show="hs.qszt == '0'"></span>
123 <span class="hqszt zheng" v-show="hs.qszt == '1'"></span> 124 <span @click.stop="qsztClick" class="hqszt zheng" v-show="hs.qszt == '1'"></span>
124 <span class="hqszt xian" v-show="hs.qszt == '2'"></span> 125 <span @click.stop="qsztClick" class="hqszt xian" v-show="hs.qszt == '2'" ></span>
125 </td> 126 </td>
126 </tr> 127 </tr>
127 </table> 128 </table>
...@@ -178,9 +179,9 @@ ...@@ -178,9 +179,9 @@
178 @contextmenu.prevent="openMenu($event, hs, 'h')" 179 @contextmenu.prevent="openMenu($event, hs, 'h')"
179 > 180 >
180 {{ hs.shbw }} 181 {{ hs.shbw }}
181 <span class="hqszt lin" v-show="hs.qszt == '0'"></span> 182 <span @click.stop="qsztClick" class="hqszt lin" v-show="hs.qszt == '0'"></span>
182 <span class="hqszt zheng" v-show="hs.qszt == '1'"></span> 183 <span @click.stop="qsztClick" class="hqszt zheng" v-show="hs.qszt == '1'"></span>
183 <span class="hqszt xian" v-show="hs.qszt == '2'"></span> 184 <span @click.stop="qsztClick" class="hqszt xian" v-show="hs.qszt == '2'" ></span>
184 </td> 185 </td>
185 </tr> 186 </tr>
186 </table> 187 </table>
...@@ -222,9 +223,9 @@ ...@@ -222,9 +223,9 @@
222 @contextmenu.prevent="openMenu($event, hs, 'h')" 223 @contextmenu.prevent="openMenu($event, hs, 'h')"
223 > 224 >
224 {{ hs.shbw }} 225 {{ hs.shbw }}
225 <span class="hqszt lin" v-show="hs.qszt == '0'"></span> 226 <span @click.stop="qsztClick" class="hqszt lin" v-show="hs.qszt == '0'"></span>
226 <span class="hqszt zheng" v-show="hs.qszt == '1'"></span> 227 <span @click.stop="qsztClick" class="hqszt zheng" v-show="hs.qszt == '1'"></span>
227 <span class="hqszt xian" v-show="hs.qszt == '2'"></span> 228 <span @click.stop="qsztClick" class="hqszt xian" v-show="hs.qszt == '2'" ></span>
228 </td> 229 </td>
229 </tr> 230 </tr>
230 </table> 231 </table>
...@@ -339,11 +340,14 @@ export default { ...@@ -339,11 +340,14 @@ export default {
339 sjc: "", //当前的层的SJC +1 340 sjc: "", //当前的层的SJC +1
340 }, 341 },
341 formLabelWidth: "120px", 342 formLabelWidth: "120px",
343 yclpbData:{},
344 sclpbData:{}
342 }; 345 };
343 }, 346 },
344 created() {}, 347 created() {},
345 mounted() { 348 mounted() {
346 this.getLpb(this.$store.state.zrzbsm, this.$parent.scyclx); 349 this.getLpb(this.$store.state.zrzbsm, "0");
350 this.getLpb(this.$store.state.zrzbsm, "1");
347 setTimeout(() => { 351 setTimeout(() => {
348 //tab-content宽度 - 右侧图例宽度 - lp-overview滚动条宽度 - lpbContent的pandingRight 352 //tab-content宽度 - 右侧图例宽度 - lp-overview滚动条宽度 - lpbContent的pandingRight
349 this.lpbContentWidth = this.$store.state.contentWidth - 34 - 20; 353 this.lpbContentWidth = this.$store.state.contentWidth - 34 - 20;
...@@ -366,7 +370,14 @@ export default { ...@@ -366,7 +370,14 @@ export default {
366 res.result.ljzs = res.result.ljzs 370 res.result.ljzs = res.result.ljzs
367 .sort(this.compare("place")) 371 .sort(this.compare("place"))
368 .reverse(); 372 .reverse();
369 this.lpbData = res.result == null ? this.lpbData : res.result; 373 // this.lpbData = res.result == null ? this.lpbData : res.result;
374 //给实预测楼盘表对象赋值,默认加载预测楼盘表数据
375 if(scyclx == 0){
376 this.yclpbData = res.result == null ? this.yclpbData : res.result;
377 this.lpbData = this.yclpbData;
378 }else{
379 this.sclpbData = res.result == null ? this.sclpbData : res.result;
380 }
370 this.$nextTick(() => { 381 this.$nextTick(() => {
371 //渲染楼盘表 382 //渲染楼盘表
372 this.dataChange(); 383 this.dataChange();
...@@ -438,6 +449,7 @@ export default { ...@@ -438,6 +449,7 @@ export default {
438 } 449 }
439 450
440 //计算逻辑幢下的幢单元和层户的高度 451 //计算逻辑幢下的幢单元和层户的高度
452 this.ljzzdyHeight = 1;
441 if (this.$refs.ljzzdy != undefined && this.$refs.ljzzdy.length > 0) { 453 if (this.$refs.ljzzdy != undefined && this.$refs.ljzzdy.length > 0) {
442 //判断自然幢下有没有比层户高的幢单元 454 //判断自然幢下有没有比层户高的幢单元
443 let higher = true; 455 let higher = true;
...@@ -617,6 +629,9 @@ export default { ...@@ -617,6 +629,9 @@ export default {
617 }); 629 });
618 }, 630 },
619 //end 631 //end
632 qsztClick(){
633
634 },
620 }, 635 },
621 computed: { 636 computed: {
622 createFlagChange() { 637 createFlagChange() {
...@@ -631,7 +646,12 @@ export default { ...@@ -631,7 +646,12 @@ export default {
631 }, 646 },
632 watch: { 647 watch: {
633 scyclx(n) { 648 scyclx(n) {
634 this.getLpb(this.$store.state.zrzbsm, n); 649 // this.getLpb(this.$store.state.zrzbsm, n);
650 if(n == '0'){
651 this.lpbData = this.yclpbData;
652 }else{
653 this.lpbData = this.sclpbData;
654 }
635 }, 655 },
636 createFlagChange: function(val) { 656 createFlagChange: function(val) {
637 setTimeout(() => { 657 setTimeout(() => {
......