浏览代码

Merge branch 'master' of http://114.244.114.158:8802/siwei/real3d-portalsite

maxiaoxiao 1 年之前
父节点
当前提交
19e68cf9a5

+ 16 - 0
src/api/ghss/ghxz.js

@@ -0,0 +1,16 @@
+import request from '@/utils/request.js'
+
+export function GetFxyzList(params) {
+    return request({
+        url: '/apply/fzxz/GetFxyzList',
+        method: 'get',
+        params
+    })
+}
+export function GetDldmTree(params) {
+    return request({
+        url: '/apply/fzxz/GetDldmTree',
+        method: 'get',
+        params
+    })
+}

+ 4 - 1
src/components/sceneAtttribute/camera/camera.vue

@@ -216,7 +216,7 @@ export default {
       flyCirclePoint: null,
       speed: 1,
       underground: false,
-      SurfaceTransparency: 1,
+      SurfaceTransparency: 0,
       cameraMinimumZoomDistance: -1000,
       isDestroyFlag: true,
 
@@ -763,12 +763,15 @@ export default {
     underground(val) {
       viewer.scene.undergroundMode = val;
       if (val) {
+        this.SurfaceTransparency = 0;
         viewer.scene.screenSpaceCameraController.minimumZoomDistance = Number(
           this.cameraMinimumZoomDistance
         );
       } else {
+        this.SurfaceTransparency = 1;
         viewer.scene.screenSpaceCameraController.minimumZoomDistance = 1;
       }
+      viewer.scene.globe.globeAlpha = parseFloat(this.SurfaceTransparency);
     },
     cameraMinimumZoomDistance(val) {
       viewer.scene.screenSpaceCameraController.minimumZoomDistance =

+ 37 - 3
src/store/store.js

@@ -58,9 +58,18 @@ var store2 = {
                 xdata: [],
                 result: [],
             },
-            jt_jg:{
-                "商服用地":{},
-                "工业用地":{},
+            gy_jd_info: {
+                info: {},
+                pieData: {}
+            },
+            jt_jg: {
+                "商服用地": {},
+                "工业用地": {},
+
+            },
+            jt_gy: {
+                jh: "",
+                wc: "",
 
             }
         },
@@ -81,6 +90,31 @@ var store2 = {
             id: 4602,
             name: '',
         },
+        cockpit_stxf: {
+            ssgc: {
+                list: {},
+                title: {},
+
+            }
+        },
+        cockpit_gdbh: {//耕地保护
+            gdxz: {//耕地现状
+                list: {
+                    yAxis:[],
+                    yData:[]
+
+                },
+                title: {},
+            },
+            zbph: {
+                bcgd: {},
+            }
+        },
+        cockpit_bjxm: {
+            csbj: {
+                csbj_echart: {}
+            }
+        },
         cockpit_gkzb: {
             // 生态保护红线面积
             mj: 0,

+ 106 - 67
src/views/cockpit/bjxm.vue

@@ -31,6 +31,7 @@
 
 <script>
 //这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
+import { QueryOne, QueryList } from "../../api/cockpitNew";
 
 export default {
   components: {},
@@ -43,6 +44,37 @@ export default {
   watch: {},
   //方法集合
   methods: {
+    async init_bjxm_echart_info(params) {
+      const that = this;
+      let obj = {
+        jscType: 'jsc_bjxm_csbj_yffl',
+        beginTime: params ? params.beginTime : store.state.cockpit_date[0],
+        endTime: params ? params.endTime : store.state.cockpit_date[1],
+        id: params ? params.id : '4602'
+      };
+      let data = await QueryList(obj);
+      console.log('data: ', data);
+      let xAxis = [];
+      let bat_data = [];
+      let line_data = [];
+
+      data.data.forEach(element => {
+
+        xAxis.push(element.yf);
+        bat_data.push(element.sj_mj);
+        line_data.push(element.sj_number);
+
+
+      });
+      store.state.cockpit_bjxm.csbj.csbj_echart = {
+        xAxis: xAxis,
+        bat_data: bat_data,
+        line_data: line_data,
+
+      }
+      this.init_bjxm_echart();
+
+    },
     init_bjxm_echart() {
       var myChart = echarts.init(document.getElementById("bjxm_echart"));
       // 柱状图的宽度,y是x的一半
@@ -98,11 +130,16 @@ export default {
       echarts.graphic.registerShape('CubeRight', CubeRight)
       echarts.graphic.registerShape('CubeTop', CubeTop)
       // 数据
-      const VALUE = [210.9, 260.8, 204.2, 504.9, 740.5]
+      const xAxis = store.state.cockpit_bjxm.csbj.csbj_echart.xAxis
+      const bat_data = store.state.cockpit_bjxm.csbj.csbj_echart.bat_data
+      const line_data = store.state.cockpit_bjxm.csbj.csbj_echart.line_data
+
       let option = {
         //你的代码
         backgroundColor: 'rgba(17, 42, 62, 0)',//"#012366",
         tooltip: {
+          show: false,
+
           trigger: 'axis',
           axisPointer: {
             type: 'shadow'
@@ -121,7 +158,7 @@ export default {
         },
         xAxis: {
           type: 'category',
-          data: ['崖州区', '天崖区', '吉阳区', '海棠区', '育才区'],
+          data: xAxis,
           axisLine: {
             lineStyle: {
               color: '#BCD3E5'
@@ -144,8 +181,8 @@ export default {
         yAxis: [
           {
             min: 0,
-            max: 1200,
-            interval: 200,
+            max: 20,
+            interval: 5,
             type: 'value',
             name: '用地面积(km2)',
             axisLine: {
@@ -173,8 +210,8 @@ export default {
           },
           {
             min: 0,
-            max: 1200,
-            interval: 200,
+            max: 20,
+            interval: 5,
             name: '项目数(个)',
             type: 'value',
             axisLine: {
@@ -220,78 +257,78 @@ export default {
                 type: 'group',
                 children: [
                   {
-                  type: 'CubeLeft',
-                  shape: {
-                    api,
-                    xValue: api.value(0),
-                    yValue: api.value(1),
-                    x: location[0],
-                    y: location[1],
-                    xAxisPoint: api.coord([api.value(0), 0])
-                  },
-                  style: {
-                    fill: color = api.value(1) > 10000 ? 'red' : new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
-                      offset: 0,
-                      color: 'rgba(34, 129, 209, 0.8)'
+                    type: 'CubeLeft',
+                    shape: {
+                      api,
+                      xValue: api.value(0),
+                      yValue: api.value(1),
+                      x: location[0],
+                      y: location[1],
+                      xAxisPoint: api.coord([api.value(0), 0])
                     },
-                    {
-                      offset: 0.8,
-                      color: 'rgba(34, 129, 209, 0.8)'
+                    style: {
+                      fill: color = api.value(1) > 10000 ? 'red' : new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
+                        offset: 0,
+                        color: 'rgba(34, 129, 209, 0.8)'
+                      },
+                      {
+                        offset: 0.8,
+                        color: 'rgba(34, 129, 209, 0.8)'
 
 
+                      }
+                      ])
                     }
-                    ])
-                  }
-                },
-                {
-                  type: 'CubeRight',
-                  shape: {
-                    api,
-                    xValue: api.value(0),
-                    yValue: api.value(1),
-                    x: location[0],
-                    y: location[1],
-                    xAxisPoint: api.coord([api.value(0), 0])
                   },
-                  style: {
-                    fill: color = api.value(1) > 10000 ? 'red' : new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
-                      offset: 0,
-                      color: 'rgba(97, 173, 237, 0.8)'
+                  {
+                    type: 'CubeRight',
+                    shape: {
+                      api,
+                      xValue: api.value(0),
+                      yValue: api.value(1),
+                      x: location[0],
+                      y: location[1],
+                      xAxisPoint: api.coord([api.value(0), 0])
                     },
-                    {
-                      offset: 0.8,
-                      color: 'rgba(97, 173, 237, 0.8)'
+                    style: {
+                      fill: color = api.value(1) > 10000 ? 'red' : new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
+                        offset: 0,
+                        color: 'rgba(97, 173, 237, 0.8)'
+                      },
+                      {
+                        offset: 0.8,
+                        color: 'rgba(97, 173, 237, 0.8)'
+                      }
+                      ])
                     }
-                    ])
-                  }
-                }, {
-                  type: 'CubeTop',
-                  shape: {
-                    api,
-                    xValue: api.value(0),
-                    yValue: api.value(1),
-                    x: location[0],
-                    y: location[1],
-                    xAxisPoint: api.coord([api.value(0), 0])
-                  },
-                  style: {
-                    fill: color = api.value(1) > 10000 ? 'red' : new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
-                      offset: 0,
-                      color: 'rgba(60, 167, 255, 1)'
-
+                  }, {
+                    type: 'CubeTop',
+                    shape: {
+                      api,
+                      xValue: api.value(0),
+                      yValue: api.value(1),
+                      x: location[0],
+                      y: location[1],
+                      xAxisPoint: api.coord([api.value(0), 0])
                     },
-                    {
-                      offset: 1,
-                      color: 'rgba(135, 200, 255, 1)'
+                    style: {
+                      fill: color = api.value(1) > 10000 ? 'red' : new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
+                        offset: 0,
+                        color: 'rgba(60, 167, 255, 1)'
+
+                      },
+                      {
+                        offset: 1,
+                        color: 'rgba(135, 200, 255, 1)'
 
+                      }
+                      ])
                     }
-                    ])
-                  }
-                }]
+                  }]
               }
             },
 
-            data: VALUE
+            data: bat_data
           },
           {
             type: 'line',
@@ -301,7 +338,7 @@ export default {
                 color: '#FFCC64'  // 折线的颜色
               }
             },
-            data: VALUE,
+            data: line_data,
           },
         ]
       };
@@ -312,7 +349,9 @@ export default {
   created() { }, //生命周期 - 创建完成(可以访问当前this实例)
   beforeMount() { }, //生命周期 - 挂载之前
   mounted() {
-    this.init_bjxm_echart();
+    this.$nextTick((res) => {
+      this.init_bjxm_echart_info();
+    })
   }, //生命周期 - 挂在完成
   beforeUpdate() { }, //生命周期 - 更新之前
   updated() { }, //生命周期 - 更新之后

+ 123 - 15
src/views/cockpit/gdbh.vue

@@ -9,7 +9,7 @@
       </div>
     </div>
     <div class="content_index">
-      <div v-show="tab == options[2].value">
+      <!-- <div v-show="tab == options[2].value">
         <pie3d id="gdbh_echart_gdlr" :legendFlag=false unit="" ref="gdbh_echart_gdlr"></pie3d>
         <pie3d id="gdbh_echart_gdlc" :legendFlag=false unit="" ref="gdbh_echart_gdlc"></pie3d>
         <div class="legend_gdlx">
@@ -20,7 +20,7 @@
 
           </div>
         </div>
-      </div>
+      </div> -->
 
       <div v-show="tab == options[1].value">
         <div class="content">
@@ -44,7 +44,7 @@
             </div>
             <div class="text_back">
               <p>补充耕地</p>
-              <span>673.56</span>公顷
+              <span>{{ store.state.cockpit_gdbh.zbph.bcgd.jszgm }}</span>公顷
 
             </div>
           </div>
@@ -60,7 +60,7 @@
                 <br>
 
                 <span class="zbph_value_unit">
-                  <span class="zbph_value">934.23</span>
+                  <span class="zbph_value">0</span>
                   <span class="zbph_unit">公顷</span>
                 </span>
               </li>
@@ -72,7 +72,7 @@
                 <br>
 
                 <span class="zbph_value_unit">
-                  <span class="zbph_value">934.23</span>
+                  <span class="zbph_value">0</span>
                   <span class="zbph_unit">吨</span>
                 </span>
               </li>
@@ -88,7 +88,7 @@
                 <br>
 
                 <span class="zbph_value_unit">
-                  <span class="zbph_value">934.23</span>
+                  <span class="zbph_value">{{ store.state.cockpit_gdbh.zbph.bcgd.xzstmj }}</span>
                   <span class="zbph_unit">公顷</span>
                 </span>
               </li>
@@ -100,7 +100,7 @@
                 <br>
 
                 <span class="zbph_value_unit">
-                  <span class="zbph_value">934.23</span>
+                  <span class="zbph_value">{{ store.state.cockpit_gdbh.zbph.bcgd.jszgm }}</span>
                   <span class="zbph_unit">吨</span>
                 </span>
               </li>
@@ -120,7 +120,7 @@
             </div>
             <div class="text">
               <p>水田</p>
-              <span>673.56</span>公顷
+              <span>{{ store.state.cockpit_gdbh.gdxz.title.st_mj }}</span>公顷
 
             </div>
           </div>
@@ -132,7 +132,7 @@
             </div>
             <div class="text">
               <p>水浇地</p>
-              <span>673.56</span>公顷
+              <span>{{ store.state.cockpit_gdbh.gdxz.title.sjd_mj }}</span>公顷
 
             </div>
           </div>
@@ -144,7 +144,7 @@
             </div>
             <div class="text">
               <p>旱地</p>
-              <span>673.56</span>公顷
+              <span>{{ store.state.cockpit_gdbh.gdxz.title.hd_mj }}</span>公顷
 
             </div>
           </div>
@@ -174,7 +174,7 @@ export default {
       options: [
         { value: "gdxz", label: "耕地现状" },
         { value: "zbph", label: "占补平衡" },
-        { value: "gdlx", label: "耕地流向" },
+        // { value: "gdlx", label: "耕地流向" },
 
       ],
     };
@@ -186,6 +186,111 @@ export default {
   //方法集合
 
   methods: {
+    async init_info(params) {
+      const that = this;
+      let obj = {
+        jscType: 'sc_gdbh_xz_dlbm',
+        id: params ? params.id : '4602'
+      };
+      let data = await QueryOne(obj);
+      store.state.cockpit_gdbh.gdxz.title = data.data
+
+      let obj_list = {
+        jscType: 'sc_gdbh_xz_gddb',
+        id: params ? params.id : '4602'
+      };
+      let data_list = await QueryList(obj_list);
+      let yAxis = ['优等地', '高等地', '中等地', '低等地'];
+      let yData = [];
+
+      let echartData = [];
+      data_list.data.forEach((res) => {
+        if (res.dj == 1) {
+          echartData.push(
+            {
+              "优等地": res.tbmj,
+            }
+          )
+        }
+        if (res.dj == 2) {
+          echartData.push(
+            {
+              "高等地": res.tbmj,
+            }
+          )
+        } if (res.dj == 3) {
+          echartData.push(
+            {
+              "中等地": res.tbmj,
+            }
+          )
+        } if (res.dj == 4) {
+          echartData.push(
+            {
+              "低等地": res.tbmj,
+            }
+          )
+        }
+      })
+      if (data_list.data.length == 3) {
+        echartData.push({
+          "低等地": 0
+        });
+      }
+      if (data_list.data.length == 2) {
+        echartData.push({
+          "中等地": 0
+        });
+        echartData.push({
+          "低等地": 0
+        });
+      }
+      if (data_list.data.length == 1) {
+        echartData.push({
+          "高等地": 0
+        });
+        echartData.push({
+          "中等地": 0
+        });
+        echartData.push({
+          "低等地": 0
+        });
+      }
+      if (data_list.data.length == 0) {
+        echartData.push({
+          "优等地": 0
+        });
+        echartData.push({
+          "高等地": 0
+        });
+        echartData.push({
+          "中等地": 0
+        });
+        echartData.push({
+          "低等地": 0
+        });
+      }
+       yData = echartData.map((res) => {
+        for (let key in res) {
+          return res[key]
+        }
+      })
+      yAxis.reverse();
+      yData.reverse();
+
+      store.state.cockpit_gdbh.gdxz.list.yAxis = yAxis;
+      store.state.cockpit_gdbh.gdxz.list.yData = yData;
+
+      this.init_gdxz_echart();
+    }, async init_zbph(params) {
+      const that = this;
+      let obj = {
+        jscType: 'jsc_gdbh_zbph_gdbc',
+        id: params ? params.id : '4602'
+      };
+      let data = await QueryOne(obj);
+      store.state.cockpit_gdbh.zbph.bcgd = data.data
+    },
     setData(datas) {
       this.GetQueryOne_nt(datas);
       this.GetQueryOne_bh(datas);
@@ -315,7 +420,7 @@ export default {
           interval: 0
         },
         yAxis: {
-          data: ['优等地', '高等地', '中等地', '低等地'],
+          data: store.state.cockpit_gdbh.gdxz.list.yAxis,
 
           splitLine: {
             show: false,
@@ -381,7 +486,7 @@ export default {
               }
             },
             symbolPosition: 'end',
-            data: [22.23, 23.57, 18.14, 14.75],
+            data: store.state.cockpit_gdbh.gdxz.list.yData,
 
           }, {
             name: '一行动一活动开展情况',
@@ -397,7 +502,6 @@ export default {
                 }
               }
             },
-            data: [22, 23, 18, 14],
 
           }, {
             type: 'bar',
@@ -424,7 +528,7 @@ export default {
             silent: true,
             barWidth: 15,
             barCategoryGap: '100%',
-            data: [22.23, 23.57, 18.14, 14.75],
+            data: store.state.cockpit_gdbh.gdxz.list.yData,
 
           }]
       };
@@ -444,7 +548,11 @@ export default {
     // });
 
     this.$nextTick((res) => {
+      this.init_info();
       this.init_gdxz_echart();
+      this.init_zbph();
+
+
     })
   },
 };

+ 30 - 11
src/views/cockpit/stxf.vue

@@ -31,18 +31,18 @@
     <div v-show="tab == options[1].value">
       <div class="content">
 
-        <div class="infoLIst" v-if="jiDataInfo.length">
-          <div class="infoItem" v-for="(item, index) in jiDataInfo" :key="index">
+        <div class="infoLIst" v-if="store.state.cockpit_stxf.ssgc.list.length">
+          <div class="infoItem" v-for="(item, index) in store.state.cockpit_stxf.ssgc.list" :key="index">
             <div class="itemIcon">
               <span>
-                {{ index }}
+                {{ index + 1 }}
               </span>
             </div>
             <div class="itemCon">
               <p>{{ item.xmmc }}</p>
               <p>
-                <span>{{ item.yelx }}</span>
-                <span>{{ item.crnj }}公顷</span>
+                <span><span class="font_color">治理面积</span>{{ item.zlmj }}公顷</span>
+                <span><span class="font_color">投资金额</span>{{ item.tzje }}万元</span>
               </p>
             </div>
           </div>
@@ -104,13 +104,28 @@ export default {
   //监控data中的数据变化
   watch: {},
   methods: {
-    async getInfo() {
+    async getInfo(params) {
       let res = await QueryList({
-        val0: '区',
-        jscType: "jsc_tdgy_jt_xx",
-        id: 4602,
+        jscType: "jsc_stxf_ywlx_ssxfmx",
+        id: params ? params.id : '4602'
+
+      });
+      store.state.cockpit_stxf.ssgc.list = res.data
+
+
+      let res_title = await QueryOne({
+        jscType: "jsc_stxf_ztgh_ssxf",
+        id: params ? params.id : '4602'
+
       });
-      this.jiDataInfo = res.data
+      store.state.cockpit_stxf.ssgc.title = res_title.data
+
+      this.sdata.ssxf = {
+        xzqhdm_number: store.state.cockpit_stxf.ssgc.title.xzqhdm_number,
+        zlmj: store.state.cockpit_stxf.ssgc.title.zlmj,
+        tzje: store.state.cockpit_stxf.ssgc.title.tzje,
+
+      }
     },
     changeCharts(e) {
 
@@ -281,7 +296,7 @@ export default {
       }
 
       p:first-child {
-        width: 177px;
+        width: 90%;
         overflow: hidden;
         white-space: nowrap;
         text-overflow: ellipsis;
@@ -297,6 +312,10 @@ export default {
           color: #64daff;
           font-size: 12px;
         }
+
+        .font_color {
+          color: white;
+        }
       }
     }
 

+ 8 - 6
src/views/cockpit/tdsc.vue

@@ -33,13 +33,13 @@
 
 
           </div>
-          <div class="rt_box box">
+          <div class="rt_box_tdsc_jd box">
             <div class="text">
               <p>完成收储</p>
               <span>{{ store.state.cockpit_tdsc.scjd.sj_mj }}</span>公顷
             </div>
           </div>
-          <div class="rb_box box">
+          <div class="rb_box_tdsc_jd box">
             <div class="text">
               <p>完成收储</p>
               <span>{{ store.state.cockpit_tdsc.scjd.sj_number }}</span>个
@@ -602,14 +602,15 @@ export default {
 
   }
 
-  .rt_box {
+  .rt_box_tdsc_jd {
     background: no-repeat;
     background-size: 101% 50%;
 
     background-image: url("/static/images/overview/rtback.png");
     position: absolute;
     top: 3rem;
-    right: 0rem;
+    left: 16rem;
+
     z-index: -1;
 
     .text {
@@ -617,13 +618,14 @@ export default {
     }
   }
 
-  .rb_box {
+  .rb_box_tdsc_jd {
     background: no-repeat;
     background-size: 101% 50%;
     background-image: url("/static/images/overview/rbback.png");
     position: absolute;
     top: 8rem;
-    right: 0rem;
+    left: 16rem;
+
     z-index: 100;
 
     .text {

+ 50 - 21
src/views/cockpit/tdsy.vue

@@ -28,7 +28,7 @@
             </div>
             <div class="text">
               计划已入市面积
-              <span>213.44</span>公顷
+              <span>{{ store.state.cockpit_tdgy.jt_gy.jh }}</span>公顷
 
             </div>
           </div>
@@ -38,7 +38,7 @@
             </div>
             <div class="text">
               已入市面积
-              <span>213.44</span>公顷
+              <span>{{store.state.cockpit_tdgy.jt_gy.wc}}</span>公顷
 
             </div>
           </div>
@@ -69,29 +69,29 @@
             <div class="lt_box box">
               <div class="text">
                 <p>计划供应</p>
-                <span>66.23</span>公顷
+                <span>{{ store.state.cockpit_tdgy.gy_jd_info.info.jh_crmj }}</span>公顷
               </div>
             </div>
             <div class="lb_box box">
               <div class="text">
                 <p>完成供应</p>
-                <span>66.23</span>公顷
+                <span>{{ store.state.cockpit_tdgy.gy_jd_info.info.sj_cr_crmj }}</span>公顷
               </div>
             </div>
             <div id="dial_watch_gy_jd">
 
 
             </div>
-            <div class="rt_box box">
+            <div class="rt_box_gy_jd box">
               <div class="text">
                 <p>计划供应项目</p>
-                <span>66.23</span>个
+                <span>{{ store.state.cockpit_tdgy.gy_jd_info.info.jh_xzqhdm_number }}</span>个
               </div>
             </div>
-            <div class="rb_box box">
+            <div class="rb_box_gy_jd box">
               <div class="text">
                 <p>完成供应项目</p>
-                <span>66.23</span>个
+                <span>{{ store.state.cockpit_tdgy.gy_jd_info.info.sj_xzqhdm_number }}</span>个
               </div>
             </div>
           </div>
@@ -172,6 +172,28 @@ export default {
   created() { }, //生命周期 - 创建完成(可以访问当前this实例)
   beforeMount() { }, //生命周期 - 挂载之前
   methods: {
+    async init_tdgy_gy_jg(params) {
+      const that = this;
+      let obj = {
+        jscType: 'jsc_tdgy_gy_ztsh',
+        id: params ? params.id : '4602'
+      };
+      let data = await QueryList(obj);
+      console.log('data: ', data);
+      store.state.cockpit_tdgy.gy_jd_info.info = data.data[0]
+      store.state.cockpit_tdgy.gy_jd_info.pieData = {
+        wgy: data.data[0].ce_crmj,
+        yhb: data.data[0].sj_hb_crmj,
+        ycr: data.data[0].sj_cr_crmj,
+
+      }
+
+      this.$refs.tdgy_echart_gyjd.setOptions([
+        { name: "未供应", value: store.state.cockpit_tdgy.gy_jd_info.pieData.wgy },
+        { name: "以划拨", value: store.state.cockpit_tdgy.gy_jd_info.pieData.yhb },
+        { name: "已出让", value: store.state.cockpit_tdgy.gy_jd_info.pieData.ycr },
+      ]);
+    },
     async init_tdgy_jt_jg(params) {
       const that = this;
       let obj = {
@@ -782,23 +804,29 @@ export default {
       that.init_gy_jg_echart();
 
     },
-
+    async init_tdgy_jt_jd(params) {
+      const that = this;
+      let obj = {
+        jscType: 'jsc_tdgy_jt_ztsh',
+        id: params ? params.id : '4602'
+      };
+      let data = await QueryOne(obj);
+      store.state.cockpit_tdgy.jt_gy.jh = data.data.jh_crmj
+      store.state.cockpit_tdgy.jt_gy.wc = data.data.sj_crmj
+    }
   },
   mounted() {
     const that = this;
     this.$nextTick(() => {
 
       this.init_tdgy_jt_jg();
-
+      this.init_tdgy_gy_jg();
       this.init_tdgy_gy_jd();
       that.init_echart();
       that.init_dial_watch_scjg();
       that.getInfo();
-      this.$refs.tdgy_echart_gyjd.setOptions([
-        { name: "未供应", value: 12 },
-        { name: "以划拨", value: 21 },
-        { name: "已出让", value: 24 },
-      ]);
+      that.init_tdgy_jt_jd();
+
       //  store.start.cockpit_tdgy.jt_jg
       // this.$refs.tdgy_echart_sfyd.setOptions([
       //   { name: "未供应", value: 12.86 },
@@ -1118,14 +1146,15 @@ export default {
 
   }
 
-  .rt_box {
+  .rt_box_gy_jd {
     background: no-repeat;
     background-size: 101% 50%;
 
     background-image: url("/static/images/overview/rtback.png");
     position: absolute;
     top: 3rem;
-    right: 2rem;
+    right: 4rem;
+    left: 16rem;
     z-index: -1;
 
     .text {
@@ -1133,13 +1162,13 @@ export default {
     }
   }
 
-  .rb_box {
+  .rb_box_gy_jd {
     background: no-repeat;
     background-size: 101% 50%;
     background-image: url("/static/images/overview/rbback.png");
     position: absolute;
     top: 8rem;
-    right: 2rem;
+    left: 16rem;
     z-index: 100;
 
     .text {
@@ -1175,10 +1204,10 @@ export default {
 #tdgy_echart_gyjd {
 
   width: 20rem;
-  height: 10rem;
+  height: 8rem;
   margin-bottom: 0rem;
   position: fixed;
-  top: 47rem;
+  top: 50rem;
   left: 2rem;
 }
 

+ 1 - 1
src/views/cockpit/wpjg.vue

@@ -21,7 +21,7 @@
         <span class="dvalue">{{ sdata.jcmj || 0 }}%</span>
       </div>
     </div>
-    <div id="wpjg_echart" v-show="false"></div>
+    <div id="wpjg_echart"></div>
 
     <div id="wpjg_echart_xzqh">
 

+ 49 - 13
src/views/siteselection/components/fzxz.vue

@@ -54,11 +54,19 @@
         </el-select>
       </el-form-item>
       <el-form-item label="用地类型:" prop="ydlx">
-        <el-input
+        <!-- <el-input
           v-model="ruleForm.ydlx"
           size="mini"
           placeholder="请输入用地类型"
-        ></el-input>
+        ></el-input> -->
+
+        <el-cascader
+          v-model="ruleForm.ydlx"
+          :options="cascaderOptions"
+          :props="{ expandTrigger: 'hover' }"
+          @change="handleChange"
+          size="mini"
+        ></el-cascader>
       </el-form-item>
       <el-form-item label="用地面积" required>
         <el-col :span="11">
@@ -99,14 +107,14 @@
       <span class="clearBtn" @click="reset">取消</span>
       <span class="sureBtn" @click="submitData">确定</span>
     </div>
-    <yxyzPop :dialogVisible="dialogVisible" :tableData="tableData"></yxyzPop>
+    <yxyzPop :tableData="tableData" ref="yxyzPop"></yxyzPop>
   </div>
 </template>
 
 <script>
 import yxyzPop from "./yxyzPop.vue"; ///mapview/range
 import range from "@/components/mapview/range.vue"; ///mapview/range
-
+import { GetDldmTree } from "../../../api/ghss/ghxz.js";
 export default {
   components: {
     yxyzPop,
@@ -402,24 +410,51 @@ export default {
           spatial_type: "identity",
         },
       ],
+      cascaderOptions: [], //用地性质数据存储数组
     };
   },
   computed: {},
-  mounted() {},
+  mounted() {
+    GetDldmTree({
+      fzbs: "3DDLDM",
+    }).then((res) => {
+      //顶级树只有一个
+      let childArr = res.data;
+      childArr.forEach((item) => {
+        let child = item.children;
+        if (item.children.length < 1) {
+          item.children = undefined;
+        } else {
+          for (var i = 0; i < child.length; i++) {
+            if (child[i].children.length < 1) {
+              //判断children的数组长度
+              child[i].children = undefined;
+            }
+          }
+        }
+      });
+
+      this.cascaderOptions = childArr; //为Cascader的options值
+
+    });
+  },
   methods: {
+    handleChange(value) {
+      console.log(value);
+    },
     submitData() {
       this.$refs.ruleForm.validate((valid) => {
         if (valid) {
           // this.activeTabs = 'lsju'
           // this.$emit('updateParent','activeTabs','lsju')
           this.$emit("updateParent", "loading", true);
-            setTimeout(() => {
-              let bsm = "8979e8f6a9364828a9d6b2e459c8fd76";
-              this.$emit("updateParent", "nowObj", this.ruleForm);
-              this.$emit("updateParent", "rzBsm", bsm);
-              this.$emit("updateParent", "loading", false);
-              this.reset();
-            }, 500);
+          setTimeout(() => {
+            let bsm = "8979e8f6a9364828a9d6b2e459c8fd76";
+            this.$emit("updateParent", "nowObj", this.ruleForm);
+            this.$emit("updateParent", "rzBsm", bsm);
+            this.$emit("updateParent", "loading", false);
+            this.reset();
+          }, 500);
         } else {
           console.log("error submit!!");
           return false;
@@ -462,7 +497,8 @@ export default {
       }
     },
     yzpz() {
-      this.dialogVisible = true;
+      // this.dialogVisible = true;
+      this.$refs.yxyzPop.dialogVisible = true;
     },
   },
 };

+ 104 - 45
src/views/siteselection/components/yxyzPop.vue

@@ -14,6 +14,7 @@
           <el-scrollbar class="left-tree">
             <el-tree
               :data="options"
+              :props="defaultProps"
               highlight-current
               show-checkbox
               node-key="value"
@@ -52,9 +53,24 @@
                   v-model="scope.row.condition"
                   placeholder="请选择"
                   class="input-style"
+                  v-if="scope.row.condition == 'identity'"
                 >
                   <el-option
-                    v-for="item in conditionList"
+                    v-for="item in conditionList1"
+                    :key="item.value"
+                    :label="item.label"
+                    :value="item.value"
+                  >
+                  </el-option>
+                </el-select>
+                <el-select
+                  v-model="scope.row.condition"
+                  placeholder="请选择"
+                  class="input-style"
+                  v-if="scope.row.condition == 'contain'"
+                >
+                  <el-option
+                    v-for="item in conditionList2"
                     :key="item.value"
                     :label="item.label"
                     :value="item.value"
@@ -88,12 +104,10 @@
 </template>
 
 <script>
+import { GetFxyzList } from "../../../api/ghss/ghxz.js";
 export default {
   components: {},
   props: {
-    dialogVisible: {
-      type: Boolean,
-    },
     tableData: {
       type: Array,
     },
@@ -101,25 +115,30 @@ export default {
 
   data() {
     return {
+      defaultProps: {
+        children: "children",
+        label: "yxyzmc",
+      },
+      dialogVisible: false,
       options: [
-        {
-          value: "控制线",
-          label: "规划控制线",
-          disabled: false,
-          children: [],
-        },
-        {
-          value: "专项规划",
-          label: "专项规划",
-          disabled: false,
-          children: [],
-        },
-        {
-          value: "基础设施",
-          label: "兴趣点",
-          disabled: false,
-          children: [],
-        },
+        // {
+        //   value: "控制线",
+        //   label: "规划控制线",
+        //   disabled: false,
+        //   children: [],
+        // },
+        // {
+        //   value: "专项规划",
+        //   label: "专项规划",
+        //   disabled: false,
+        //   children: [],
+        // },
+        // {
+        //   value: "基础设施",
+        //   label: "兴趣点",
+        //   disabled: false,
+        //   children: [],
+        // },
       ],
       kxyzList: [
         {
@@ -539,22 +558,61 @@ export default {
       optionsTemp: [],
       selectdialogData: [],
       dialogData: [],
-      conditionList: [
-        { label: "范围内", value: "C" },
-        { label: "范围外", value: "N" },
-        { label: "距离包含", value: "A" },
-        { label: "距离不包含", value: "B" },
-        { label: "分析", value: "F" },
+      conditionList1: [
+        { label: "范围内", value: "identity" },
+        { label: "范围外", value: "n_identity" },
+      ],
+      conditionList2: [
+        { label: "距离包含", value: "contain" },
+        { label: "距离不包含", value: "n_contain" },
       ],
     };
   },
+  computed: {
+    conditionList(val) {
+      if (val == "identity") {
+        return this.conditionList1;
+      } else {
+        return this.conditionList2;
+      }
+    },
+  },
   mounted() {
-    this.getList();
+    // this.getList();
+    this.GetFxyzList();
+    this.getTreeList();
   },
   methods: {
     close() {
-      this.$parent.dialogVisible = false;
+      this.dialogVisible = false;
+    },
+    GetFxyzList() {
+      GetFxyzList().then((res) => {
+        this.kxyzList = res.data;
+      });
+    },
+
+    getTreeList() {
+      function arrayToTreeLoop(nodes) {
+        const map = {};
+        const tree = [];
+        for (const node of nodes) {
+          map[node.bsm] = { ...node, children: [] };
+        }
+        for (const node of Object.values(map)) {
+          if (node.parent_bsm === null) {
+            tree.push(node);
+          } else {
+            map[node.parent_bsm].children.push(node);
+          }
+        }
+        return tree;
+      }
+
+      this.options = arrayToTreeLoop(this.kxyzList);
+      this.optionsTemp = JSON.parse(JSON.stringify(this.options));
     },
+
     getList() {
       // yzlist().then((res) => {
       //   if (res.success) {
@@ -578,16 +636,21 @@ export default {
       let tableList = [];
       selectdata.forEach((item) => {
         tableList.push({
-          name: item.label,
-          condition: item.yztj,
-          id: item.value,
-          type: item.type,
+          // name: item.label,
+          // condition: item.yztj,
+          // id: item.value,
+          // type: item.type,
+          // value: "",
+          // sjy: item.sjy,
+          // sjlx: item.sjlx,
+          id: item.bsm,
+          name: item.yxyzmc,
+          condition: item.spatial_type,
           value: "",
-          sjy: item.sjy,
-          sjlx: item.sjlx,
+          sjy: item.has_yxz,
+          sjlx: item.spatial_type,
         });
       });
-      console.log(this.options);
       tableList.forEach((item) => {
         this.resetTree(this.options, item);
       });
@@ -595,12 +658,11 @@ export default {
       return tableList;
     },
     resetTree(data, item1) {
-      console.log(data, item1);
       data.forEach((item, index) => {
-        if (item.value == item1.id) {
+        if (item.bsm == item1.id) {
           data.splice(index, 1);
         }
-        if (item.children != undefined) {
+        if (item.children != undefined && item.children.length != 0) {
           this.resetTree(item.children, item1);
         }
       });
@@ -626,12 +688,10 @@ export default {
       }
 
       let list = this.$refs.tree.getCheckedNodes().filter((item) => {
-        return item.children == undefined;
+        return item.children == undefined || item.children.length == 0;
       });
-      console.log(list);
       list = this.setTable(list);
       this.dialogData = [...this.dialogData, ...list];
-      console.log(this.dialogData, "this.dialogData");
     },
     turnRightToLeft() {
       if (this.selectdialogData.length == 0) {
@@ -655,7 +715,6 @@ export default {
       this.selectdialogData = val;
     },
     submit() {
-      console.log(this.dialogData);
       var sign = true;
       this.dialogData.forEach((item) => {
         item.type && item.value == "" && (sign = false);
@@ -664,7 +723,7 @@ export default {
         // parent.emit("update:tableData", this.dialogData);
         // parent.emit("update:dialogVisible", false);
         this.$parent.tableData = this.dialogData;
-        this.$parent.dialogVisible = false;
+        this.dialogVisible = false;
       } else {
         this.$message.warning("请将信息补充完整!");
       }

+ 20 - 1
src/views/viewer.vue

@@ -13,7 +13,7 @@
             <!-- <ser-center></ser-center> -->
             <JSYD ref="gkzb_ref" />
             <JCBD />
-            <BJXM />
+            <BJXM ref="bjxm_ref" />
             <TDSC ref="tdsc_ref" />
             <HYSY ref="hysy_ref" />
             <TDSY ref="tdgy_ref" />
@@ -92,13 +92,32 @@ export default {
             this.flag = !this.flag;
         },
         setDatas() {
+            // 耕地保护
             this.$refs.gdbh_ref.setData({ id: this.params.id });
+            this.$refs.gdbh_ref.init_zbph(this.params);
+            this.$refs.gdbh_ref.init_info(this.params);
+
+            
             // this.$refs.stxf_ref.setData({ id: this.params.id });
             this.$refs.wpjg_ref.setData(this.params);
             this.$refs.tdsc_ref.init_scjd(this.params);
+            // 土地供应
             this.$refs.tdgy_ref.init_tdgy_gy_jd(this.params);
+            this.$refs.tdgy_ref.init_tdgy_gy_jg(this.params);
+            this.$refs.tdgy_ref.init_tdgy_jt_jg(this.params);
+            this.$refs.tdgy_ref.getInfo(this.params);
+            this.$refs.tdgy_ref.init_tdgy_jt_jd(this.params);
+
+
+            // 海域使用
             this.$refs.hysy_ref.init_info(this.params);
+            this.$refs.hysy_ref.init_echart_data(this.params);
+
+            // 报建项目
 
+            this.$refs.bjxm_ref.init_bjxm_echart_info(this.params);
+            // 生态修复
+            this.$refs.stxf_ref.getInfo(this.params);
 
 
         },