af-mobile-client-vue3 1.1.50 → 1.1.52

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.
package/package.json CHANGED
@@ -1,113 +1,113 @@
1
- {
2
- "name": "af-mobile-client-vue3",
3
- "type": "module",
4
- "version": "1.1.50",
5
- "description": "Vue + Vite component lib",
6
- "license": "MIT",
7
- "engines": {
8
- "node": ">=18.12.0",
9
- "pnpm": ">=8.15.0"
10
- },
11
- "scripts": {
12
- "dev": "cross-env MOCK_SERVER_PORT=8086 vite",
13
- "build": "vue-tsc --noEmit && vite build",
14
- "build:dev": "vue-tsc --noEmit && vite build --mode=development",
15
- "preview": "vite preview",
16
- "lint": "eslint . && vue-tsc --noEmit",
17
- "lint:fix": "eslint . --fix",
18
- "test": "vitest",
19
- "release": "bumpp --commit --push --tag"
20
- },
21
- "dependencies": {
22
- "@iconify/vue": "4.3.0",
23
- "@micro-zoe/micro-app": "1.0.0-rc.24",
24
- "@unhead/vue": "^2.0.5",
25
- "@vant/area-data": "^2.0.0",
26
- "@vant/touch-emulator": "^1.4.0",
27
- "@vant/use": "^1.6.0",
28
- "@vueuse/core": "^13.1.0",
29
- "animate.css": "^4.1.1",
30
- "axios": "^1.8.4",
31
- "crypto-js": "^4.2.0",
32
- "dayjs": "^1.11.13",
33
- "echarts": "^5.6.0",
34
- "lodash-es": "^4.17.21",
35
- "nprogress": "^0.2.0",
36
- "ol": "^10.5.0",
37
- "pinia": "^3.0.2",
38
- "pinia-plugin-persistedstate": "^4.2.0",
39
- "qs": "^6.14.0",
40
- "resize-detector": "^0.3.0",
41
- "store": "^2.0.12",
42
- "vant": "^4.9.18",
43
- "vconsole": "^3.15.1",
44
- "vue": "^3.5.13",
45
- "vue-router": "^4.5.0",
46
- "vue3-hash-calendar": "^1.1.3"
47
- },
48
- "devDependencies": {
49
- "@antfu/eslint-config": "^4.12.0",
50
- "@iconify/json": "2.2.318",
51
- "@types/crypto-js": "^4.2.2",
52
- "@types/lodash-es": "^4.17.12",
53
- "@types/node": "^22.14.1",
54
- "@types/nprogress": "^0.2.3",
55
- "@types/store": "^2.0.5",
56
- "@unocss/eslint-plugin": "^66.1.0-beta.11",
57
- "@unocss/preset-rem-to-px": "66.1.0-beta.11",
58
- "@vitejs/plugin-legacy": "^6.0.2",
59
- "@vitejs/plugin-vue": "^5.2.3",
60
- "autoprefixer": "^10.4.21",
61
- "bumpp": "^10.1.0",
62
- "commitizen": "^4.3.1",
63
- "consola": "^3.4.2",
64
- "cross-env": "^7.0.3",
65
- "cz-emoji-chinese": "^0.3.1",
66
- "eslint": "^9.24.0",
67
- "eslint-ts-patch": "^8.57.0-0",
68
- "husky": "^9.1.7",
69
- "less": "^4.3.0",
70
- "mockjs": "^1.1.0",
71
- "postcss-mobile-forever": "^5.0.0",
72
- "rollup": "^4.40.0",
73
- "terser": "^5.39.0",
74
- "typescript": "^5.8.3",
75
- "unocss": "^66.1.0-beta.11",
76
- "unplugin-auto-import": "^19.1.2",
77
- "unplugin-vue-components": "^28.4.1",
78
- "unplugin-vue-router": "^0.12.0",
79
- "vite": "^6.2.6",
80
- "vite-plugin-compression": "^0.5.1",
81
- "vite-plugin-mock-dev-server": "^1.8.5",
82
- "vite-plugin-pwa": "^1.0.0",
83
- "vite-plugin-sitemap": "^0.7.1",
84
- "vite-plugin-svg-icons": "^2.0.1",
85
- "vite-plugin-vconsole": "^2.1.1",
86
- "vite-plugin-vue-devtools": "^7.7.2",
87
- "vite-plugin-vue-layouts": "^0.11.0",
88
- "vitest": "^3.1.1",
89
- "vue-tsc": "^2.2.8"
90
- },
91
- "pnpm": {
92
- "peerDependencyRules": {
93
- "ignoreMissing": [
94
- "postcss",
95
- "esbuild"
96
- ],
97
- "allowedVersions": {
98
- "rollup": "^4.x"
99
- }
100
- }
101
- },
102
- "config": {
103
- "commitizen": {
104
- "path": "./node_modules/cz-emoji-chinese"
105
- },
106
- "cz-emoji-chinese": {
107
- "skipQuestions": [
108
- "body",
109
- "scope"
110
- ]
111
- }
112
- }
113
- }
1
+ {
2
+ "name": "af-mobile-client-vue3",
3
+ "type": "module",
4
+ "version": "1.1.52",
5
+ "description": "Vue + Vite component lib",
6
+ "license": "MIT",
7
+ "engines": {
8
+ "node": ">=18.12.0",
9
+ "pnpm": ">=8.15.0"
10
+ },
11
+ "scripts": {
12
+ "dev": "cross-env MOCK_SERVER_PORT=8086 vite",
13
+ "build": "vue-tsc --noEmit && vite build",
14
+ "build:dev": "vue-tsc --noEmit && vite build --mode=development",
15
+ "preview": "vite preview",
16
+ "lint": "eslint . && vue-tsc --noEmit",
17
+ "lint:fix": "eslint . --fix",
18
+ "test": "vitest",
19
+ "release": "bumpp --commit --push --tag"
20
+ },
21
+ "dependencies": {
22
+ "@iconify/vue": "4.3.0",
23
+ "@micro-zoe/micro-app": "1.0.0-rc.24",
24
+ "@unhead/vue": "^2.0.5",
25
+ "@vant/area-data": "^2.0.0",
26
+ "@vant/touch-emulator": "^1.4.0",
27
+ "@vant/use": "^1.6.0",
28
+ "@vueuse/core": "^13.1.0",
29
+ "animate.css": "^4.1.1",
30
+ "axios": "^1.8.4",
31
+ "crypto-js": "^4.2.0",
32
+ "dayjs": "^1.11.13",
33
+ "echarts": "^5.6.0",
34
+ "lodash-es": "^4.17.21",
35
+ "nprogress": "^0.2.0",
36
+ "ol": "^10.5.0",
37
+ "pinia": "^3.0.2",
38
+ "pinia-plugin-persistedstate": "^4.2.0",
39
+ "qs": "^6.14.0",
40
+ "resize-detector": "^0.3.0",
41
+ "store": "^2.0.12",
42
+ "vant": "^4.9.18",
43
+ "vconsole": "^3.15.1",
44
+ "vue": "^3.5.13",
45
+ "vue-router": "^4.5.0",
46
+ "vue3-hash-calendar": "^1.1.3"
47
+ },
48
+ "devDependencies": {
49
+ "@antfu/eslint-config": "^4.12.0",
50
+ "@iconify/json": "2.2.318",
51
+ "@types/crypto-js": "^4.2.2",
52
+ "@types/lodash-es": "^4.17.12",
53
+ "@types/node": "^22.14.1",
54
+ "@types/nprogress": "^0.2.3",
55
+ "@types/store": "^2.0.5",
56
+ "@unocss/eslint-plugin": "^66.1.0-beta.11",
57
+ "@unocss/preset-rem-to-px": "66.1.0-beta.11",
58
+ "@vitejs/plugin-legacy": "^6.0.2",
59
+ "@vitejs/plugin-vue": "^5.2.3",
60
+ "autoprefixer": "^10.4.21",
61
+ "bumpp": "^10.1.0",
62
+ "commitizen": "^4.3.1",
63
+ "consola": "^3.4.2",
64
+ "cross-env": "^7.0.3",
65
+ "cz-emoji-chinese": "^0.3.1",
66
+ "eslint": "^9.24.0",
67
+ "eslint-ts-patch": "^8.57.0-0",
68
+ "husky": "^9.1.7",
69
+ "less": "^4.3.0",
70
+ "mockjs": "^1.1.0",
71
+ "postcss-mobile-forever": "^5.0.0",
72
+ "rollup": "^4.40.0",
73
+ "terser": "^5.39.0",
74
+ "typescript": "^5.8.3",
75
+ "unocss": "^66.1.0-beta.11",
76
+ "unplugin-auto-import": "^19.1.2",
77
+ "unplugin-vue-components": "^28.4.1",
78
+ "unplugin-vue-router": "^0.12.0",
79
+ "vite": "^6.2.6",
80
+ "vite-plugin-compression": "^0.5.1",
81
+ "vite-plugin-mock-dev-server": "^1.8.5",
82
+ "vite-plugin-pwa": "^1.0.0",
83
+ "vite-plugin-sitemap": "^0.7.1",
84
+ "vite-plugin-svg-icons": "^2.0.1",
85
+ "vite-plugin-vconsole": "^2.1.1",
86
+ "vite-plugin-vue-devtools": "^7.7.2",
87
+ "vite-plugin-vue-layouts": "^0.11.0",
88
+ "vitest": "^3.1.1",
89
+ "vue-tsc": "^2.2.8"
90
+ },
91
+ "pnpm": {
92
+ "peerDependencyRules": {
93
+ "ignoreMissing": [
94
+ "postcss",
95
+ "esbuild"
96
+ ],
97
+ "allowedVersions": {
98
+ "rollup": "^4.x"
99
+ }
100
+ }
101
+ },
102
+ "config": {
103
+ "commitizen": {
104
+ "path": "./node_modules/cz-emoji-chinese"
105
+ },
106
+ "cz-emoji-chinese": {
107
+ "skipQuestions": [
108
+ "body",
109
+ "scope"
110
+ ]
111
+ }
112
+ }
113
+ }
@@ -1,5 +1,6 @@
1
1
  <script setup lang="ts">
2
2
  import type { LocationResult, PhoneLocationStatus } from '../types'
3
+ import { post } from '@af-mobile-client-vue3/services/restTools'
3
4
  import { mobileUtil } from '@af-mobile-client-vue3/utils/mobileUtil'
4
5
  import { Button } from 'vant'
5
6
  import { nextTick, onMounted, ref, watch } from 'vue'
@@ -9,6 +10,7 @@ interface Props {
9
10
  modelValue?: LocationResult
10
11
  defaultCenter?: [number, number]
11
12
  defaultZoom?: number
13
+ serviceName?: string
12
14
  }
13
15
 
14
16
  const props = withDefaults(defineProps<Props>(), {
@@ -53,6 +55,16 @@ onMounted(async () => {
53
55
  center: props.defaultCenter,
54
56
  zoom: props.defaultZoom,
55
57
  })
58
+ try {
59
+ const webConfig = await post(`/api/${props.serviceName || 'default-service'}/logic/openapi/getLiuliConfiguration`, { configName: 'webConfig' })
60
+ const wms = webConfig.wms ?? {}
61
+ if (Array.isArray(wms.layers) && wms.layers.length > 0 && wms.wms?.url) {
62
+ await mapRef.value.addWMSLayers(wms)
63
+ }
64
+ }
65
+ catch (e) {
66
+ console.error('初始化地图wms图层失败', e)
67
+ }
56
68
  // 初始化后尝试获取地址信息
57
69
  handleCenterChange(props.defaultCenter)
58
70
 
@@ -30,6 +30,8 @@ export interface UserInfo {
30
30
  f_operatorid: string
31
31
  f_orgid: string
32
32
  f_orgname: string
33
+ f_depid: string
34
+ f_depname: string
33
35
  }
34
36
 
35
37
  interface IUserState {
@@ -172,6 +172,8 @@ async function afterGeneral(result) {
172
172
  f_operatorid: result.id,
173
173
  f_orgid: result.orgid,
174
174
  f_orgname: result.orgs,
175
+ f_depid: result.f_department_id,
176
+ f_depname: result.f_department_name,
175
177
  }
176
178
  userState.setUserInfo(user)
177
179
  // 如果result中没有返回 权限 需要主动获取权限列表