af-mobile-client-vue3 1.3.55 → 1.3.58

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.
Files changed (40) hide show
  1. package/package.json +1 -1
  2. package/public/favicon.svg +4 -4
  3. package/scripts/verifyCommit.js +19 -19
  4. package/src/App.vue +20 -7
  5. package/src/components/data/UserDetail/types.ts +1 -1
  6. package/src/components/data/XReportGrid/XAddReport/index.ts +1 -1
  7. package/src/components/data/XReportGrid/XReportDrawer/index.ts +1 -1
  8. package/src/components/data/XTag/index.vue +10 -10
  9. package/src/components/layout/TabBarLayout/index.vue +40 -40
  10. package/src/font-style/Inter-Bold.woff2 +0 -0
  11. package/src/font-style/Inter-Medium.woff2 +0 -0
  12. package/src/font-style/Inter-Regular.woff2 +0 -0
  13. package/src/font-style/Inter-SemiBold.woff2 +0 -0
  14. package/src/font-style/PingFangSC-Medium.subset.woff2 +0 -0
  15. package/src/font-style/PingFangSC-Medium.woff2 +0 -0
  16. package/src/font-style/PingFangSC-Regular.subset.woff2 +0 -0
  17. package/src/font-style/PingFangSC-Semibold.subset.woff2 +0 -0
  18. package/src/font-style/PingFangSC-Semibold.woff2 +0 -0
  19. package/src/font-style/font.css +66 -2
  20. package/src/hooks/useCommon.ts +9 -9
  21. package/src/plugins/AppData.ts +38 -38
  22. package/src/router/invoiceRoutes.ts +33 -33
  23. package/src/services/api/common.ts +109 -109
  24. package/src/services/api/manage.ts +8 -8
  25. package/src/services/api/search.ts +16 -16
  26. package/src/services/restTools.ts +56 -56
  27. package/src/services/v3Api.ts +11 -11
  28. package/src/utils/authority-utils.ts +84 -84
  29. package/src/utils/crypto.ts +39 -39
  30. package/src/utils/runEvalFunction.ts +13 -13
  31. package/src/views/component/EvaluateRecordView/index.vue +40 -40
  32. package/src/views/component/XCellDetailView/index.vue +217 -217
  33. package/src/views/component/XOlMapView/XLocationPicker/index.vue +118 -118
  34. package/src/views/component/XReportFormIframeView/index.vue +47 -47
  35. package/src/views/component/XReportFormView/index.vue +13 -13
  36. package/src/views/component/XSignatureView/index.vue +50 -50
  37. package/src/views/component/notice.vue +46 -46
  38. package/src/views/component/topNav.vue +36 -36
  39. package/src/views/invoiceShow/index.vue +61 -61
  40. package/src/views/user/login/index.vue +22 -22
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "af-mobile-client-vue3",
3
3
  "type": "module",
4
- "version": "1.3.55",
4
+ "version": "1.3.58",
5
5
  "packageManager": "pnpm@10.13.1",
6
6
  "description": "Vue + Vite component lib",
7
7
  "engines": {
@@ -1,4 +1,4 @@
1
- <svg t="1709866807903" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4913" width="32" height="32">
2
- <path d="M512 598.528a111.232 111.232 0 0 0-111.232 111.2064V870.4h222.464v-160.6656c0-61.44-49.792-111.232-111.232-111.232z m0 58.0608c-30.72 0-55.6032 24.9088-55.6032 55.6288v105.0368h111.2064v-105.0368c0-30.72-24.8832-55.6288-55.6032-55.6288z" fill="#FB4D31" p-id="4914"></path>
3
- <path d="M542.08 270.208l45.2608-78.5408a24.5248 24.5248 0 0 0 0-25.6A26.4448 26.4448 0 0 0 564.1472 153.6a26.3424 26.3424 0 0 0-22.5792 13.44L512 217.6256l-29.5424-50.5344c-4.5824-8.192-13.184-13.312-22.5536-13.4912a26.4448 26.4448 0 0 0-23.2448 12.4928 24.5248 24.5248 0 0 0 0 25.6l45.2352 78.5152L156.928 832.768a24.4736 24.4736 0 0 0 0.3328 25.088c4.8384 7.8336 13.3888 12.544 22.5792 12.5184h664.3456c9.3184 0 17.92-4.7616 22.6304-12.4672a24.4736 24.4736 0 0 0 0.3072-25.088l-325.0176-562.688v0.0512zM619.52 816.64h-33.3568c-12.3648 0-9.6768 0.1024-65.0496 0H512c-55.3728 0.1024-24.704 0-61.7984 0H225.28L512 322.1248 798.72 816.64h-179.2z" fill="#000000" p-id="4915"></path>
4
- </svg>
1
+ <svg t="1709866807903" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4913" width="32" height="32">
2
+ <path d="M512 598.528a111.232 111.232 0 0 0-111.232 111.2064V870.4h222.464v-160.6656c0-61.44-49.792-111.232-111.232-111.232z m0 58.0608c-30.72 0-55.6032 24.9088-55.6032 55.6288v105.0368h111.2064v-105.0368c0-30.72-24.8832-55.6288-55.6032-55.6288z" fill="#FB4D31" p-id="4914"></path>
3
+ <path d="M542.08 270.208l45.2608-78.5408a24.5248 24.5248 0 0 0 0-25.6A26.4448 26.4448 0 0 0 564.1472 153.6a26.3424 26.3424 0 0 0-22.5792 13.44L512 217.6256l-29.5424-50.5344c-4.5824-8.192-13.184-13.312-22.5536-13.4912a26.4448 26.4448 0 0 0-23.2448 12.4928 24.5248 24.5248 0 0 0 0 25.6l45.2352 78.5152L156.928 832.768a24.4736 24.4736 0 0 0 0.3328 25.088c4.8384 7.8336 13.3888 12.544 22.5792 12.5184h664.3456c9.3184 0 17.92-4.7616 22.6304-12.4672a24.4736 24.4736 0 0 0 0.3072-25.088l-325.0176-562.688v0.0512zM619.52 816.64h-33.3568c-12.3648 0-9.6768 0.1024-65.0496 0H512c-55.3728 0.1024-24.704 0-61.7984 0H225.28L512 322.1248 798.72 816.64h-179.2z" fill="#000000" p-id="4915"></path>
4
+ </svg>
@@ -1,19 +1,19 @@
1
- import fs from 'node:fs'
2
-
3
- // import process from 'node:process'
4
-
5
- const msg = fs.readFileSync('.git/COMMIT_EDITMSG', 'utf-8').trim()
6
-
7
- const commitRE = /^(?:revert: )?(?:feat|fix|docs|dx|style|refactor|perf|test|workflow|build|ci|chore|types|wip|release)(?:\(.+\))?: .{1,50}/
8
- // const mergeRe = /^(Merge pull request|Merge branch)/
9
-
10
- if (!commitRE.test(msg)) {
11
- // if (!mergeRe.test(msg)) {
12
- // console.log('git commit unpass')
13
- // console.error('git commit error, needs title(scope): desc')
14
- // process.exit(1)
15
- // }
16
- }
17
- else {
18
- console.log('git commit pass')
19
- }
1
+ import fs from 'node:fs'
2
+
3
+ // import process from 'node:process'
4
+
5
+ const msg = fs.readFileSync('.git/COMMIT_EDITMSG', 'utf-8').trim()
6
+
7
+ const commitRE = /^(?:revert: )?(?:feat|fix|docs|dx|style|refactor|perf|test|workflow|build|ci|chore|types|wip|release)(?:\(.+\))?: .{1,50}/
8
+ // const mergeRe = /^(Merge pull request|Merge branch)/
9
+
10
+ if (!commitRE.test(msg)) {
11
+ // if (!mergeRe.test(msg)) {
12
+ // console.log('git commit unpass')
13
+ // console.error('git commit error, needs title(scope): desc')
14
+ // process.exit(1)
15
+ // }
16
+ }
17
+ else {
18
+ console.log('git commit pass')
19
+ }
package/src/App.vue CHANGED
@@ -1,5 +1,4 @@
1
1
  <script setup lang="ts">
2
- import type { ConfigProviderThemeVars } from 'vant'
3
2
  import NavBar from '@af-mobile-client-vue3/components/core/NavBar/index.vue'
4
3
  import Tabbar from '@af-mobile-client-vue3/components/core/Tabbar/index.vue'
5
4
  import { isDark, preferredDark } from '@af-mobile-client-vue3/composables/dark'
@@ -8,7 +7,7 @@ import { useHead } from '@unhead/vue'
8
7
  import {
9
8
  ConfigProvider as VanConfigProvider,
10
9
  } from 'vant/es'
11
- import { computed, reactive } from 'vue'
10
+ import { computed } from 'vue'
12
11
  import { appDescription, appName } from './constants'
13
12
 
14
13
  useHead({
@@ -41,14 +40,10 @@ const keepAliveRouteNames = computed(() => {
41
40
  const mode = computed(() => {
42
41
  return isDark.value ? 'dark' : 'light'
43
42
  })
44
-
45
- const themeVars: ConfigProviderThemeVars = reactive({
46
- baseFont: 'PingFangSC-Regular-woff2, serif',
47
- })
48
43
  </script>
49
44
 
50
45
  <template>
51
- <VanConfigProvider :theme="mode" :theme-vars="themeVars" theme-vars-scope="global">
46
+ <VanConfigProvider :theme="mode" theme-vars-scope="global">
52
47
  <NavBar />
53
48
  <router-view v-slot="{ Component }">
54
49
  <section class="app-wrapper">
@@ -63,6 +58,24 @@ const themeVars: ConfigProviderThemeVars = reactive({
63
58
 
64
59
  <style>
65
60
  @import './font-style/font.css';
61
+ body {
62
+ font-family:
63
+ Inter,
64
+ 'PingFang SC',
65
+ 'Microsoft YaHei UI',
66
+ system-ui,
67
+ -apple-system,
68
+ 'Segoe UI',
69
+ Roboto,
70
+ 'Helvetica Neue',
71
+ Arial,
72
+ 'Noto Sans',
73
+ 'Apple Color Emoji',
74
+ 'Segoe UI Emoji',
75
+ 'Segoe UI Symbol',
76
+ 'Noto Color Emoji',
77
+ sans-serif !important;
78
+ }
66
79
  input[type='password']::-ms-reveal {
67
80
  display: none;
68
81
  }
@@ -23,4 +23,4 @@ export interface ConfigItem {
23
23
  format?: (value: string | number) => string
24
24
  template?: string
25
25
  condition?: (data: any) => boolean
26
- }
26
+ }
@@ -7,4 +7,4 @@ export default {
7
7
  install(app: App) {
8
8
  app.component('XAddReport', XAddReport)
9
9
  },
10
- }
10
+ }
@@ -7,4 +7,4 @@ export default {
7
7
  install(app: App) {
8
8
  app.component('XReportDrawer', XReportDrawer)
9
9
  },
10
- }
10
+ }
@@ -1,10 +1,10 @@
1
- <script setup lang="ts">
2
- </script>
3
-
4
- <template>
5
- <VanTag />
6
- </template>
7
-
8
- <style scoped lang="less">
9
-
10
- </style>
1
+ <script setup lang="ts">
2
+ </script>
3
+
4
+ <template>
5
+ <VanTag />
6
+ </template>
7
+
8
+ <style scoped lang="less">
9
+
10
+ </style>
@@ -1,40 +1,40 @@
1
- <script setup lang="ts">
2
- import {
3
- Tabbar as VanTabbar,
4
- TabbarItem as VanTabbarItem,
5
- } from 'vant'
6
- import { defineProps } from 'vue'
7
-
8
- const { barList, callbacks } = defineProps<{
9
- barList?: Array<{ icon: string, text: string, method: string }>
10
- callbacks?: object
11
- }>()
12
-
13
- function handleClick(index) {
14
- const methodName = (barList[index] as any).method
15
- callbacks[methodName]()
16
- }
17
- </script>
18
-
19
- <template>
20
- <VanTabbar class="van-bar">
21
- <VanTabbarItem v-for="(item, index) in barList" :key="index" :icon="(item as any).icon" @click="handleClick(index)">
22
- {{ (item as any).text }}
23
- </VanTabbarItem>
24
- </VanTabbar>
25
- </template>
26
-
27
- <style scoped lang="less">
28
- .van-bar {
29
- height: 8vh;
30
- background-color: #f7f8fa;
31
- color: black;
32
- }
33
- .van-tabbar-item:hover {
34
- color: var(--van-text-color-2);
35
- }
36
- :deep(.van-tabbar-item--active) {
37
- background-color: #f7f8fa;
38
- color: black;
39
- }
40
- </style>
1
+ <script setup lang="ts">
2
+ import {
3
+ Tabbar as VanTabbar,
4
+ TabbarItem as VanTabbarItem,
5
+ } from 'vant'
6
+ import { defineProps } from 'vue'
7
+
8
+ const { barList, callbacks } = defineProps<{
9
+ barList?: Array<{ icon: string, text: string, method: string }>
10
+ callbacks?: object
11
+ }>()
12
+
13
+ function handleClick(index) {
14
+ const methodName = (barList[index] as any).method
15
+ callbacks[methodName]()
16
+ }
17
+ </script>
18
+
19
+ <template>
20
+ <VanTabbar class="van-bar">
21
+ <VanTabbarItem v-for="(item, index) in barList" :key="index" :icon="(item as any).icon" @click="handleClick(index)">
22
+ {{ (item as any).text }}
23
+ </VanTabbarItem>
24
+ </VanTabbar>
25
+ </template>
26
+
27
+ <style scoped lang="less">
28
+ .van-bar {
29
+ height: 8vh;
30
+ background-color: #f7f8fa;
31
+ color: black;
32
+ }
33
+ .van-tabbar-item:hover {
34
+ color: var(--van-text-color-2);
35
+ }
36
+ :deep(.van-tabbar-item--active) {
37
+ background-color: #f7f8fa;
38
+ color: black;
39
+ }
40
+ </style>
Binary file
@@ -1,4 +1,68 @@
1
1
  @font-face {
2
- font-family: 'PingFangSC-Regular-woff2';
3
- src: url('./PingFangSC-Regular.woff2') format('woff2');
2
+ font-family: 'PingFang SC';
3
+ font-style: normal;
4
+ font-weight: 400;
5
+ font-display: swap;
6
+ src: url('./PingFangSC-Regular.subset.woff2') format('woff2');
7
+ }
8
+
9
+ @font-face {
10
+ font-family: 'PingFang SC';
11
+ font-style: normal;
12
+ font-weight: 500;
13
+ font-display: swap;
14
+ src: url('./PingFangSC-Medium.subset.woff2') format('woff2');
15
+ }
16
+
17
+ @font-face {
18
+ font-family: 'PingFang SC';
19
+ font-style: normal;
20
+ font-weight: 600;
21
+ font-display: swap;
22
+ src: url('./PingFangSC-Semibold.subset.woff2') format('woff2');
23
+ }
24
+
25
+ /* fonts.css */
26
+ @font-face {
27
+ font-family: 'Inter';
28
+ font-style: normal;
29
+ font-weight: 400;
30
+ font-display: swap;
31
+ src: url('./Inter-Regular.woff2') format('woff2');
32
+ unicode-range:
33
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074,
34
+ U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
35
+ }
36
+
37
+ @font-face {
38
+ font-family: 'Inter';
39
+ font-style: normal;
40
+ font-weight: 500;
41
+ font-display: swap;
42
+ src: url('./Inter-Medium.woff2') format('woff2');
43
+ unicode-range:
44
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074,
45
+ U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
46
+ }
47
+
48
+ @font-face {
49
+ font-family: 'Inter';
50
+ font-style: normal;
51
+ font-weight: 600;
52
+ font-display: swap;
53
+ src: url('./Inter-SemiBold.woff2') format('woff2');
54
+ unicode-range:
55
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074,
56
+ U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
57
+ }
58
+
59
+ @font-face {
60
+ font-family: 'Inter';
61
+ font-style: normal;
62
+ font-weight: 700;
63
+ font-display: swap;
64
+ src: url('./Inter-Bold.woff2') format('woff2');
65
+ unicode-range:
66
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074,
67
+ U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
4
68
  }
@@ -1,9 +1,9 @@
1
- export function formatDate(date) {
2
- const year = date.getFullYear()
3
- const month = (date.getMonth() + 1).toString().padStart(2, '0') // 月份加1,并补零
4
- const day = date.getDate().toString().padStart(2, '0') // 日期补零
5
- const hours = date.getHours().toString().padStart(2, '0') // 小时补零
6
- const minutes = date.getMinutes().toString().padStart(2, '0') // 分钟补零
7
- const seconds = date.getSeconds().toString().padStart(2, '0') // 秒数补零
8
- return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`
9
- }
1
+ export function formatDate(date) {
2
+ const year = date.getFullYear()
3
+ const month = (date.getMonth() + 1).toString().padStart(2, '0') // 月份加1,并补零
4
+ const day = date.getDate().toString().padStart(2, '0') // 日期补零
5
+ const hours = date.getHours().toString().padStart(2, '0') // 小时补零
6
+ const minutes = date.getMinutes().toString().padStart(2, '0') // 分钟补零
7
+ const seconds = date.getSeconds().toString().padStart(2, '0') // 秒数补零
8
+ return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`
9
+ }
@@ -1,38 +1,38 @@
1
- import type { App } from 'vue'
2
- import { manageApi } from '@af-mobile-client-vue3/services/api/manage'
3
- import { APP_WEB_CONFIG_KEY } from '@af-mobile-client-vue3/stores/mutation-type'
4
- import { handleTree } from '@af-mobile-client-vue3/utils/dataUtil'
5
- import { indexedDB } from '@af-mobile-client-vue3/utils/indexedDB'
6
- import { createStorage } from '@af-mobile-client-vue3/utils/Storage'
7
-
8
- const Storage = createStorage({ storage: localStorage })
9
-
10
- export const GetAppDataService = {
11
- install(app: App<Element>) {
12
- app.provide('$appdata', GetAppDataService)
13
- },
14
- async load() {
15
- },
16
- // 返回树形省市区
17
- async getDivisionsOhChinaForTree() {
18
- // 获取省市区数据
19
- return new Promise((resolve, reject) => {
20
- try {
21
- indexedDB.getByWeb('divisionsOhChina', manageApi.getDivisionsOhChina, {}, (res) => {
22
- resolve(res)
23
- }, (processRes) => {
24
- return handleTree(processRes, 'code', 'parentcode', null)
25
- })
26
- }
27
- catch (e) {
28
- reject(e)
29
- }
30
- })
31
- },
32
- getWebConfigByKey(key: string) {
33
- const object = Storage.get(APP_WEB_CONFIG_KEY)
34
- return object[key]
35
- },
36
- }
37
-
38
- export default GetAppDataService
1
+ import type { App } from 'vue'
2
+ import { manageApi } from '@af-mobile-client-vue3/services/api/manage'
3
+ import { APP_WEB_CONFIG_KEY } from '@af-mobile-client-vue3/stores/mutation-type'
4
+ import { handleTree } from '@af-mobile-client-vue3/utils/dataUtil'
5
+ import { indexedDB } from '@af-mobile-client-vue3/utils/indexedDB'
6
+ import { createStorage } from '@af-mobile-client-vue3/utils/Storage'
7
+
8
+ const Storage = createStorage({ storage: localStorage })
9
+
10
+ export const GetAppDataService = {
11
+ install(app: App<Element>) {
12
+ app.provide('$appdata', GetAppDataService)
13
+ },
14
+ async load() {
15
+ },
16
+ // 返回树形省市区
17
+ async getDivisionsOhChinaForTree() {
18
+ // 获取省市区数据
19
+ return new Promise((resolve, reject) => {
20
+ try {
21
+ indexedDB.getByWeb('divisionsOhChina', manageApi.getDivisionsOhChina, {}, (res) => {
22
+ resolve(res)
23
+ }, (processRes) => {
24
+ return handleTree(processRes, 'code', 'parentcode', null)
25
+ })
26
+ }
27
+ catch (e) {
28
+ reject(e)
29
+ }
30
+ })
31
+ },
32
+ getWebConfigByKey(key: string) {
33
+ const object = Storage.get(APP_WEB_CONFIG_KEY)
34
+ return object[key]
35
+ },
36
+ }
37
+
38
+ export default GetAppDataService
@@ -1,33 +1,33 @@
1
- import type { RouteRecordRaw } from 'vue-router'
2
- import PageLayout from '@af-mobile-client-vue3/layout/PageLayout.vue'
3
- import NotFound from '@af-mobile-client-vue3/views/common/NotFound.vue'
4
- import invoiceShow from '@af-mobile-client-vue3/views/invoiceShow/index.vue'
5
-
6
- const routes: Array<RouteRecordRaw> = [
7
- {
8
- path: '/',
9
- name: 'root',
10
- component: PageLayout,
11
- redirect: { name: 'Component' },
12
- children: [
13
- {
14
- path: '/invoiceShow',
15
- name: 'invoiceShow',
16
- component: invoiceShow,
17
- },
18
- ],
19
- },
20
- {
21
- path: '/404',
22
- name: '404',
23
- component: NotFound,
24
- },
25
- {
26
- path: '/:pathMatch(.*)',
27
- redirect: {
28
- name: '404',
29
- },
30
- },
31
- ]
32
-
33
- export default routes
1
+ import type { RouteRecordRaw } from 'vue-router'
2
+ import PageLayout from '@af-mobile-client-vue3/layout/PageLayout.vue'
3
+ import NotFound from '@af-mobile-client-vue3/views/common/NotFound.vue'
4
+ import invoiceShow from '@af-mobile-client-vue3/views/invoiceShow/index.vue'
5
+
6
+ const routes: Array<RouteRecordRaw> = [
7
+ {
8
+ path: '/',
9
+ name: 'root',
10
+ component: PageLayout,
11
+ redirect: { name: 'Component' },
12
+ children: [
13
+ {
14
+ path: '/invoiceShow',
15
+ name: 'invoiceShow',
16
+ component: invoiceShow,
17
+ },
18
+ ],
19
+ },
20
+ {
21
+ path: '/404',
22
+ name: '404',
23
+ component: NotFound,
24
+ },
25
+ {
26
+ path: '/:pathMatch(.*)',
27
+ redirect: {
28
+ name: '404',
29
+ },
30
+ },
31
+ ]
32
+
33
+ export default routes