69c583cc by yangwei

楼盘表

1 parent b4865ddb
1 /* 1 /*
2 * @Description: 2 * @Description:
3 * @Autor: renchao 3 * @Autor: renchao
4 * @LastEditTime: 2023-06-08 13:43:33 4 * @LastEditTime: 2023-06-16 16:06:39
5 */ 5 */
6 import request from '@/utils/request' 6 import request from "@/utils/request";
7 let SERVER = window.config ? window.config : JSON.parse(localStorage.getItem('ApiUrl')) 7 let SERVER = window.config
8 const url = SERVER.SERVERAPI + '/rest/zhcx/lpcx/' 8 ? window.config
9 // 9 : JSON.parse(localStorage.getItem("ApiUrl"));
10 const url = SERVER.SERVERAPI + "/rest/zhcx/lpcx/";
11 //
10 /** 12 /**
11 * @description:楼盘查询- 根据条件进行列表查询 13 * @description:楼盘查询- 根据条件进行列表查询
12 * @param {*} data 14 * @param {*} data
13 * @author: renchao 15 * @author: renchao
14 */ 16 */
15 export function getLpZrz (data) { 17 export function getLpZrz(data) {
16 return request({ 18 return request({
17 url: 'service-lpb-zq/rest/zhcx/lpcx/getLpZrz', 19 url: "service-lpb-zq/rest/zhcx/lpcx/getLpZrz",
18 method: 'post', 20 method: "post",
19 data: data 21 data: data,
20 }) 22 });
21 } 23 }
22 24
23 /** 25 /**
...@@ -25,32 +27,47 @@ export function getLpZrz (data) { ...@@ -25,32 +27,47 @@ export function getLpZrz (data) {
25 * @param {*} zrzbsm 27 * @param {*} zrzbsm
26 * @author: renchao 28 * @author: renchao
27 */ 29 */
28 export function getLpb (zrzbsm) { 30 export function getLpb(zrzbsm) {
29 return request({ 31 return request({
30 url: 'service-lpb-zq/rest/zhcx/lpcx/getLpb?scyclx=1&zrzbsm=' + zrzbsm, 32 url: "service-lpb-zq/rest/zhcx/lpcx/getLpb?scyclx=0&zrzbsm=" + zrzbsm,
31 method: 'get' 33 method: "get",
32 }) 34 });
33 } 35 }
34 /** 36 /**
35 * @description: 获取楼盘表房屋用途,房屋性质右侧房屋用途统计数据 37 * @description: 获取楼盘表房屋用途,房屋性质右侧房屋用途统计数据
36 * @param {*} zrzbsm 38 * @param {*} zrzbsm
37 * @author: renchao 39 * @author: renchao
38 */ 40 */
39 export function getLpbFwytAndQlxz (zrzbsm) { 41 export function getLpbFwytAndQlxz(zrzbsm) {
40 return request({ 42 return request({
41 url: 'service-lpb-zq/rest/zhcx/lpcx/getLpbFwytAndQlxz?scyclx=1&zrzbsm=' + zrzbsm, 43 url:
42 method: 'get' 44 "service-lpb-zq/rest/zhcx/lpcx/getLpbFwytAndQlxz?scyclx=0&zrzbsm=" +
43 }) 45 zrzbsm,
46 method: "get",
47 });
44 } 48 }
45 /** 49 /**
46 * @description: 获取楼盘表缺失项统计 50 * @description: 获取楼盘表缺失项统计
47 * @param {*} zrzbsm 51 * @param {*} zrzbsm
48 * @author: renchao 52 * @author: renchao
49 */ 53 */
50 export function getLpbQsxtj (zrzbsm) { 54 export function getLpbQsxtj(zrzbsm) {
51 return request({ 55 return request({
52 url: url + 'getLpbQsxtj?scyclx=1&zrzbsm=' + zrzbsm, 56 url: "service-lpb-zq/rest/zhcx/lpcx/getLpbQsxtj?scyclx=0&zrzbsm=" + zrzbsm,
53 method: 'get' 57 method: "get",
54 }) 58 });
55 } 59 }
56 60
61 /**
62 * @description: 楼盘表 获取单元状态统计数据
63 * @param {*} data
64 * zrzbsm 自然幢标识码
65 * scyclx 实测预测类型 0预测,1实测
66 * @return {*}
67 */
68 export function getLpbTj(zrzbsm) {
69 return request({
70 url: "service-lpb-zq/rest/zhcx/lpcx/getLpbTj?scyclx=0&zrzbsm=" + zrzbsm,
71 method: "get",
72 });
73 }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
2 * @Author: yangwei 2 * @Author: yangwei
3 * @Date: 2023-02-28 15:47:12 3 * @Date: 2023-02-28 15:47:12
4 * @LastEditors: yangwei 4 * @LastEditors: yangwei
5 * @LastEditTime: 2023-03-02 16:35:36 5 * @LastEditTime: 2023-06-16 16:14:51
6 * @FilePath: \bdcdj-web\src\views\lpb\lpbContent\ch.vue 6 * @FilePath: \bdcdj-web\src\views\lpb\lpbContent\ch.vue
7 * @Description: 7 * @Description:
8 * 8 *
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
37 :data-qszt="hs.qszt" 37 :data-qszt="hs.qszt"
38 ref="hBsm" 38 ref="hBsm"
39 :key="hsIndex" 39 :key="hsIndex"
40 style="border-color: rgb(230, 230, 230)" 40 :style="{'border-color': borderColor}"
41 :class="hs.select ? 'tdSelect' : ''" 41 :class="hs.select ? 'tdSelect' : ''"
42 @click="handleClickH($event.target, hs.bsm, hs)" 42 @click="handleClickH($event.target, hs.bsm, hs)"
43 @dblclick="dbclick(hs.bsm)" 43 @dblclick="dbclick(hs.bsm)"
...@@ -82,7 +82,12 @@ ...@@ -82,7 +82,12 @@
82 <script> 82 <script>
83 export default { 83 export default {
84 name: "BdcdjWebCh", 84 name: "BdcdjWebCh",
85 inject: ["openMenu", "selectAll"], 85 inject: {
86 openMenu:{value:'openMenu',default:null},
87 selectAll:{value:'selectAll',default:null},
88 changeChoosedObj:{value:'changeChoosedObj',default:null},
89 clearChangeChoosedObj:{value:'clearChangeChoosedObj',default:null}
90 },
86 props: { 91 props: {
87 ch: { 92 ch: {
88 type: Array, 93 type: Array,
...@@ -101,6 +106,8 @@ export default { ...@@ -101,6 +106,8 @@ export default {
101 hqsztList: [], 106 hqsztList: [],
102 //区分单双击事件的定时器 107 //区分单双击事件的定时器
103 time: null, 108 time: null,
109 // 边框颜色
110 borderColor:'rgb(230, 230, 230)'
104 }; 111 };
105 }, 112 },
106 mounted() {}, 113 mounted() {},
...@@ -108,48 +115,32 @@ export default { ...@@ -108,48 +115,32 @@ export default {
108 // 层选中事件 115 // 层选中事件
109 handleClickC(e, item) { 116 handleClickC(e, item) {
110 //判断点击的层是否选中 117 //判断点击的层是否选中
111 if (e.target.className.indexOf("tdSelect") == -1) { 118 // if (e.target.className.indexOf("tdSelect") == -1) {
112 //未选中→选中 119 // //未选中→选中
113 e.target.className += " tdSelect"; //加边框 120 // e.target.className += " tdSelect"; //加边框
114 this.cbsmList.push(item.bsm); 121 // this.cbsmList.push(item.bsm);
115 } else { 122 // } else {
116 //选中→未选中 123 // //选中→未选中
117 e.target.className = "floor"; 124 // e.target.className = "floor";
118 this.cbsmList = this.cbsmList.filter((i) => i != item.bsm); 125 // this.cbsmList = this.cbsmList.filter((i) => i != item.bsm);
119 } 126 // }
120 // this.$parent.getCbsm(this.cbsmList); 127 // this.$parent.getCbsm(this.cbsmList);
121 }, 128 },
122 //户单击事件 129 //户单击事件
123 handleClickH(e, bsm, hs) { 130 handleClickH(e, bsm, hs) {
124 let self = this;
125 // 开启延时器,200ms的间隔区分单击和双击,解决双击时执行两次单击事件
126 clearTimeout(self.time);
127 self.time = setTimeout(() => {
128 // this.closeMenu();
129 //判断点击的户是否选中
130 if (!hs.select) {
131 //未选中→选中
132 hs.select = true; //加边框
133 this.hbsmList.push(bsm); // 将户bsm放进hbsmList
134 this.hqsztList.push(hs.qszt); // 将户qszt放进hqsztList
135 } else {
136 //选中→未选中
137 hs.select = false;
138 this.hbsmList = this.hbsmList.filter((i) => i != bsm);
139 this.hqsztList = this.hqsztList.filter((i) => i != hs.qszt);
140 }
141 }, 200);
142 }, 131 },
143 // 户单元状态点击事件 132 // 户单元状态点击事件
144 hDyztClick(e, bsm, hs) { 133 hDyztClick(e, bsm, hs) {
145 this.handleClickH(e.target.parentNode, bsm, hs); 134 // this.handleClickH(e.target.parentNode, bsm, hs);
146 }, 135 },
147 //户双击事件 136 //户双击事件
148 dbclick(bsm) { 137 dbclick(bsm) {
149 clearTimeout(this.time); 138 // clearTimeout(this.time);
150 }, 139 },
151 //幢单元全选/反选 140 //幢单元全选/反选
152 zdySelectAll(val) { 141 zdySelectAll(val,flag) {
142 // 手动点击全部取消选中
143 !flag && this.clearChangeChoosedObj()
153 this.ch.forEach((c) => { 144 this.ch.forEach((c) => {
154 c.hs.forEach((h) => { 145 c.hs.forEach((h) => {
155 if (val) { 146 if (val) {
...@@ -158,10 +149,16 @@ export default { ...@@ -158,10 +149,16 @@ export default {
158 this.hbsmList.push(h.bsm) 149 this.hbsmList.push(h.bsm)
159 } else { 150 } else {
160 h.select = false; 151 h.select = false;
152 this.borderColor = 'rgb(230, 230, 230)'
161 this.hbsmList = [] 153 this.hbsmList = []
162 } 154 }
163 }); 155 });
164 }); 156 });
157 this.$refs.hBsm && this.$refs.hBsm.forEach((item) => {
158 // item.style.borderColor = this.borderColor
159 item.style.backgroundColor = '#fff';
160 // item.style.border = `1px solid ${this.borderColor}`
161 });
165 }, 162 },
166 }, 163 },
167 watch: { 164 watch: {
...@@ -172,6 +169,34 @@ export default { ...@@ -172,6 +169,34 @@ export default {
172 immediate: true, 169 immediate: true,
173 deep: true, 170 deep: true,
174 }, 171 },
172 changeChoosedObj: {
173 handler(val) {
174 debugger
175 //清除选中户
176 this.borderColor = 'rgb(230, 230, 230)';
177 this.zdySelectAll(false,true)
178 if (val.bsms.length) {
179 this.$refs.hBsm.forEach((item) => {
180 val.bsms.forEach((i,ind) => {
181 if (item.dataset.bsm == i) {
182 if (ind == 0) {
183 //定位到第一个户所在位置
184 window.lpbContent.$refs.lpbContent.scrollTop = item.offsetTop;
185 window.lpbContent.$refs.lpbContent.scrollLeft = item.offsetLeft;
186 }
187 item.style.border = '1px solid '+ val.color;
188 // item.style.backgroundColor = val.color;
189 }
190 });
191 });
192 }else{
193 this.borderColor = 'rgb(230, 230, 230)'
194 }
195
196 },
197 immediate: true,
198 deep: true,
199 },
175 }, 200 },
176 }; 201 };
177 </script> 202 </script>
...@@ -181,16 +206,26 @@ export default { ...@@ -181,16 +206,26 @@ export default {
181 display: flex; 206 display: flex;
182 flex-direction: column-reverse; 207 flex-direction: column-reverse;
183 .chTable { 208 .chTable {
184 margin-left: -1px; 209 // margin-left: -1px;
185 border-color: #e4ebf4 !important; 210 border-color: #e4ebf4 !important;
186 border-collapse: collapse; 211 border-collapse: collapse;
187 border-spacing: 0; 212 border-spacing: 0;
188 // position: relative; 213 // position: relative;
189 tr { 214 tr {
215 .floor {
216 min-width: 56px;
217 background: #e8f2ff;
218 border: 1px solid #acbae8;
219 }
220 &:first-child {
221 .floor {
222 border-radius: 4px 0px 0px 1px;
223 }
224 }
190 td { 225 td {
191 min-width: 138px; 226 min-width: 138px;
192 height: 72px; 227 height: 64px;
193 line-height: 72px; 228 line-height: 64px;
194 text-align: center; 229 text-align: center;
195 cursor: pointer; 230 cursor: pointer;
196 position: relative; 231 position: relative;
...@@ -204,7 +239,7 @@ export default { ...@@ -204,7 +239,7 @@ export default {
204 left: 6px; 239 left: 6px;
205 top: 6px; 240 top: 6px;
206 border: 1px solid; 241 border: 1px solid;
207 border-radius: 8px; 242 border-radius: 3px 0px 3px 0px;
208 } 243 }
209 .lin { 244 .lin {
210 color: #f7b500; 245 color: #f7b500;
...@@ -223,7 +258,7 @@ export default { ...@@ -223,7 +258,7 @@ export default {
223 width: 138px; 258 width: 138px;
224 height: 18px; 259 height: 18px;
225 position: absolute; 260 position: absolute;
226 bottom: 32px; 261 bottom: 28px;
227 box-sizing: border-box; 262 box-sizing: border-box;
228 padding: 0 6px; 263 padding: 0 6px;
229 li { 264 li {
...@@ -239,7 +274,8 @@ export default { ...@@ -239,7 +274,8 @@ export default {
239 } 274 }
240 } 275 }
241 .tdSelect { 276 .tdSelect {
242 border: 1px solid #006cff !important; 277 border: 1px solid ;
278 border-color: #5A78DE !important;
243 background-image: url("./images/tdSelect.png"); 279 background-image: url("./images/tdSelect.png");
244 background-repeat: no-repeat; 280 background-repeat: no-repeat;
245 background-position: right top; 281 background-position: right top;
......
1 <template> 1 <template>
2 <div class="lpbContent-wrap" ref="lpbContentWrap"> 2 <div class="lpbContent-wrap" ref="lpbContentWrap">
3 <div class="lpbContent"> 3 <div class="lpbContent" ref="lpbContent">
4 <!-- 纵向倒序排列 逻辑幢位于独立幢单元和独立层户的上方 --> 4 <!-- 纵向倒序排列 逻辑幢位于独立幢单元和独立层户的上方 -->
5 <div class="ch-zdy-wrap"> 5 <div class="ch-zdy-wrap">
6 <!-- 幢单元 --> 6 <!-- 幢单元 -->
...@@ -13,9 +13,10 @@ ...@@ -13,9 +13,10 @@
13 </div> 13 </div>
14 <!-- 自然幢名称 --> 14 <!-- 自然幢名称 -->
15 <p class="lpb-xmmc"> 15 <p class="lpb-xmmc">
16 <el-checkbox @change="zdySelectAll($event)">{{ 16 <!-- <el-checkbox @change="zdySelectAll($event)">{{
17 lpbData.xmmc 17 lpbData.xmmc
18 }}</el-checkbox> 18 }}</el-checkbox> -->
19 {{lpbData.xmmc}}
19 </p> 20 </p>
20 <!-- 右键菜单 --> 21 <!-- 右键菜单 -->
21 <ul 22 <ul
...@@ -38,6 +39,8 @@ export default { ...@@ -38,6 +39,8 @@ export default {
38 return { 39 return {
39 openMenu: this.openMenu, 40 openMenu: this.openMenu,
40 selectAll: this.selectAllObj, 41 selectAll: this.selectAllObj,
42 changeChoosedObj:this.changeChoosedObj,
43 clearChangeChoosedObj:this.clearChangeChoosedObj
41 }; 44 };
42 }, 45 },
43 name: "", 46 name: "",
...@@ -72,20 +75,27 @@ export default { ...@@ -72,20 +75,27 @@ export default {
72 //右键菜单定位位置 75 //右键菜单定位位置
73 lpbChLeft: 100, 76 lpbChLeft: 100,
74 lpbChTop: 100, 77 lpbChTop: 100,
78 // 改变户选中状态
79 changeChoosedObj:{
80 bsms:[],
81 color:''
82 }
75 }; 83 };
76 }, 84 },
77 mounted() { 85 mounted() {
78 this.getLpb("dfc08a0cc6a25188990ea53d1d2c500e"); 86 this.getLpb(this.zrzbsm);
79 // setTimeout(() => { 87 window.lpbContent = this;
80 // //让滚动条滚动至最下面 -6是横向滚动条的高度
81 // this.$refs.lpbContent.scrollTop =
82 // this.$refs.lpbContent.scrollHeight -
83 // this.$refs.lpbContent.clientHeight -
84 // 6;
85 // }, 200);
86 // window.lpbContent = this;
87 }, 88 },
88 methods: { 89 methods: {
90 // 改变户选中状态
91 changeChoosed(bsms, color){
92 debugger
93 this.changeChoosedObj.bsms = bsms;
94 this.changeChoosedObj.color = color;
95 },
96 clearChangeChoosedObj(){
97 this.changeChoosedObj.bsms = [];
98 },
89 //全选户 99 //全选户
90 zdySelectAll(val) { 100 zdySelectAll(val) {
91 this.selectAllObj.selectAll = val; 101 this.selectAllObj.selectAll = val;
...@@ -113,7 +123,7 @@ export default { ...@@ -113,7 +123,7 @@ export default {
113 openMenu(e, item, type) { 123 openMenu(e, item, type) {
114 this.lpbChLeft = e.pageX - 96; 124 this.lpbChLeft = e.pageX - 96;
115 this.lpbChTop = e.pageY - 23; 125 this.lpbChTop = e.pageY - 23;
116 this.lpbChVisible = true; 126 // this.lpbChVisible = true;
117 }, 127 },
118 //关闭户右键菜单 128 //关闭户右键菜单
119 closeMenu() { 129 closeMenu() {
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
10 --> 10 -->
11 <template> 11 <template>
12 <div class="ljzs-wrap"> 12 <div class="ljzs-wrap">
13 <div v-for="ljzarr in ljzsCptd" :key="ljzarr[0].bsm"> 13 <div v-for="ljzarr in ljzsCptd" :style="{'margin-bottom': ljzarr.length == 1 ? '34px':'80px'}" :key="ljzarr[0].bsm">
14 <!-- 多个同起始层逻辑幢 横向排列 --> 14 <!-- 多个同起始层逻辑幢 横向排列 -->
15 <div class="ch-zdy-wrap" v-if="ljzarr.length > 1"> 15 <div class="ch-zdy-wrap" v-if="ljzarr.length > 1">
16 <div v-for="ljz in ljzarr" :key="ljz.ljzmc" class="same-floor-ljz"> 16 <div v-for="ljz in ljzarr" :key="ljz.ljzmc" class="same-floor-ljz">
...@@ -94,7 +94,7 @@ export default { ...@@ -94,7 +94,7 @@ export default {
94 display: flex; 94 display: flex;
95 flex-direction: column-reverse; 95 flex-direction: column-reverse;
96 > div { 96 > div {
97 margin-bottom: 80px; 97 // margin-bottom: 80px;
98 margin-right: 20px; 98 margin-right: 20px;
99 display: flex; 99 display: flex;
100 flex-direction: column; 100 flex-direction: column;
...@@ -110,8 +110,8 @@ export default { ...@@ -110,8 +110,8 @@ export default {
110 } 110 }
111 .ljz-xmmc { 111 .ljz-xmmc {
112 position: absolute; 112 position: absolute;
113 width: calc(100% + 1px); 113 width: calc(100% - 4px);
114 bottom: -60px; 114 bottom: -34px;
115 } 115 }
116 } 116 }
117 .cs-none { 117 .cs-none {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
2 * @Author: yangwei 2 * @Author: yangwei
3 * @Date: 2023-02-28 16:29:04 3 * @Date: 2023-02-28 16:29:04
4 * @LastEditors: yangwei 4 * @LastEditors: yangwei
5 * @LastEditTime: 2023-03-02 14:45:19 5 * @LastEditTime: 2023-06-08 13:58:58
6 * @FilePath: \bdcdj-web\src\views\lpb\lpbContent\zdys.vue 6 * @FilePath: \bdcdj-web\src\views\lpb\lpbContent\zdys.vue
7 * @Description: 7 * @Description:
8 * 8 *
...@@ -13,9 +13,10 @@ ...@@ -13,9 +13,10 @@
13 <div v-for="zdy in realZdys" :key="zdy.bsm"> 13 <div v-for="zdy in realZdys" :key="zdy.bsm">
14 <!-- 幢单元名称 --> 14 <!-- 幢单元名称 -->
15 <p class="lpb-xmmc"> 15 <p class="lpb-xmmc">
16 <el-checkbox @change="zdySelectAll($event,zdy.bsm)">{{ 16 <!-- <el-checkbox @change="zdySelectAll($event,zdy.bsm)">{{
17 zdy.zdymc 17 zdy.zdymc
18 }}</el-checkbox> 18 }}</el-checkbox> -->
19 {{zdy.zdymc}}
19 </p> 20 </p>
20 <!-- 每个幢单元下的层户 --> 21 <!-- 每个幢单元下的层户 -->
21 <ch-cpn :ref="zdy.bsm" :ch="zdy.cs" /> 22 <ch-cpn :ref="zdy.bsm" :ch="zdy.cs" />
......