File tree Expand file tree Collapse file tree 7 files changed +11
-9
lines changed
Expand file tree Collapse file tree 7 files changed +11
-9
lines changed Original file line number Diff line number Diff line change @@ -2,5 +2,5 @@ import AudioVisual from 'vue-audio-visual'
22import BaiduMap from 'vue-baidu-map'
33Vue . use ( AudioVisual )
44Vue . use ( BaiduMap , {
5- ak : 'WpeAb6pL4tsX2ZVd56GHbO9Ut6c4HZhG' ,
5+ ak : Vue . prototype . $dgiot . secret . baidu . map ,
66} )
Original file line number Diff line number Diff line change @@ -28,9 +28,9 @@ const store = new Vuex.Store({
2828 plugins,
2929} )
3030export default store
31- info . secret = Base64 . encode ( JSON . stringify ( info . secret ) )
32- info . secretMsg =
33- 'dgiot.secret字段属于机密信息,为了安全起见不予直接展示。已使用Base64加密'
31+ // info.secret = Base64.encode(JSON.stringify(info.secret))
32+ // info.secretMsg =
33+ // 'dgiot.secret字段属于机密信息,为了安全起见不予直接展示。已使用Base64加密'
3434// 解密方法 Base64.decode(dgiot.secret)
3535// if (!window.isInnerIp) getTags()
3636
Original file line number Diff line number Diff line change @@ -547,5 +547,7 @@ export default {
547547 Vue . prototype . $getTopic = getTopic
548548 Vue . prototype . $subscribe = subscribe
549549 Vue . prototype . $unSubscribe = unSubscribe
550+ // 全局配置环境变量
551+ Vue . prototype . $dgiot = window . dgiot
550552 } ,
551553}
Original file line number Diff line number Diff line change 5252 </el-input >
5353 </label >
5454 <baidu-map
55- ak =" WpeAb6pL4tsX2ZVd56GHbO9Ut6c4HZhG "
55+ : ak =" $dgiot.secret.baidu.map "
5656 :center =" mapLabel.position"
5757 :map-click =" false"
5858 :scroll-wheel-zoom =" true"
Original file line number Diff line number Diff line change 3636 </el-input >
3737 </label >
3838 <baidu-map
39- ak =" WpeAb6pL4tsX2ZVd56GHbO9Ut6c4HZhG "
39+ : ak =" $dgiot.secret.baidu.map "
4040 :center =" { lng: 116.404, lat: 39.915 }"
4141 :map-click =" false"
4242 :scroll-wheel-zoom =" true"
150150 </label >
151151 <baidu-map
152152 v-if =" map.innerVisible"
153- ak =" WpeAb6pL4tsX2ZVd56GHbO9Ut6c4HZhG "
153+ : ak =" $dgiot.secret.baidu.map "
154154 :center =" { lng: 116.404, lat: 39.915 }"
155155 :map-click =" false"
156156 :scroll-wheel-zoom =" true"
Original file line number Diff line number Diff line change 704704 },
705705 mapType: ' baidu' ,
706706 isShow: true ,
707- ak: ' WpeAb6pL4tsX2ZVd56GHbO9Ut6c4HZhG ' ,
707+ ak: this . $dgiot . secret . baidu . map ,
708708 // ak: 'oW2UEhdth2tRbEE4FUpF9E5YVDCIPYih',
709709 // center:{ lng: 120.187273, lat: 30.334877 },
710710 center: {
Original file line number Diff line number Diff line change 704704 },
705705 mapType: ' baidu' ,
706706 isShow: true ,
707- ak: ' WpeAb6pL4tsX2ZVd56GHbO9Ut6c4HZhG ' ,
707+ ak: this . $dgiot . secret . baidu . map ,
708708 // ak: 'oW2UEhdth2tRbEE4FUpF9E5YVDCIPYih',
709709 // center:{ lng: 120.187273, lat: 30.334877 },
710710 center: {
You can’t perform that action at this time.
0 commit comments