safecheck-client 3.0.33-91 → 3.0.33-93

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -469,10 +469,15 @@
469
469
  let that=this
470
470
  this.map = new AMap.Map('check_map', {
471
471
  zoom: 12,
472
+ center: [116.80030599999998, 37.65219],
473
+ showIndoorMap: false,
472
474
  viewMode: '2D', //设置地图模式
473
475
  lang: 'zh_cn', //设置地图语言类型
474
476
  zindex: 99
475
477
  });
478
+
479
+ let bounds = this.map.getBounds();
480
+ this.map.setLimitBounds(bounds);
476
481
  // 异步加载地图插件
477
482
  AMap.plugin(
478
483
  ['AMap.ToolBar','AMap.Geolocation','AMap.Geocoder'], () => {//异步加载插件
@@ -1,46 +1,46 @@
1
- let DataStore = {
2
- params: {},
3
- singleValues: {},
4
- gasstyles: {},
5
- gasbrands: [],
6
- price: [],
7
-
8
- getParam (key) {
9
- return this.params[key]
10
- },
11
- getSingleValue (key) {
12
- return this.singleValues[key]
13
- },
14
- getGasstyle (key) {
15
- return this.gasbrands.key
16
- },
17
- getGasbrand () {
18
- return this.gasbrands
19
- },
20
- getPrice (object) {
21
- // 目前支持三个字段并都有值 f_user_type,f_gasproperties,f_price_type
22
- if (!object.f_user_type || !object.f_gasproperties || !object.f_price_type) {
23
- return
24
- }
25
- let result = []
26
- // 做筛选
27
- this.price.forEach((item) => {
28
- if (item.f_state === '有效' && object.f_user_type === item.f_user_type && object.f_gasproperties === item.f_gasproperties && object.f_price_type === item.f_price_type) {
29
- let value = {
30
- label: item.f_price_name,
31
- value: item
32
- }
33
- result.push(value)
34
- }
35
- })
36
- // 数组去重
37
- let hash = {}
38
- result = result.reduce((item, next) => {
39
- hash[next.label] ? '' : hash[next.label] = true && item.push(next)
40
- return item
41
- }, [])
42
- return Array.from(new Set(result))
43
- }
44
- }
45
-
46
- export default DataStore
1
+ let DataStore = {
2
+ params: {},
3
+ singleValues: {},
4
+ gasstyles: {},
5
+ gasbrands: [],
6
+ price: [],
7
+
8
+ getParam (key) {
9
+ return this.params[key]
10
+ },
11
+ getSingleValue (key) {
12
+ return this.singleValues[key]
13
+ },
14
+ getGasstyle (key) {
15
+ return this.gasbrands.key
16
+ },
17
+ getGasbrand () {
18
+ return this.gasbrands
19
+ },
20
+ getPrice (object) {
21
+ // 目前支持三个字段并都有值 f_user_type,f_gasproperties,f_price_type
22
+ if (!object.f_user_type || !object.f_gasproperties || !object.f_price_type) {
23
+ return
24
+ }
25
+ let result = []
26
+ // 做筛选
27
+ this.price.forEach((item) => {
28
+ if (item.f_state === '有效' && object.f_user_type === item.f_user_type && object.f_gasproperties === item.f_gasproperties && object.f_price_type === item.f_price_type) {
29
+ let value = {
30
+ label: item.f_price_name,
31
+ value: item
32
+ }
33
+ result.push(value)
34
+ }
35
+ })
36
+ // 数组去重
37
+ let hash = {}
38
+ result = result.reduce((item, next) => {
39
+ hash[next.label] ? '' : hash[next.label] = true && item.push(next)
40
+ return item
41
+ }, [])
42
+ return Array.from(new Set(result))
43
+ }
44
+ }
45
+
46
+ export default DataStore