Selaa lähdekoodia

接口字段调整

ming 1 vuosi sitten
vanhempi
commit
a102eb3b22
1 muutettua tiedostoa jossa 75 lisäystä ja 30 poistoa
  1. 75 30
      src/views/security-plan.vue

+ 75 - 30
src/views/security-plan.vue

@@ -32,7 +32,7 @@
                             </div>
                         </el-row>
 
-                        <el-row  class="sdqBasicInfo sdline2">
+                        <el-row  class="sdqBasicInfo sdline2" >
                             <div
                                 class="basicItem"
                                 v-for="(item, index) in diversionArea.slice(7,10)"
@@ -52,12 +52,14 @@
                                 </div>
                             </div>
                         </el-row>
+                       
 
-                        <el-row  class="sdline3">
+                        <el-row v-if="basicStatisStatus" class="sdline3" >
                             <div
                                 class="basicItem"
                                 v-for="(item, index) in line3Array"
                                 :key="index"
+                                @click="basicStaticsData"
                             >
                                 <div style="padding: 0.03rem 0; text-align: center">
                                     <span style="display: block">
@@ -73,6 +75,18 @@
                                 </div>
                             </div>
                         </el-row>
+                        <el-row  v-else class="sdqBasicInfo sdline3" style="position:relative">
+                            <div @click="basicGoBack" class="return">
+                                <div class="returnText">返回</div>
+                            </div>
+                           
+                            表格展示区域
+
+                            <!-- <el-table>
+
+                            </el-table> -->
+
+                        </el-row>
                     </div>
                 </div>
                 
@@ -873,6 +887,7 @@ export default {
     components: { category, gauge, CountTo,unitBox },
     data() {
         return {
+            basicStatisStatus:true,
             gridStatisticsNum:{
                 total:0,
                 over:0,
@@ -1452,21 +1467,48 @@ export default {
         this.anbaoMap()
         this.getFireSiteDuty(); //各站点执勤实力
         this.selectVideo(); //视频在线
-        // this.sadianSelect(this.checkedArray.checkedData[0]); //撒点
-        this.getStaticData(this.value111)
+        // this.sadianSelect(this.checkedArray.checkedData[0]);  //撒点
+        this.getStaticData(this.value111)   //疏导区社会单位情况统计
+        this.getZQStaticData()  //执勤战备力量部署
     },
     methods: {
 
+        basicStaticsData(){  //疏导区基本情况 统计点击事件
+            this.basicStatisStatus=false;
+        },
+        basicGoBack(){  //疏导区基本情况 返回
+
+            this.basicStatisStatus=true;
+        },
+
+        getZQStaticData(){
+                this.$axios.post(this.$api.water.baseGgpFacilityStatistic,{
+                                "facilityType": [33,34,35,36 ],
+                                "statisticType":"facilityType",
+                        }).then((res) => {
+                            console.log(res)
+                    // this.staticData.array=res.data;
+                    // var colorArr=['#00C8B8','#068DFF','#FF843A','#7DD807'];
+                    // this.staticData.array.forEach((item, index) => {
+                    //     item.color = colorArr[index]
+                    // })
+                    // console.log(this.staticData.array)
+
+                    // var totalCount=0
+                    // res.data.forEach(function(item){
+                    //     totalCount+=Number(item.count)
+
+                    // })
+                    // this.staticData.total=totalCount
+                })
+
+        },
+
+
         getStaticData(type){
-            // this.$axios.post(
-            //         this.$api.water.baseGgpFacilityStatistic +
-            //         "?" +
-            //         this.$qs.stringify({
-            //             facilityType: type, 
-            //         })
-            //     ).then(res=>{
                 this.$axios.post(this.$api.water.baseGgpFacilityStatistic,{
-                                "facilityType": [type ] 
+                                "facilityType": [type ] ,
+                                "statisticType":"street",
                         }).then((res) => {
                     this.staticData.array=res.data;
                     var colorArr=['#00C8B8','#068DFF','#FF843A','#7DD807'];
@@ -2513,6 +2555,23 @@ export default {
 <style lang="scss" scoped>
 @import "@/assets/scss/color.scss";
 .contentBox {
+    .return{
+        position: absolute;
+        top:0px;
+        right:0px;
+        margin-top:0!important;
+        .returnText {
+            width: 0.5rem;
+            text-align: center;
+            height: 0.3rem;
+            line-height: 0.3rem;
+            box-shadow: inset 0 0 0.05rem 0.05rem #1b4f90;
+            background: rgba(19, 42, 90, 0.2) !important;
+            color: #fff;
+            float: right;
+            margin-top: 0;
+        }
+    }
     .leftBox {
         .leftTop {
             height: 43%;
@@ -2604,8 +2663,9 @@ export default {
                     margin-top:.25rem;
                    
                     .basicItem{
-                    width:14.28%; margin: 0px 0;  box-sizing: border-box;
-                    position:relative;
+                        cursor:pointer;
+                        width:14.28%; margin: 0px 0;  box-sizing: border-box;
+                        position:relative;
                     }
                     // .basicItem::after {
                     //     position: absolute; /*绝对定位*/
@@ -2820,22 +2880,7 @@ export default {
             height: 30%;
             max-height: 30%;
             position:relative;
-            .return{
-                position: absolute;
-                top:0px;
-                right:0px;
-                .returnText {
-                    width: 0.5rem;
-                    text-align: center;
-                    height: 0.3rem;
-                    line-height: 0.3rem;
-                    box-shadow: inset 0 0 0.05rem 0.05rem #1b4f90;
-                    background: rgba(19, 42, 90, 0.2) !important;
-                    color: #fff;
-                    float: right;
-                    margin-top: 0;
-                }
-            }
+            
 
             .rightTopContent {
                 width: 100%;