surprise
2024-04-17 f560ccccd3878497339daeee3241a81c263898f7
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
<template>
  <div class="showRightClickBtn">
    <div v-for="(item, index) in btnlist" :key="index" >
      <el-checkbox v-model="item.value" @change="doRight(item)">{{ item.name }}</el-checkbox>
    </div>
  </div>
</template>
 
<script>
import { showdataJCZ } from "../../utils/work";
export default {
  name: "showcheak",
  data() {
    return {
      btnlist: [
        {
          name: "场强范围",
          value: false,
        },
        {
          name: "黑广播",
          value: false,
        },
        {
          name: "伪基站覆盖范围",
          value: false,
        },
      ],
    };
  },
  mounted() {},
  methods: {
    close() {
      this.showdia = false;
    },
    doRight(item) {
      if (item.name === "场强范围") {
        this.btnlist[0].value?this.$set(this.btnlist,0,{name:"场强范围",value:false}):this.$set(this.btnlist,0,{name:"场强范围",value:true})
        if (this.btnlist[0].value) {
          let lng = window.pick.id.properties.monstationLg._value;
          let lat = window.pick.id.properties.monstationLa._value;
          let height = 0;
          if (window.pick.id.properties._monstationName._value == "云海") {
            lng = 121.444697;
            lat = 31.21385;
            height = 105;
          }
          if (window.FieldIntensity) {
            window.FieldIntensity.deleteObject();
            window.FieldIntensity = null;
          }
          let url = "./static/json/ant.json";
          window.FieldIntensity = sgworld.Creator.FieldIntensity(url, {
            center: [lng, lat, height], // 备用中心坐标
            scale: 0.3,
          });
        } else {
          //删除事件
        }
      }
 
      if (item.name === "伪基站覆盖范围") {
        this.btnlist[1].value?this.$set(this.btnlist,1,{name:"伪基站覆盖范围",value:false}):this.$set(this.btnlist,1,{name:"伪基站覆盖范围",value:true})
        if (this.btnlist[1].value) {
          window.showtable = true;
          window.objform = {
            analysisType: "伪基站",
            areaResult: 10185.58366101,
            coverageThreshold: "-110",
            freqPoint: 100,
            frequency: 954,
            modelName: "",
            monFrequency: "",
            monstationGuid: "2",
            propModel: 2,
            rxAntGain: 0,
            rxAntHeight: 0,
            txAntGain: 0,
            txAntHeight: 10,
            txFrequency: "",
            txPower: 40,
          };
          window.objform.monstationGuid =
            window.pick.id.properties._monstationGuid._value;
          let arr = [window.objform];
          showdataJCZ(arr);
        } else {
          //删除事件
        }
      }
 
      if (item.name === "黑广播") {
         this.btnlist[2].value?this.$set(this.btnlist,2,{name:"黑广播",value:false}):this.$set(this.btnlist,2,{name:"黑广播",value:true})
 
        if (this.btnlist[2].value) {
          window.showtable = true;
          window.objform = {
            analysisType: "黑广播",
            areaResult: 99.83516631,
            coverageThreshold: "-110",
            freqPoint: 954,
            frequency: 100,
            modelName: "",
            monFrequency: "",
            monstationGuid: "2",
            propModel: 2,
            rxAntGain: 0,
            rxAntHeight: 0,
            txAntGain: 0,
            txAntHeight: 20,
            txFrequency: "",
            txPower: 50,
          };
          window.objform.monstationGuid =
            pick.id.properties._monstationGuid._value;
          let arr = [window.objform];
          showdataJCZ(arr);
        }else{
          //删除事件
        }
      }
    },
  },
};
</script>
 
<style scoped>
.showRightClickBtn > div {
  background: url(~@/assets/image/test/bjtp.png);
  background-position: center;
  background-size: 100% 100%;
  color: #fff;
  width: 150px;
  height: 40px;
  pointer-events: all;
}
.showRightClickBtn >>> .el-checkbox {
  color: #fff;
  margin: 10px;
}
</style>