根据房屋状态标记的不同颜色改变选中户的边框颜色
Showing
3 changed files
with
19 additions
and
10 deletions
| ... | @@ -138,7 +138,7 @@ | ... | @@ -138,7 +138,7 @@ |
| 138 | v-for="(item, index) in dyztList" | 138 | v-for="(item, index) in dyztList" |
| 139 | :key="index" | 139 | :key="index" |
| 140 | class="cp" | 140 | class="cp" |
| 141 | @click="handleChoosedH(item.bsms)" | 141 | @click="handleChoosedH(item.bsms,item.color)" |
| 142 | > | 142 | > |
| 143 | <td> | 143 | <td> |
| 144 | <i class="fa fa-circle" :style="{ color: item.color }"></i | 144 | <i class="fa fa-circle" :style="{ color: item.color }"></i |
| ... | @@ -165,7 +165,7 @@ | ... | @@ -165,7 +165,7 @@ |
| 165 | v-for="(item, index) in fwxzList" | 165 | v-for="(item, index) in fwxzList" |
| 166 | :key="index" | 166 | :key="index" |
| 167 | class="cp" | 167 | class="cp" |
| 168 | @click="handleChoosedH(item.bsms)" | 168 | @click="handleChoosedH(item.bsms,item.color)" |
| 169 | > | 169 | > |
| 170 | <td> | 170 | <td> |
| 171 | <i class="fa fa-circle" :style="{ color: item.color }"></i | 171 | <i class="fa fa-circle" :style="{ color: item.color }"></i |
| ... | @@ -195,7 +195,7 @@ | ... | @@ -195,7 +195,7 @@ |
| 195 | v-for="(item, index) in fwytList" | 195 | v-for="(item, index) in fwytList" |
| 196 | :key="index" | 196 | :key="index" |
| 197 | class="cp" | 197 | class="cp" |
| 198 | @click="handleChoosedH(item.bsms)" | 198 | @click="handleChoosedH(item.bsms,item.color)" |
| 199 | > | 199 | > |
| 200 | <td> | 200 | <td> |
| 201 | <i class="fa fa-circle" :style="{ color: item.color }"></i | 201 | <i class="fa fa-circle" :style="{ color: item.color }"></i |
| ... | @@ -596,14 +596,23 @@ export default { | ... | @@ -596,14 +596,23 @@ export default { |
| 596 | } | 596 | } |
| 597 | }); | 597 | }); |
| 598 | }, | 598 | }, |
| 599 | //选中房屋状态 | 599 | //切换房屋状态 |
| 600 | handleChoosedH(bsms) { | 600 | handleChoosedH(bsms,color) { |
| 601 | console.log(bsms,'bsms'); | 601 | //每次切换房屋状态,将之前高亮的户边框颜色重置为默认 |
| 602 | this.$refs.lpbContent.choosedList = []; | ||
| 603 | this.$refs.lpbContent.$refs.hBsm.forEach((item) => { | ||
| 604 | item.style.borderColor = '#E6E6E6'; | ||
| 605 | }); | ||
| 606 | // console.log(bsms,'bsms'); | ||
| 607 | // console.log(color,'color'); | ||
| 602 | // Dyzt:{list:[],mj:''} | 608 | // Dyzt:{list:[],mj:''} |
| 603 | //清除选中户 | 609 | //清除选中户 |
| 604 | this.$refs.lpbContent.clearChoosedH(); | 610 | // this.$refs.lpbContent.clearChoosedH(); |
| 605 | //给hBsmList传值 | 611 | this.$nextTick(()=>{ |
| 606 | this.$refs.lpbContent.choosedList = bsms; | 612 | //给hBsmList传值 |
| 613 | this.$refs.lpbContent.choosedList = bsms; | ||
| 614 | this.$refs.lpbContent.borderColor = color; | ||
| 615 | }) | ||
| 607 | }, | 616 | }, |
| 608 | //批量添加不动产单元号 | 617 | //批量添加不动产单元号 |
| 609 | addBdcdyh() { | 618 | addBdcdyh() { | ... | ... |
This diff is collapsed.
Click to expand it.
-
Please register or sign in to post a comment