Compare commits

...

76 Commits

Author SHA1 Message Date
闵 年泽
224e4578db 增加可配置人员统计页面 2025-02-11 17:22:32 +08:00
闵 年泽
8624b29d37 Merge remote-tracking branch 'remotes/origin/master'
# Conflicts:
#	.gitignore
#	pages/views/zhongheguanli/meeting/index.vue
#	pages/views/zhongheguanli/zhiban/index.vue
2025-02-11 09:02:31 +08:00
闵 年泽
3dd367c216 1 2025-02-11 09:01:27 +08:00
yangzhq68909
aff8d2168a Merge remote-tracking branch 'remotes/origin/ldeyun' into yzqUniapp
# Conflicts:
#	api/renyuan.js
#	manifest.json
#	pages/views/renliziyuan/renyuanxinxi/detail.vue
#	pages/views/renliziyuan/renyuanxinxi/tongji.vue
2025-02-07 10:29:20 +08:00
yangzhq68909
71cdfa3116 修改请假日期判断 2025-02-07 10:26:15 +08:00
8222fdc0a4 完善人员年龄统计模块 2025-02-03 07:24:30 +08:00
yangzhq68909
7d871f7151 Merge remote-tracking branch 'remotes/origin/ldeyun' into yzqUniapp
# Conflicts:
#	.env.development
#	manifest.json
#	package-lock.json
#	pages/views/renliziyuan/renyuanxinxi/taizhang.vue
2025-01-23 18:00:35 +08:00
f50e2fe7ec 完善人员详情,增加考核信息,修改学历数据处理逻辑 2025-01-23 16:58:38 +08:00
闵 年泽
1dbe2fbd07 Merge branch 'ldeyun' into 'master'
Ldeyun

See merge request cxcxt/cxc-szcx-uniapp!9
2025-01-23 09:02:27 +08:00
闵 年泽
d536aaad8a Merge branch 'master' into 'ldeyun'
# Conflicts:
#   pages/login/login.vue
2025-01-23 09:02:12 +08:00
yangzhq68909
ef66d42536 新版本 2025-01-23 08:42:35 +08:00
mnz
3f29785a61 Merge remote-tracking branch 'remotes/origin/ldeyun' into ldeyun
# Conflicts:
#	pages/login/login.vue
#	pages/views/zhongheguanli/zhiban/index.vue
2025-01-23 08:37:57 +08:00
mnz
45aa41d156 Merge remote-tracking branch 'remotes/origin/master' into ldeyun 2025-01-23 08:31:24 +08:00
mnz
3dc869143c 1.修改指标 2025-01-23 08:27:59 +08:00
yangzhq68909
410769873a Merge remote-tracking branch 'remotes/origin/ldeyun' into yzqUniapp
# Conflicts:
#	pages/login/login.vue
2025-01-23 08:18:35 +08:00
yangzhq68909
d650513a5d 1 2025-01-23 08:15:11 +08:00
a5d733a269 Merge branch 'master' of http://10.75.166.171/cxcxt/cxc-szcx-uniapp
# Conflicts:
#	package-lock.json
#	pages/views/renliziyuan/renyuanxinxi/taizhang.vue
#	pages/views/renliziyuan/renyuanxinxi/tongji.vue
2025-01-22 22:29:32 +08:00
yangzhq68909
911c4c365a 流程判断,判断是否是电子签章节点任务,是则显示温馨提示并隐藏审批按钮 2025-01-22 17:03:57 +08:00
yangzhq68909
a04694b724 发布新版本 2025-01-20 15:10:05 +08:00
yangzhq68909
13519318e0 删除人员台账focus 2025-01-17 18:33:30 +08:00
闵 年泽
9474cd3ddf Merge branch 'ldeyun' into 'master'
Ldeyun

See merge request cxcxt/cxc-szcx-uniapp!8
2025-01-17 17:01:06 +08:00
mnz
5cdfd452c7 Merge remote-tracking branch 'remotes/origin/master' into ldeyun
# Conflicts:
#	manifest.json
2025-01-17 17:00:42 +08:00
mnz
8f8a54369d 1.推送 2025-01-17 16:57:51 +08:00
闵 年泽
75b33dd395 Update manifest.json 2025-01-17 16:52:25 +08:00
闵 年泽
c6612d254b Merge branch 'ldeyun' into 'master'
Ldeyun

See merge request cxcxt/cxc-szcx-uniapp!6
2025-01-17 16:37:10 +08:00
闵 年泽
f4d737e827 Merge remote-tracking branch 'remotes/origin/master' into ldeyun
# Conflicts:
#	.env.development
#	.gitignore
#	api/renyuan.js
#	bpm/leaveApplication/index.vue
#	package-lock.json
#	package.json
#	pages.json
#	pages/views/renliziyuan/renyuanxinxi/index.vue
#	pages/views/renliziyuan/renyuanxinxi/taizhang.vue
#	uni_modules/trq-depart-select/components/trq-depart-select/trq-depart-select.vue
2025-01-17 16:36:27 +08:00
闵 年泽
90584edaf9 Squashed commit of the following:
commit 26ee39e9e0
Author: yangzhq68909 <993367776@qq.com>
Date:   Fri Jan 17 13:48:45 2025 +0800

    首页值班跳转路径

commit 0eb5fa4f51
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Jan 13 08:44:08 2025 +0800

    修改流程节点开始结束中文

commit d11c9c13f2
Merge: 5be34bd f5e9d1e
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Jan 13 08:38:33 2025 +0800

    Merge remote-tracking branch 'remotes/origin/master' into yzqUniapp

    # Conflicts:
    #	.gitignore
    #	App.vue
    #	bpm/leaveApplication/index.vue
    #	bpm/supervise.vue
    #	pages.json
    #	uni_modules/uni-data-picker/changelog.md
    #	uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.uvue
    #	uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue
    #	uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.uts
    #	uni_modules/uni-data-picker/package.json
    #	uni_modules/uni-datetime-picker/changelog.md
    #	uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue
    #	uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue
    #	uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue
    #	uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js
    #	uni_modules/uni-datetime-picker/package.json
    #	uni_modules/uni-load-more/changelog.md
    #	uni_modules/uni-load-more/components/uni-load-more/uni-load-more.vue
    #	uni_modules/uni-load-more/package.json
    #	uni_modules/uni-popup/changelog.md
    #	uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue
    #	uni_modules/uni-popup/components/uni-popup/uni-popup.vue
    #	uni_modules/uni-popup/package.json

commit 5be34bd578
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Jan 13 08:24:57 2025 +0800

    将流程信息开始结束节点改成中文

commit f5e9d1e611
Author: ldeyun <ldeyun@163.com>
Date:   Sun Jan 12 18:49:20 2025 +0800

    添加uni-modules组件,departSelect

commit 23e4f9f409
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Jan 7 09:44:59 2025 +0800

    1

commit a472d67520
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Jan 6 10:44:29 2025 +0800

    请假有效日期范围限制

commit 6054db8315
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Dec 16 11:40:20 2024 +0800

    1

commit 157249f2c6
Merge: ed007cb 20ba06b
Author: yangzhq68909 <993367776@qq.com>
Date:   Fri Dec 6 09:03:09 2024 +0800

    Merge remote-tracking branch 'remotes/origin/master' into yzqUniapp

    # Conflicts:
    #	.env.development
    #	.gitignore
    #	manifest.json
    #	pages/login/login.vue
    #	unpackage/cache/apk/apkurl
    #	unpackage/cache/apk/cmManifestCache.json
    #	unpackage/cache/wgt/__UNI__9F097F0/pages/leave/application.css
    #	unpackage/cache/wgt/__UNI__9F097F0/pages/tab/index.css
    #	unpackage/cache/wgt/__UNI__F0AFD30/app-service.js
    #	unpackage/cache/wgt/__UNI__F0AFD30/manifest.json
    #	unpackage/dist/build/app-plus/app-service.js
    #	unpackage/dist/build/app-plus/manifest.json
    #	unpackage/dist/build/app-plus/pages/leave/application.css
    #	unpackage/dist/build/app-plus/pages/login/login.css
    #	unpackage/dist/build/app-plus/pages/tab/index.css
    #	unpackage/dist/build/app-plus/pages/useredit/useredit.css
    #	unpackage/dist/cache/.vite/deps/_metadata.json
    #	unpackage/dist/cache/.vite/deps/base-64.js
    #	unpackage/dist/cache/.vite/deps/base-64.js.map
    #	unpackage/dist/dev/app-plus/app-service.js
    #	unpackage/dist/dev/app-plus/manifest.json

commit ed007cbaf6
Author: yangzhq68909 <993367776@qq.com>
Date:   Fri Dec 6 09:00:15 2024 +0800

    请假获取部门修改

commit 20ba06b4f1
Merge: fe7a52c af4b1b6
Author: jiang <358254771@qq.com>
Date:   Wed Dec 4 17:04:09 2024 +0800

    Merge branch 'master' of 10.75.166.171:cxcxt/cxc-szcx-uniapp

commit fe7a52cfef
Author: jiang <358254771@qq.com>
Date:   Wed Dec 4 17:00:37 2024 +0800

    忽略打包文件

commit 3794abbafc
Author: jiang <358254771@qq.com>
Date:   Wed Dec 4 16:52:44 2024 +0800

    和

commit af4b1b6c0a
Merge: 1ca340b ecc98b1
Author: 闵 年泽 <627844378@qq.com>
Date:   Wed Dec 4 15:37:30 2024 +0800

    Merge branch 'minUniapp' into 'master'

    Min uniapp

    See merge request cxcxt/cxc-szcx-uniapp!2

commit ecc98b14a2
Author: mnz <627844378@qq.com>
Date:   Wed Dec 4 11:10:13 2024 +0800

    修改h5

commit 4c1f42de56
Author: mnz <627844378@qq.com>
Date:   Wed Dec 4 11:05:49 2024 +0800

    1.修改app h5

commit c9ad71fe35
Author: jiang <358254771@qq.com>
Date:   Tue Dec 3 14:08:45 2024 +0800

    发布

commit ba291f2d61
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Dec 3 10:52:17 2024 +0800

    denglu

commit 1ca340b23c
Merge: 27c1637 c1a1127
Author: jiang wen <358254771@qq.com>
Date:   Tue Nov 26 08:45:17 2024 +0800

    Merge branch 'yzqUniapp' into 'master'

    Yzq uniapp

    See merge request cxcxt/cxc-szcx-uniapp!1

commit 0e7e8f3a8d
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Nov 26 08:39:05 2024 +0800

    忽略unpackage文件,jiang

commit a252f9b88b
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Nov 12 16:16:01 2024 +0800

    修改请假页面

commit b2664417e3
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Nov 12 14:42:02 2024 +0800

    1

commit c1a112754c
Author: yangzhq68909 <993367776@qq.com>
Date:   Fri Nov 8 14:17:40 2024 +0800

    1

commit ccfa6e4f11
Author: yangzhq68909 <993367776@qq.com>
Date:   Thu Oct 31 16:38:07 2024 +0800

    页面修改

commit f27c6e4ef0
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Oct 29 15:34:31 2024 +0800

    1

commit ba4d6ac0dd
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Oct 29 08:23:20 2024 +0800

    1

commit 6308621789
Author: yangzhq68909 <993367776@qq.com>
Date:   Fri Oct 25 11:26:14 2024 +0800

    1

commit 4bf243f42b
Author: yangzhq68909 <993367776@qq.com>
Date:   Fri Oct 25 11:02:31 2024 +0800

    增加流程取回、流程作废功能

commit 60e6f2bd2f
Author: yangzhq68909 <993367776@qq.com>
Date:   Thu Oct 24 11:15:16 2024 +0800

    流程签收功能 取消组任务

commit 72e1f6c02f
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Oct 15 08:38:47 2024 +0800

    1

commit e88ce332ed
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Oct 14 15:46:55 2024 +0800

    1

commit 1e857671cb
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Oct 14 15:22:41 2024 +0800

    上传附件及回显

commit 6202ab0f4c
Author: yangzhq68909 <993367776@qq.com>
Date:   Mon Oct 14 08:51:28 2024 +0800

    1

commit e73c24ff15
Author: yangzhq68909 <993367776@qq.com>
Date:   Sat Oct 12 09:14:27 2024 +0800

    11

commit 646c801665
Author: yangzhq68909 <993367776@qq.com>
Date:   Sat Oct 12 08:53:10 2024 +0800

    1

commit 767c647d4a
Author: yangzhq68909 <993367776@qq.com>
Date:   Thu Oct 10 16:52:10 2024 +0800

    1

commit 9a9e8327f6
Author: yangzhq68909 <993367776@qq.com>
Date:   Thu Oct 10 15:32:42 2024 +0800

    1

commit c3eb02f522
Author: yangzhq68909 <993367776@qq.com>
Date:   Sun Sep 29 10:44:16 2024 +0800

    icon修改 修改头像接口修改

commit 33666985b6
Author: yangzhq68909 <993367776@qq.com>
Date:   Fri Sep 27 11:03:07 2024 +0800

    1

commit 8809cc1975
Author: yangzhq68909 <993367776@qq.com>
Date:   Thu Sep 26 12:06:47 2024 +0800

    本地登录页面 请假类型选择

commit f9432900bd
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Sep 24 17:23:37 2024 +0800

    1

commit c9a320ddfd
Author: yangzhq68909 <993367776@qq.com>
Date:   Tue Sep 24 17:21:34 2024 +0800

    请假流程2.0

commit e7bcd4328d
Author: yangzhq68909 <993367776@qq.com>
Date:   Thu Sep 19 16:13:33 2024 +0800

    修改接口

commit 267ba082f0
Author: yangzhq68909 <993367776@qq.com>
Date:   Thu Sep 19 15:12:58 2024 +0800

    修改api接口路径

commit 27c163736d
Author: jiang <358254771@qq.com>
Date:   Sat Sep 14 10:26:50 2024 +0800

    数智产销APP第一版。

commit 14d9997160
Author: jiang wen <358254771@qq.com>
Date:   Sat Sep 14 10:24:54 2024 +0800

    Update README.md

# Conflicts:
#	.env.development
#	.gitignore
#	api/renyuan.js
#	bpm/leaveApplication/index.vue
#	package-lock.json
#	package.json
#	pages.json
#	pages/tab/index.vue
#	pages/views/renliziyuan/renyuanxinxi/index.vue
#	pages/views/renliziyuan/renyuanxinxi/taizhang.vue
#	uni_modules/trq-depart-select/components/trq-depart-select/trq-depart-select.vue
2025-01-17 16:29:01 +08:00
42adfc83d0 人员统计图表页面 2025-01-17 16:00:43 +08:00
yangzhq68909
26ee39e9e0 首页值班跳转路径 2025-01-17 13:48:45 +08:00
yangzhq68909
0eb5fa4f51 修改流程节点开始结束中文 2025-01-13 08:44:08 +08:00
yangzhq68909
d11c9c13f2 Merge remote-tracking branch 'remotes/origin/master' into yzqUniapp
# Conflicts:
#	.gitignore
#	App.vue
#	bpm/leaveApplication/index.vue
#	bpm/supervise.vue
#	pages.json
#	uni_modules/uni-data-picker/changelog.md
#	uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.uvue
#	uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue
#	uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.uts
#	uni_modules/uni-data-picker/package.json
#	uni_modules/uni-datetime-picker/changelog.md
#	uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue
#	uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue
#	uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue
#	uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js
#	uni_modules/uni-datetime-picker/package.json
#	uni_modules/uni-load-more/changelog.md
#	uni_modules/uni-load-more/components/uni-load-more/uni-load-more.vue
#	uni_modules/uni-load-more/package.json
#	uni_modules/uni-popup/changelog.md
#	uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue
#	uni_modules/uni-popup/components/uni-popup/uni-popup.vue
#	uni_modules/uni-popup/package.json
2025-01-13 08:38:33 +08:00
yangzhq68909
5be34bd578 将流程信息开始结束节点改成中文 2025-01-13 08:24:57 +08:00
闵 年泽
f0ae068474 1 2025-01-12 09:39:25 +08:00
闵 年泽
df0e9f3310 Merge remote-tracking branch 'remotes/origin/master' 2025-01-12 09:06:19 +08:00
闵 年泽
a9ddf5324d app 2025-01-12 09:06:05 +08:00
yangzhq68909
23e4f9f409 1 2025-01-07 09:44:59 +08:00
yangzhq68909
a472d67520 请假有效日期范围限制 2025-01-06 10:44:29 +08:00
yangzhq68909
6054db8315 1 2024-12-16 11:40:20 +08:00
yangzhq68909
157249f2c6 Merge remote-tracking branch 'remotes/origin/master' into yzqUniapp
# Conflicts:
#	.env.development
#	.gitignore
#	manifest.json
#	pages/login/login.vue
#	unpackage/cache/apk/apkurl
#	unpackage/cache/apk/cmManifestCache.json
#	unpackage/cache/wgt/__UNI__9F097F0/pages/leave/application.css
#	unpackage/cache/wgt/__UNI__9F097F0/pages/tab/index.css
#	unpackage/cache/wgt/__UNI__F0AFD30/app-service.js
#	unpackage/cache/wgt/__UNI__F0AFD30/manifest.json
#	unpackage/dist/build/app-plus/app-service.js
#	unpackage/dist/build/app-plus/manifest.json
#	unpackage/dist/build/app-plus/pages/leave/application.css
#	unpackage/dist/build/app-plus/pages/login/login.css
#	unpackage/dist/build/app-plus/pages/tab/index.css
#	unpackage/dist/build/app-plus/pages/useredit/useredit.css
#	unpackage/dist/cache/.vite/deps/_metadata.json
#	unpackage/dist/cache/.vite/deps/base-64.js
#	unpackage/dist/cache/.vite/deps/base-64.js.map
#	unpackage/dist/dev/app-plus/app-service.js
#	unpackage/dist/dev/app-plus/manifest.json
2024-12-06 09:03:09 +08:00
yangzhq68909
ed007cbaf6 请假获取部门修改 2024-12-06 09:00:15 +08:00
jiang
20ba06b4f1 Merge branch 'master' of 10.75.166.171:cxcxt/cxc-szcx-uniapp 2024-12-04 17:04:09 +08:00
jiang
fe7a52cfef 忽略打包文件 2024-12-04 17:00:37 +08:00
jiang
3794abbafc 2024-12-04 16:52:44 +08:00
闵 年泽
af4b1b6c0a Merge branch 'minUniapp' into 'master'
Min uniapp

See merge request cxcxt/cxc-szcx-uniapp!2
2024-12-04 15:37:30 +08:00
mnz
ecc98b14a2 修改h5 2024-12-04 11:10:13 +08:00
mnz
4c1f42de56 1.修改app h5 2024-12-04 11:05:49 +08:00
jiang
c9ad71fe35 发布 2024-12-03 14:08:45 +08:00
yangzhq68909
ba291f2d61 denglu 2024-12-03 10:52:17 +08:00
jiang wen
1ca340b23c Merge branch 'yzqUniapp' into 'master'
Yzq uniapp

See merge request cxcxt/cxc-szcx-uniapp!1
2024-11-26 08:45:17 +08:00
yangzhq68909
0e7e8f3a8d 忽略unpackage文件,jiang 2024-11-26 08:39:05 +08:00
yangzhq68909
a252f9b88b 修改请假页面 2024-11-12 16:16:01 +08:00
yangzhq68909
b2664417e3 1 2024-11-12 14:42:02 +08:00
yangzhq68909
c1a112754c 1 2024-11-08 14:17:40 +08:00
yangzhq68909
ccfa6e4f11 页面修改 2024-10-31 16:38:07 +08:00
yangzhq68909
f27c6e4ef0 1 2024-10-29 15:34:31 +08:00
yangzhq68909
ba4d6ac0dd 1 2024-10-29 08:23:20 +08:00
yangzhq68909
6308621789 1 2024-10-25 11:26:14 +08:00
yangzhq68909
4bf243f42b 增加流程取回、流程作废功能 2024-10-25 11:02:31 +08:00
yangzhq68909
60e6f2bd2f 流程签收功能 取消组任务 2024-10-24 11:15:16 +08:00
yangzhq68909
72e1f6c02f 1 2024-10-15 08:38:47 +08:00
yangzhq68909
e88ce332ed 1 2024-10-14 15:46:55 +08:00
yangzhq68909
1e857671cb 上传附件及回显 2024-10-14 15:22:41 +08:00
yangzhq68909
6202ab0f4c 1 2024-10-14 08:51:28 +08:00
yangzhq68909
e73c24ff15 11 2024-10-12 09:14:27 +08:00
yangzhq68909
646c801665 1 2024-10-12 08:53:10 +08:00
yangzhq68909
767c647d4a 1 2024-10-10 16:52:10 +08:00
yangzhq68909
9a9e8327f6 1 2024-10-10 15:32:42 +08:00
yangzhq68909
c3eb02f522 icon修改 修改头像接口修改 2024-09-29 10:44:16 +08:00
yangzhq68909
33666985b6 1 2024-09-27 11:03:07 +08:00
yangzhq68909
8809cc1975 本地登录页面 请假类型选择 2024-09-26 12:06:47 +08:00
yangzhq68909
f9432900bd 1 2024-09-24 17:23:37 +08:00
yangzhq68909
c9a320ddfd 请假流程2.0 2024-09-24 17:21:34 +08:00
yangzhq68909
e7bcd4328d 修改接口 2024-09-19 16:13:33 +08:00
yangzhq68909
267ba082f0 修改api接口路径 2024-09-19 15:12:58 +08:00
jiang
27c163736d 数智产销APP第一版。 2024-09-14 10:26:50 +08:00
jiang wen
14d9997160 Update README.md 2024-09-14 10:24:54 +08:00
65 changed files with 1626 additions and 1035 deletions

View File

@ -1,3 +1,4 @@
# 开发环境
# 请求接口地址
VITE_REQUEST_BASE_URL = https://36.112.48.190
#VITE_REQUEST_BASE_URL = http://10.75.15.247:8080

View File

@ -1,3 +1,4 @@
# 生产环境
# 请求接口地址
VITE_REQUEST_BASE_URL = https://36.112.48.190
#VITE_REQUEST_BASE_URL = https://36.112.48.190
VITE_REQUEST_BASE_URL = http://10.75.15.247:8080

12
.gitignore vendored
View File

@ -32,7 +32,7 @@
/unpackage/cache/wgt/__UNI__9F097F0/pages/useredit/addressbook.css
/unpackage/cache/wgt/__UNI__9F097F0/pages/useredit/useredit.css
/unpackage/cache/wgt/__UNI__9F097F0/pages/userlist/index.css
/unpackage/cache/wgt/__UNI__9F097F0/pages/zhiban/index.css
/unpackage/cache/wgt/__UNI__9F097F0/pages/views/zhongheguanli/zhiban/index.css
/unpackage/dist/build/app-plus/__uniappautomator.js
/unpackage/dist/build/app-plus/__uniappchooselocation.js
/unpackage/dist/build/app-plus/app-config-service.js
@ -53,5 +53,13 @@
/unpackage/dist/dev/app-plus/app.css
/unpackage/dist/dev/app-plus/manifest.json
/unpackage/dist/dev/app-plus/uni-app-view.umd.js
/node_modules/.vite/deps/_metadata.json
/node_modules/.vite/deps/base-64.js
/node_modules/.vite/deps/base-64.js.map
/node_modules/.vite/deps/chunk-RSJERJUL.js
/node_modules/.vite/deps/chunk-RSJERJUL.js.map
/node_modules/.vite/deps/dayjs.js
/node_modules/.vite/deps/dayjs.js.map
/node_modules/.vite/deps/package.json
/uni_modules
/node_modules
/unpackage

View File

@ -27,3 +27,13 @@ export function qjQueryByIdApi(config) { // 通过id查询请假数据 流程用
data: config
})
}
export function queryHisDateApi(username) { // 根据username获取最新请假结束日期
return https({
url: '/CxcQxj/cxcQxj/queryHisDate',
method: 'get',
data: {
username
}
})
}

View File

@ -57,13 +57,14 @@ export function queryZyzgdjByRyLdhth(ldhth) { // 获取人员职业资格等级
})
}
// ryList: '/cxchrygxxtj/cxcHrYgxxtj/list',
// ryByXb: '/cxcRyData/countByXb',
// ryByNl: '/cxcRyData/countByNl',
// ryByXbTotal: '/cxcRyData/countByXbTotal',
// ryByNlTotal: '/cxcRyData/countByNlTotal',
// bmList: '/sys/sysDepart/queryTreeList'
export function queryJxkhByRyLdhth(ldhth) { // 绩效考核信息
return https({
url: '/cxc_rlzy.zb/cxcRlzyZb/listCxcRlzyJxkhByMainId',
method: 'get',
data: ldhth
})
}
export function cxcHrYgxxtj(parm) { // 获取员工信息统计
return https({
@ -73,33 +74,25 @@ export function cxcHrYgxxtj(parm) { // 获取员工信息统计
})
}
export function cxcRyDatacountByXb(parm) { // 通过性别获取员工信息统计
export function cxcRyDataTongji(url, parm) { // 员工信息统计
return https({
url: '/cxcRyData/countByXb',
url: url,
method: 'get',
data: parm
})
}
export function cxcRyDatacountByNl(parm) { // 通过年龄获取员工信息统计
export function cxcRyDatAstatistics(parm) { // 员工分组统计
return https({
url: '/cxcRyData/countByNl',
url: '/cxc_rlzy.zb/cxcRlzyZb/statistics',
method: 'get',
data: parm
})
}
export function cxcRyDatacountByXbTotal(parm) { // 通过性别获取员工信息统计
export function cxcRyDatAstatisticsDetails(parm) { // 员工信息统计
return https({
url: '/cxcRyData/countByXbTotal',
method: 'get',
data: parm
})
}
export function cxcRyDatacountByNlTotal(parm) { // 通过年龄获取员工信息统计
return https({
url: '/cxcRyData/countByNlTotal',
url: '/cxc_rlzy.zb/cxcRlzyZb/details',
method: 'get',
data: parm
})

View File

@ -182,6 +182,14 @@
}).then((res) => {
if (res.success) {
step.value = res.result.records
step.value = step.value.map(item => {
if (item.name === 'start') {
item.name = '开始';
} else if (item.name === 'end') {
item.name = '结束';
}
return item;
});
}
})
}

View File

@ -2,8 +2,8 @@
"name" : "数智产销",
"appid" : "__UNI__9F097F0",
"description" : "",
"versionName" : "1.1.1",
"versionCode" : 20250106,
"versionName" : "1.1.6",
"versionCode" : 20250207,
"transformPx" : false,
/* 5+App */
"app-plus" : {

95
package-lock.json generated Normal file
View File

@ -0,0 +1,95 @@
{
"name": "cxc-szcx-uniapp",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"dependencies": {
"@dcloudio/uni-ui": "^1.5.6",
"base-64": "^1.0.0",
"dayjs": "^1.11.13",
"echarts": "^5.6.0"
}
},
"node_modules/@dcloudio/uni-ui": {
"version": "1.5.6",
"resolved": "https://registry.npmjs.org/@dcloudio/uni-ui/-/uni-ui-1.5.6.tgz",
"integrity": "sha512-jmb98PasFvZkrIDXGh94GbdWg2/jyhgs1HUG+bU8eyL7Ltias/5XBz4q8w9RXyWUfqepJRqapPA2IIQpLCuTIg==",
"license": "Apache-2.0"
},
"node_modules/base-64": {
"version": "1.0.0",
"resolved": "https://registry.npmmirror.com/base-64/-/base-64-1.0.0.tgz",
"integrity": "sha512-kwDPIFCGx0NZHog36dj+tHiwP4QMzsZ3AgMViUBKI0+V5n4U0ufTCUMhnQ04diaRI8EX/QcPfql7zlhZ7j4zgg=="
},
"node_modules/dayjs": {
"version": "1.11.13",
"resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.13.tgz",
"integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg=="
},
"node_modules/echarts": {
"version": "5.6.0",
"resolved": "https://registry.npmmirror.com/echarts/-/echarts-5.6.0.tgz",
"integrity": "sha512-oTbVTsXfKuEhxftHqL5xprgLoc0k7uScAwtryCgWF6hPYFLRwOUHiFmHGCBKP5NPFNkDVopOieyUqYGH8Fa3kA==",
"license": "Apache-2.0",
"dependencies": {
"tslib": "2.3.0",
"zrender": "5.6.1"
}
},
"node_modules/tslib": {
"version": "2.3.0",
"resolved": "https://registry.npmmirror.com/tslib/-/tslib-2.3.0.tgz",
"integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg==",
"license": "0BSD"
},
"node_modules/zrender": {
"version": "5.6.1",
"resolved": "https://registry.npmmirror.com/zrender/-/zrender-5.6.1.tgz",
"integrity": "sha512-OFXkDJKcrlx5su2XbzJvj/34Q3m6PvyCZkVPHGYpcCJ52ek4U/ymZyfuV1nKE23AyBJ51E/6Yr0mhZ7xGTO4ag==",
"license": "BSD-3-Clause",
"dependencies": {
"tslib": "2.3.0"
}
}
},
"dependencies": {
"@dcloudio/uni-ui": {
"version": "1.5.6",
"resolved": "https://registry.npmjs.org/@dcloudio/uni-ui/-/uni-ui-1.5.6.tgz",
"integrity": "sha512-jmb98PasFvZkrIDXGh94GbdWg2/jyhgs1HUG+bU8eyL7Ltias/5XBz4q8w9RXyWUfqepJRqapPA2IIQpLCuTIg=="
},
"base-64": {
"version": "1.0.0",
"resolved": "https://registry.npmmirror.com/base-64/-/base-64-1.0.0.tgz",
"integrity": "sha512-kwDPIFCGx0NZHog36dj+tHiwP4QMzsZ3AgMViUBKI0+V5n4U0ufTCUMhnQ04diaRI8EX/QcPfql7zlhZ7j4zgg=="
},
"dayjs": {
"version": "1.11.13",
"resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.13.tgz",
"integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg=="
},
"echarts": {
"version": "5.6.0",
"resolved": "https://registry.npmmirror.com/echarts/-/echarts-5.6.0.tgz",
"integrity": "sha512-oTbVTsXfKuEhxftHqL5xprgLoc0k7uScAwtryCgWF6hPYFLRwOUHiFmHGCBKP5NPFNkDVopOieyUqYGH8Fa3kA==",
"requires": {
"tslib": "2.3.0",
"zrender": "5.6.1"
}
},
"tslib": {
"version": "2.3.0",
"resolved": "https://registry.npmmirror.com/tslib/-/tslib-2.3.0.tgz",
"integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg=="
},
"zrender": {
"version": "5.6.1",
"resolved": "https://registry.npmmirror.com/zrender/-/zrender-5.6.1.tgz",
"integrity": "sha512-OFXkDJKcrlx5su2XbzJvj/34Q3m6PvyCZkVPHGYpcCJ52ek4U/ymZyfuV1nKE23AyBJ51E/6Yr0mhZ7xGTO4ag==",
"requires": {
"tslib": "2.3.0"
}
}
}
}

View File

@ -230,7 +230,15 @@
{
"path": "pages/views/renliziyuan/renyuanxinxi/tongji",
"style": {
"navigationBarTitleText": "人员统计信息",
"navigationBarTitleText": "人员年龄分组统计信息",
"navigationBarTextStyle": "white"
}
},
{
"path": "pages/views/renliziyuan/renyuanxinxi/qttongji",
"style": {
"navigationBarTitleText": "其他统计信息",
"navigationBarTextStyle": "white"
}

View File

@ -109,7 +109,8 @@
} from '@/api/api.js';
import {
qjAddApi,
queryZwmcAndExaApi
queryZwmcAndExaApi,
queryHisDateApi
} from '@/api/pages.js';
import {
queryDepByCode,
@ -177,7 +178,7 @@
}
onLoad(() => {
loadData()
getTomorrowDate()
// getTomorrowDate()
})
const select = (e) => {
@ -274,21 +275,39 @@
proxy.$toast(res.message);
}
})
queryHisDateApi(store.userinfo.username).then((res) => { //
if (res) {
console.log('--0', res)
getTomorrowDate(res);
} else {
console.log('--1', res)
getTomorrowDate();
}
})
}
const bindType = (e) => {
typeIndex.value = e.detail.value
}
const getTomorrowDate = () => {
let today = new Date();
let tomorrow = new Date(today);
tomorrow.setDate(today.getDate() + 1);
// yyyy-mm-dd
let year = tomorrow.getFullYear();
let month = String(tomorrow.getMonth() + 1).padStart(2, '0'); // 01
let day = String(tomorrow.getDate()).padStart(2, '0');
beginTime.value = year + '-' + month + '-' + day;
const getTomorrowDate = (e) => {
let tomorrow;
if (e) {
// Date
const dateParts = e.split('-').map(Number);
tomorrow = new Date(dateParts[0], dateParts[1] - 1, dateParts[2]);
} else {
// 使
tomorrow = new Date();
}
//
tomorrow.setDate(tomorrow.getDate() + 1);
//
const year = tomorrow.getFullYear();
const month = (tomorrow.getMonth() + 1).toString().padStart(2, '0');
const day = tomorrow.getDate().toString().padStart(2, '0');
beginTime.value = `${year}-${month}-${day}`;
}
</script>

View File

@ -1,212 +0,0 @@
<template>
<view :class="['content',{'gray':store.isgray==1}]">
<view class="list_box">
<view class="list">
<view class="title f-row aic jcb">
<view class="">
年度部门讨论会议
</view>
<text>1分钟前</text>
</view>
<view class="info">
<view class="f-row aic jcb">
<view class="">
会议状态
</view>
<text>待开始/已开始/已结束</text>
</view>
<view class="f-row aic jcb">
<view class="">
发起人
</view>
<text>周如意</text>
</view>
<view class="f-row aic jcb">
<view class="">
会议日期
</view>
<text>周如意</text>
</view>
<view class="f-row aic jcb">
<view class="">
会议地点
</view>
<text>周如意</text>
</view>
<view class="f-row aic jcb">
<view class="">
会议内容
</view>
<text>周如意</text>
</view>
<view class="">
<view class="">
参与人员
</view>
<view class="person f-row aic">
<view class="item f-col aic" v-for="item,i in 7" :key="i">
<image src="" mode=""></image>
<view class="name">
周如意
</view>
</view>
</view>
</view>
</view>
</view>
</view>
<view class="btn f-row aic jcb">
<view class="refuse">
拒绝
</view>
<view class="agree" @click="openpop">
同意
</view>
</view>
</view>
</template>
<script setup>
import {
ref
} from 'vue';
import {
huiyiDetailApi
} from '@/api/api.js';
import {
onLoad
} from '@dcloudio/uni-app';
import {
useStore
} from '@/store'
const store = useStore()
onLoad(() => {
huiyiDetail()
})
const huiyiDetail = () => {
huiyiDetailApi({
mainid:1
}).then((res) => {
if (res.success) {
}
}).catch((err) => {
console.log(err);
})
}
</script>
<style lang="scss" scoped>
.content{
padding-bottom: 120rpx;
}
.btn {
position: fixed;
bottom: 0;
width: 690rpx;
height: 120rpx;
background: #FFFFFF;
padding: 0 30rpx;
border-top: 1px solid #EFEFEF;
view {
width: 330rpx;
height: 88rpx;
font-size: 28rpx;
border-radius: 16rpx;
text-align: center;
line-height: 88rpx;
}
.refuse {
box-sizing: border-box;
background: #FFFFFF;
border: 2rpx solid #01508B;
color: #01508B;
}
.agree {
background: #01508B;
color: #FFFFFF;
}
}
.list_box {
.list {
padding: 30rpx;
margin-bottom: 30rpx;
.title {
border-bottom: 1px solid #efefef;
padding-bottom: 24rpx;
margin-bottom: 8rpx;
view {
font-size: 28rpx;
color: #333333;
}
text {
font-size: 28rpx;
color: #999999;
}
}
.info {
font-size: 28rpx;
color: #666666;
view {
padding-top: 16rpx;
font-size: 28rpx;
color: #666666;
}
text{
font-size: 28rpx;
color: #333333;
}
.person{
flex-wrap: wrap;
.item{
width: 16.66%;
}
image{
width: 78rpx;
height: 78rpx;
border-radius: 38rpx;
background-color: #01508B;
}
}
}
.btn {
margin-top: 30rpx;
view {
width: 300rpx;
height: 64rpx;
border-radius: 8rpx;
font-size: 28rpx;
text-align: center;
line-height: 64rpx;
}
.entrust {
background: #FFFFFF;
border: 2rpx solid #01508B;
box-sizing: border-box;
color: #01508B;
}
.handle {
background: #01508B;
color: #FFFFFF;
}
}
}
}
</style>

View File

@ -1,247 +0,0 @@
<template>
<view :class="{'gray':store.isgray==1}">
<customNav>
<view class="nav_box f-row aic jcb">
<view class="back f-row aic" @click="back">
<uni-icons type="left" size="20" color="#fff"></uni-icons>
</view>
<view class="search f-row aic">
<input type="text" v-model="searchKey" @confirm="search" @blur="showicon=true&&!searchKey"
@focus="showicon=false" />
<view class="f-row aic" v-if="showicon">
<image src="../../static/search.png" mode=""></image>
<text>搜索</text>
</view>
</view>
</view>
</customNav>
<view class="list_box">
<view class="list" v-for="item,i in 3" :key="i" @click="jump(`/pages/meeting/detail?id=1`)">
<view class="title f-row aic jcb">
<view class="">
年度部门讨论会议
</view>
<text>1分钟前</text>
</view>
<view class="info">
<view class="f-row aic jcb">
<view class="">
发起人
</view>
<text>周如意</text>
</view>
<view class="f-row aic jcb">
<view class="">
会议日期
</view>
<text>周如意</text>
</view>
<view class="f-row aic jcb">
<view class="">
会议地点
</view>
<text>周如意</text>
</view>
<view class="f-row aic jcb">
<view class="">
会议内容
</view>
<text>周如意</text>
</view>
</view>
<!-- <view class="btn f-row aic jcb">
<view class="entrust">
拒绝
</view>
<view class="handle">
同意
</view>
</view> -->
<view class="handled f-row">
<view class="refused">
已拒绝
</view>
<!-- <view class="agreed">
已同意
</view> -->
</view>
</view>
</view>
</view>
</template>
<script setup>
import {
ref
} from 'vue';
import {
useStore
} from '@/store'
const store = useStore()
import {
huiyilistApi
} from '@/api/api.js';
import customNav from '../../bpm/customNav.vue';
import {
onLoad
} from '@dcloudio/uni-app';
import {
beforeJump
} from '@/utils/index.js';
const showicon = ref(true)
const searchKey = ref('')
onLoad(() => {
// huiyilist()
})
const huiyilist = () => {
huiyilistApi().then((res) => {
if (res.success) {
}
}).catch((err) => {
console.log(err);
})
}
const jump = (url) => {
beforeJump(url, () => {
uni.navigateTo({
url
})
})
}
const back = () => {
uni.navigateBack()
}
</script>
<style lang="scss" scoped>
.nav_box {
position: absolute;
bottom: 14rpx;
width: 100%;
left: 0;
}
.back {
padding: 0 30rpx;
}
.search {
position: relative;
padding-right: 30rpx;
flex: 1;
view {
position: absolute;
left: 28rpx;
top: 50%;
transform: translateY(-50%);
font-size: 28rpx;
color: #999999;
}
input {
flex: 1;
height: 72rpx;
background: #F8F8F8;
border-radius: 44rpx;
padding: 0 28rpx;
}
image {
width: 34rpx;
height: 34rpx;
margin-right: 16rpx;
}
}
.list_box {
padding: 14rpx 30rpx 0 30rpx;
margin-top: 24rpx;
.list {
background: #FFFFFF;
box-shadow: 0rpx 2rpx 4rpx 0rpx rgba(0, 0, 0, 0.5);
border-radius: 16rpx;
padding: 30rpx;
margin-bottom: 30rpx;
.title {
border-bottom: 1px solid #efefef;
padding-bottom: 24rpx;
margin-bottom: 8rpx;
view {
font-size: 28rpx;
color: #333333;
}
text {
font-size: 28rpx;
color: #999999;
}
}
.info {
font-size: 28rpx;
color: #666666;
view {
padding-top: 16rpx;
}
}
.btn {
margin-top: 30rpx;
view {
width: 300rpx;
height: 64rpx;
border-radius: 8rpx;
font-size: 28rpx;
text-align: center;
line-height: 64rpx;
}
.entrust {
background: #FFFFFF;
border: 2rpx solid #01508B;
box-sizing: border-box;
color: #01508B;
}
.handle {
background: #01508B;
color: #FFFFFF;
}
}
}
}
.refused {
color: #333333;
}
.agreed {
color: #01508B;
}
.handled {
justify-content: flex-end;
margin-top: 30rpx;
view {
width: 150rpx;
height: 64rpx;
background: #EFEFEF;
border-radius: 8rpx;
text-align: center;
line-height: 64rpx;
font-size: 28rpx;
}
}
</style>

View File

@ -20,7 +20,9 @@
</view>
</customNav>
<component :is="comp" :dataId="dataId"></component>
<view class="btn f-row aic jcb" v-if="type == 0">
<view v-if="ifShow" style="display: block; margin: 10px;">
温馨提示:目前APP暂不支持电子签章审批,请登录PC端厂综合管理平台(https://10.75.166.6),-</view>
<view class="btn f-row aic jcb" v-if="type == 0 && !ifShow">
<view class="refuse" @click="openpop(1)">
拒绝
</view>
@ -28,7 +30,6 @@
同意
</view>
</view>
<uni-popup ref="popup" type="center">
<view class="popup">
<view class="title">
@ -110,6 +111,7 @@
}
const comp = ref(null)
const dataId = ref('')
const ifShow = ref(false) //20250122
const getProcessNodeInfo = (taskId) => {
getProcessNodeInfoApi({
taskId
@ -149,6 +151,7 @@
}
}
}
/**流程办理接口*/
const processComplete = (params) => {
processCompleteApi({
@ -165,7 +168,6 @@
})
}
/**审批流程节点*/
const stepNode = ref([])
/**当前选择的节点*/
@ -185,6 +187,7 @@
}
})
}
/**历史任务详情*/
const getHisProcessNodeInfo = (procInstId) => {
getHisProcessNodeInfoApi({
@ -196,6 +199,18 @@
}
})
}
/**判断是否是电子签章节点任务,是则显示温馨提示并隐藏审批按钮*/
const getIfShow = () => {
if (taskInfo.value.taskId == 'task1705482211321' || taskInfo.value.taskId == 'task1705482639673' ||
taskInfo.value.taskId == 'task1714092890849' || taskInfo.value.taskId == 'task1714092955682' ||
taskInfo.value.taskId == 'task1689151174324' || taskInfo.value.taskId == 'task1677809773570' ||
taskInfo.value.taskId == 'task1689579219152')
{ //
ifShow.value = true;
} else {
ifShow.value = false;
}
}
const taskInfo = ref(null)
let type = null
onLoad((options) => {
@ -207,6 +222,8 @@
getProcessNodeInfo(taskInfo.value.id)
getProcessTaskTransInfo()
getIfShow()
})
</script>
<style>

View File

@ -4,6 +4,45 @@
<view style="padding: 10px 10px 10px 10px;">
<uni-title title="基本信息" type="h1" color="blue"></uni-title>
<yjly-row-cell :cellData="cellData" :rowDataCount="3"></yjly-row-cell>
<uni-title title="年度绩效考核" type="h1" color="blue"></uni-title>
<uni-row>
<uni-col :span="4">
<view class="titleStyle">
序号
</view>
</uni-col>
<uni-col :span="10">
<view class="titleStyle">
绩效考核年份
</view>
</uni-col>
<uni-col :span="10">
<view class="titleStyle">
绩效考核成绩
</view>
</uni-col>
</uni-row>
<uni-row>
<view v-for="(item,index) in jxkhxxList">
<uni-col :span="4">
<view class="dataStyle">
{{index+1}}
</view>
</uni-col>
<uni-col :span="10">
<view class="dataStyle">
{{item.nf}}
</view>
</uni-col><uni-col :span="10">
<view class="dataStyle">
{{item.khcj+"---"+item.khcj_dictText}}
</view>
</uni-col>
</view>
</uni-row>
<uni-title title="工作简历" type="h1" color="blue"></uni-title>
<uni-row>
<uni-col :span="4">
@ -248,7 +287,8 @@
queryJtzycyByRyLdhth,
queryXlxxByRyLdhth,
queryGbxxByRyLdhth,
queryZyzgdjByRyLdhth
queryZyzgdjByRyLdhth,
queryJxkhByRyLdhth
} from '@/api/renyuan.js'
import {
useStore
@ -268,10 +308,22 @@
const xlxxList = ref([]) // -
const gbxxList = ref([]) // -
const zyzgdjList = ref([]) // -
const jxkhxxList = ref([]) // -
function getChildTable() {
console.log(ldhth.value)
queryJxkhByRyLdhth({
"ldhth": ldhth.value
}).then((res) => {
// console.log(res);
jxkhxxList.value = res.result.records
// console.log(jxkhxxList.value)
}).catch((err) => {
console.log(err);
})
queryGbxxByRyLdhth({
"ldhth": ldhth.value
}).then((res) => {
@ -327,20 +379,29 @@
xlxxList.value = []
if (res.result.records.length > 0) {
var rress = res.result.records
// console.log(rress);
for (let i = 0; i < rress.length; i++) {
if (rress[i].onexl == 1) {
if (rress[i].onexl == 1 & rress[i].zgxl == 1) {
rress[i].xllb = "第一学历"
xlxxList.value.push(JSON.parse(JSON.stringify(rress[i])))
// console.log(xlxxList.value)
rress[i].xllb = "最高学历"
xlxxList.value.push(JSON.parse(JSON.stringify(rress[i])))
// console.log(xlxxList.value)
}
if (rress[i].onexl == 1 & rress[i].zgxl != 1) {
rress[i].xllb = "第一学历"
xlxxList.value.push(rress[i])
}
if (rress[i].zgxl == 1) {
if (rress[i].onexl != 1 & rress[i].zgxl == 1) {
rress[i].xllb = "最高学历"
xlxxList.value.push(rress[i])
}
}
}
console.log(xlxxList.value);
}
}
}).catch((err) => {
console.log(err);
@ -517,7 +578,9 @@
vertical-align: middle;
border-bottom: 1px solid #919191;
border-left: 1px solid #919191;
text-overflow: ellipsis;
text-align: center;
word-wrap: break-word;
overflow-wrap: break-word;
}
</style>

View File

@ -8,10 +8,13 @@
</uni-section>
<uni-section title="统计信息" type="line">
<uni-card :is-shadow="false">
<button type="primary" @click="toTongji">分类统计</button>
<button type="primary" @click="toTongji">年龄段统计</button>
</uni-card>
<uni-card :is-shadow="false">
<button type="primary" @click="toQtTongji">其他统计</button>
</uni-card>
</uni-section>
</uni-card>
</view>
@ -29,6 +32,12 @@
url: "/pages/views/renliziyuan/renyuanxinxi/tongji"
})
}
function toQtTongji() {
uni.navigateTo({
url: "/pages/views/renliziyuan/renyuanxinxi/qttongji"
})
}
</script>
<style>

View File

@ -0,0 +1,348 @@
<template>
<view>
<view class="container" id="top1">
<uni-row style="margin-bottom: 10rpx;margin-left: 30rpx;margin-right: 30rpx;">
<uni-col :span="24"><uni-title :title="'所选单位ID'" align="left" type="h4"></uni-title></uni-col>
</uni-row>
<uni-row style="margin-bottom: 20rpx;margin-left: 30rpx;margin-right: 30rpx;">
<uni-col :span="24">
<trq-depart-select v-model="selectedOrgCode" returnCodeOrID="orgCode"
@change="onOrgCodeChange"></trq-depart-select>
</uni-col>
</uni-row>
<uni-row style="margin-bottom: 20rpx;margin-left: 30rpx;margin-right: 30rpx;">
<uni-col :span="24">
<picker mode="selector" :range="fieldList" range-key="label" @change="onFieldChange">
<view class="picker">选择字段: {{ selectedFieldLabel }}</view>
</picker>
</uni-col>
</uni-row>
</view>
<!-- ECharts图表 -->
<view class="chart-container">
<l-echart ref="chart" @finished="initChart" @tap="onChartClick" />
</view>
<!-- 数据表格 -->
<uni-row style="margin-top: 10px; margin-left: 30rpx;margin-right: 30rpx;" v-if="personnelList.length>0">
<uni-col :span="3">
<view class="titleStyle">
序号
</view>
</uni-col>
<uni-col :span="5">
<view class="titleStyle">
姓名
</view>
</uni-col>
<uni-col :span="5">
<view class="titleStyle">
性别
</view>
</uni-col>
<uni-col :span="5">
<view class="titleStyle">
年龄
</view>
</uni-col>
<uni-col :span="6">
<view class="titleStyle">
操作
</view>
</uni-col>
</uni-row>
<scroll-view scroll-y :style="{height: bottomHeight + 'px' }">
<uni-row style="margin-bottom: 10rpx;margin-left: 30rpx;margin-right: 30rpx;">
<view v-for="(item,index) in personnelList">
<uni-col :span="3">
<view class="dataStyle">
{{index+1}}
</view>
</uni-col>
<uni-col :span="5">
<view class="dataStyle">
{{item.xm}}
</view>
</uni-col><uni-col :span="5">
<view class="dataStyle">
{{item.xb_dictText}}
</view>
</uni-col><uni-col :span="5">
<view class="dataStyle">
{{item.nl}}
</view>
</uni-col>
<uni-col :span="6">
<view class="dataStyle">
<button size="mini" type="primary" @click="detail(item)">详情</button>
</view>
</uni-col>
</view>
</uni-row>
</scroll-view>
</view>
</template>
<script setup>
import {
ref,
reactive,
onMounted
} from 'vue';
import * as echarts from 'echarts';
import {
cxcRyDatAstatistics,
cxcRyDatAstatisticsDetails
} from '@/api/renyuan.js';
// tableData
const bottomHeight = ref(0);
//
const chart = ref(null);
const fieldList = ref([{
label: '性别',
value: 'xb'
},
{
label: '年龄',
value: 'nl'
},
{
label: '学历',
value: 'whcd1'
},
]); //
const selectedOrgCode = ref(''); // orgCode
const selectedOrgCodeLabel = ref('请选择单位'); //
const selectedField = ref(''); //
const selectedFieldLabel = ref('请选择字段'); //
const chartData = ref({}); //
const personnelList = ref([]); // initChart
const chartOption = ref({
tooltip: {
trigger: 'axis',
axisPointer: {
type: 'shadow',
},
},
xAxis: {
type: 'category',
data: [],
},
yAxis: {
type: 'value',
},
series: [{
name: '数量',
type: 'bar',
data: [],
}, ],
})
function detail(record) {
// console.log(record)
uni.navigateTo({
url: "/pages/views/renliziyuan/renyuanxinxi/detail?data=" + encodeURIComponent(JSON.stringify(record))
})
}
onMounted(() => {
// #ifdef APP
getHeight();
// #endif
})
// #ifdef APP
const getHeight = () => {
//
const systemInfo = uni.getSystemInfoSync();
const screenHeight = systemInfo.screenHeight;
//
const query = uni.createSelectorQuery();
//
query
.select('#top1')
.boundingClientRect((rect1) => {
//
const topComponentsHeight = rect1.height
//
bottomHeight.value = screenHeight - topComponentsHeight - 415;
})
.exec();
};
// #endif
// ECharts length departChange
//
const initChart = () => {
setTimeout(async () => {
if (!chart.value) return
const myChart = await chart.value.init(echarts)
myChart.setOption(chartOption.value)
}, 300)
};
//
const updateChart = () => {
if (!chart) return;
const {
xb,
number
} = chartData.value;
chart.setOption({
xAxis: {
data: xb,
},
series: [{
data: number,
}, ],
});
};
//
const fetchStatisticsData = async () => {
if (!selectedOrgCode.value || !selectedField.value) return;
try {
const res = await cxcRyDatAstatistics({
orgCode: selectedOrgCode.value,
field: selectedField.value,
});
console.log(res)
chartData.value = res.data;
updateChart();
} catch (error) {
console.error('获取统计数据失败:', error);
}
};
// delimiter
const fetchPersonnelList = async (ldhthList) => {
try {
const res = await cxcRyDatAstatisticsDetails({
ldhth: ldhthList
});
console.log(res)
personnelList.value = res.data;
} catch (error) {
console.error('获取人员列表失败:', error);
}
};
//
const onOrgCodeChange = (e) => {
console.log(e)
selectedOrgCode.value = e;
fetchStatisticsData();
};
const onFieldChange = (e) => {
const index = e.detail.value;
selectedField.value = fieldList.value[index].value;
selectedFieldLabel.value = fieldList.value[index].label;
fetchStatisticsData();
};
const onChartClick = (e) => {
const {
ldhth
} = chartData.value;
if (ldhth && ldhth.length > 0) {
fetchPersonnelList(ldhth);
}
};
</script>
<style scoped>
.container {
margin: 20, 20, 20, 20rpx;
}
.input-group {
display: flex;
gap: 20rpx;
margin-bottom: 30rpx;
}
.input {
flex: 1;
border: 1rpx solid #ddd;
padding: 15rpx;
border-radius: 8rpx;
}
.query-btn {
background: #007AFF;
color: white;
padding: 0 40rpx;
border-radius: 8rpx;
}
.stats-box {
display: flex;
justify-content: space-around;
margin: 30rpx 0;
padding: 20rpx;
background: #f8f8f8;
border-radius: 12rpx;
}
.stat-item {
display: flex;
flex-direction: column;
align-items: center;
}
.label {
font-size: 24rpx;
color: #666;
}
.value {
font-size: 36rpx;
font-weight: bold;
color: #0000ff;
}
.chart-container {
height: 400rpx;
margin-top: 20rpx;
}
.titleStyle {
font-size: 12px;
color: #747474;
line-height: 30px;
height: 30px;
background: #F2F9FC;
text-align: center;
vertical-align: middle;
border-left: 1px solid #919191;
border-bottom: 1px solid #919191;
;
}
/* 内容样式 */
.dataStyle {
max-font-size: 14px;
/* 最大字体限制 */
min-font-size: 10px;
/* 最小字体限制 */
font-size: 12px;
color: #00007f;
line-height: 30px;
height: 30px;
font-weight: 500;
text-align: center;
vertical-align: middle;
border-bottom: 1px solid #919191;
border-left: 1px solid #919191;
text-overflow: ellipsis;
}
</style>

View File

@ -1,8 +1,7 @@
<template>
<view>
<scroll-view :scroll-y="true">
<scroll-view :scroll-y="true" style="height: 100vh;">
<uni-card>
<uni-title title="" type="h1" align="center"></uni-title>
<view>
<uni-row>
<uni-col :span="11"><uni-title title="姓名 " align="left" type="h5"></uni-title></uni-col>
@ -10,10 +9,10 @@
type="h5"></uni-title></uni-col>
</uni-row>
<uni-row>
<uni-col :span="11"><uni-easyinput v-model="xm" focus suffixIcon="search" clearable
<uni-col :span="11"><uni-easyinput v-model="xm" suffixIcon="search" clearable
placeholder="姓名模糊查询" @change="Search" @iconClick="Search" /></uni-col>
<uni-col :span="11" :push="2">
<uni-easyinput v-model="ldhth" focus suffixIcon="search" clearable placeholder="劳动合同号模糊查询"
<uni-easyinput v-model="ldhth" suffixIcon="search" clearable placeholder="劳动合同号模糊查询"
@change="Search" @iconClick="Search" />
</uni-col>
</uni-row>
@ -24,7 +23,8 @@
</uni-row>
<uni-row>
<uni-col :span="24">
<trq-depart-select returnCodeOrID="orgCode" @change="departChange"></trq-depart-select>
<trq-depart-select v-model="departID" returnCodeOrID="orgCode"
@change="departChange"></trq-depart-select>
</uni-col>
</uni-row>
</view>
@ -34,6 +34,9 @@
:border="true" :data="ryDataList" @detail="detail"></zb-table>
<uni-pagination :current="current" :pagerCount="pages" :total="total" prev-text="前一页" next-text="后一页"
:show-icon="false" @change="pagechange" />
<view>
<text class="example-info">当前页{{ current }}数据总量{{ total }}每页数据{{ pageSize }}</text>
</view>
</uni-card>
</scroll-view>
@ -97,12 +100,6 @@
width: 70,
align: 'center'
},
// {
// name: 'gzdw',
// label: '',
// align: 'center',
// width: 150
// },
{
name: 'xb_dictText',
label: '性别',
@ -118,6 +115,7 @@
{
name: 'operation',
type: 'operation',
width: 60,
fixed: true,
label: '操作',
align: 'center',
@ -139,7 +137,6 @@
function detail(record) {
// console.log(record)
uni.navigateTo({
url: "/pages/views/renliziyuan/renyuanxinxi/detail?data=" + encodeURIComponent(JSON.stringify(record))
})
@ -148,29 +145,47 @@
function pagechange(e) {
current.value = e.current
pageNo.value = e.current
getRenyuanByDepID()
}
function departChange(e) {
departID.value = e
getRenyuanByDepID()
}
function getRenyuanByDepID() {
ryDataList.value = []
let queryParm = {
let params = {
pageNo: pageNo.value,
pageSize: pageSize.value,
current: current.value
};
queryParm.orgCode = departID.value
if (departID.value.length <= 9) {
params.orgCode = departID.value
} else {
params.jcxd_code = departID.value
}
getRenyuanByDepID(params)
}
function departChange(e, data) {
departID.value = e
let params = {
pageNo: pageNo.value,
pageSize: pageSize.value,
current: current.value
};
console.log(e)
if (e.length <= 9) {
params.orgCode = departID.value
} else {
params.jcxd_code = departID.value
}
getRenyuanByDepID(params)
}
function getRenyuanByDepID(queryParm) {
ryDataList.value = []
console.log(queryParm)
queryRenyuanByDepartID(queryParm).then((res) => {
console.log(res)
if (res.success) {
ryDataList.value = res.result.records
total.value = res.result.total
pages.value = res.result.pages
current.value = res.result.current
}
}).catch((err) => {
console.log(err);
@ -192,6 +207,7 @@
if (ldhth.value !== '') {
queryParm.ldhth = '*' + ldhth.value + '*';
}
console.log(queryParm)
queryRenyuanByDepartID(queryParm).then((res) => {
if (res.success) {
ryDataList.value = res.result.records

View File

@ -1,273 +1,563 @@
<template>
<view>
<uni-card>
<uni-forms>
<uni-forms-item>
<view class="container" id="top1">
<uni-row style="margin-bottom: 10rpx;margin-left: 30rpx;margin-right: 30rpx;">
<uni-col :span="24"><uni-title :title="'所选单位ID:'+orgCode" align="left" type="h4"></uni-title></uni-col>
</uni-row>
<uni-row style="margin-bottom: 20rpx;margin-left: 30rpx;margin-right: 30rpx;">
<uni-col :span="24">
<trq-depart-select v-model="orgCode" returnCodeOrID="orgCode"
@change="departChange"></trq-depart-select>
</uni-col>
</uni-row>
<!-- 概览统计 -->
<view class="stats-box" v-if="summary.total">
<view class=" stat-item">
<text class="label">总人数</text>
<text class="value">{{ summary.total }}</text>
</view>
<view class="stat-item">
<text class="label">平均年龄</text>
<text class="value">{{ summary.avgAge.toFixed(1) }}</text>
</view>
</view>
</view>
<!-- ECharts图表 -->
<view class="chart-container">
<l-echart ref="chart" @finished="initChart" />
</view>
</uni-forms-item>
</uni-forms>
<uni-title title="所属单位 " align="center"></uni-title>
<trq-depart-select returnCodeOrID="orgCode" @change="departChange"></trq-depart-select>
<!-- 数据表格 -->
<uni-row style="margin-top: 10px; margin-left: 30rpx;margin-right: 30rpx;" v-if="tableData.length>0">
<uni-col :span="3">
<view class="titleStyle">
序号
</view>
</uni-col>
<uni-col :span="5">
<view class="titleStyle">
姓名
</view>
</uni-col>
<uni-col :span="5">
<view class="titleStyle">
性别
</view>
</uni-col>
<uni-col :span="5">
<view class="titleStyle">
年龄
</view>
</uni-col>
<uni-col :span="6">
<view class="titleStyle">
操作
</view>
</uni-col>
</uni-row>
<scroll-view scroll-y :style="{height: bottomHeight + 'px' }">
<uni-row style="margin-bottom: 10rpx;margin-left: 30rpx;margin-right: 30rpx;">
<view v-for="(item,index) in tableData">
<uni-col :span="3">
<view class="dataStyle">
{{index+1}}
</view>
</uni-col>
<uni-col :span="5">
<view class="dataStyle">
{{item.xm}}
</view>
</uni-col><uni-col :span="5">
<view class="dataStyle">
{{item.xb_dictText}}
</view>
</uni-col><uni-col :span="5">
<view class="dataStyle">
{{item.nl}}
</view>
</uni-col>
<uni-col :span="6">
<view class="dataStyle">
<button size="mini" type="primary" @click="detail(item)">详情</button>
</view>
</uni-col>
</view>
<uni-row>
<uni-col :span="6"><button @click="getRyByxb(0)" type="primary" size="mini"
style="margin: 10px 10px 10px 10px;">性别分组统计</button></uni-col>
<uni-col :span="6"><button @click="getRyBynl(0)" type="primary" size="mini"
style="margin: 10px 10px 10px 10px;">年龄分组统计</button></uni-col>
<uni-col :span="6"><button @click="getRyByxb(1)" type="primary" size="mini"
style="margin: 10px 10px 10px 10px;">性别总统计</button></uni-col>
<uni-col :span="6"><button @click="getRyBynl(1)" type="primary" size="mini"
style="margin: 10px 10px 10px 10px;">年龄总统计</button></uni-col>
</uni-row>
<view style="width:750rpx; height:750rpx"><l-echart ref="myChart" @finished="init"></l-echart></view>
</uni-card>
</scroll-view>
</view>
</template>
<script setup>
import * as echarts from 'echarts'
import {
onReady,
onLoad
} from '@dcloudio/uni-app';
import {
reactive,
ref,
reactive,
onMounted
} from 'vue';
import * as echarts from 'echarts'
import {
useStore
} from '@/store';
import {
cxcRyDatacountByXb,
cxcRyDatacountByNl,
cxcRyDatacountByXbTotal,
cxcRyDatacountByNlTotal
queryRenyuanByDepartID
} from '@/api/renyuan.js'
const ryCountData = ref([])
const departID = ref("")
const option = ref({
notMerge: true,
backgroundColor: '#F8FAFF',
tooltip: {
trigger: 'axis',
showContent: this.showContent,
axisPointer: {
type: 'shadow',
label: {
show: true
}
}
},
title: {
text: '人员统计图表'
},
toolbox: {
padding: [0, 20, 20, 20],
show: true,
feature: {
//
mark: {
show: true
},
dataView: {
show: true
},
magicType: {
show: true, //
type: ['line', 'bar'] //
},
dataZoom: {
yAxisIndex: 'none'
},
restore: {
show: true //
},
saveAsImage: {
show: true //
}
}
},
calculable: false, //
// itemHeight: 0,
legend: {
//
data: [],
itemGap: 24,
padding: [5, 15, 10, 15],
// y: 'bottom',
itemHeight: 8, //
itemWidth: 8, //
type: 'scroll',
top: 40,
},
grid: {
top: '15%',
left: '4%',
right: '4%',
bottom: '6%',
containLabel: true
},
xAxis: [{
show: true,
type: 'category', //
// boundaryGap:false, //线
data: [],
// offset:50,
//['7.1', '7.2', '7.3', '7.4', '7.5', '7.6', '7.7', '7.8', '7.9', '7.10','7.11', ], //this.xList, //obama_budget_2012.names
axisLabel: {
color: '#7F84B5',
fontWeight: 300,
interval: 0,
rotate: 70
},
axisTick: {
show: false //线
},
axisLine: {
show: false //线
}
}],
yAxis: [{
show: true,
boundaryGap: false, //线
type: 'value',
// name: 'Budget (million USD)',
// data: this.yList,
minInterval: 1,
axisLabel: {
interval: 0
},
splitLine: {
show: true,
lineStyle: {
//线
type: 'dashed'
}
},
axisTick: {
show: true //线
},
axisLine: {
show: false //线
}
}],
dataZoom: [{
show: true,
start: 80,
end: 100,
handleSize: 10
},
{
type: 'inside',
start: 0,
end: 50
},
{
show: false,
yAxisIndex: 0,
filterMode: 'empty',
width: 12,
height: '80%',
showDataShadow: false,
left: '93%',
handleSize: 8
}
],
series: []
//
const bottomHeight = ref(0);
//
const isLoading = ref(false);
const orgCode = ref('');
const rawData = ref([]);
const tableData = ref([]);
const summary = reactive({
total: 0,
avgAge: 0
});
const chart = ref(null);
const chartOption = ref({});
const drillPopup = ref(null);
const drillList = ref([]);
const drillTitle = ref('');
const xData = ref([])
const ySeries = ref([])
const legData = ref([])
function departChange(e) {
departID.value = e
function detail(record) {
// console.log(record)
uni.navigateTo({
url: "/pages/views/renliziyuan/renyuanxinxi/detail?data=" + encodeURIComponent(JSON.stringify(record))
})
}
// initChart
const calculateAge = (birthDate) => {
const today = new Date();
const birth = new Date(birthDate);
let age = today.getFullYear() - birth.getFullYear();
const monthDiff = today.getMonth() - birth.getMonth();
if (monthDiff < 0 || (monthDiff === 0 && today.getDate() < birth.getDate())) {
age--;
}
return age;
};
//
const departChange = async (e, data) => {
function getRyByxb(val) {
ryCountData.value = []
let queryParm = {};
queryParm.orgCode = departID.value
cxcRyDatacountByXb(queryParm).then((res) => {
console.log(res);
if (res.success) {
xData.value = [];
ySeries.value = [];
legData.value = [];
let serie = {
name: '',
type: 'bar',
data: [],
itemStyle: {
normal: {
label: {
show: true, //
position: 'top', //
textStyle: {
//
color: 'black',
fontSize: 16
}
}
}
}
};
tableData.value = []
console.log(e)
orgCode.value = e;
try {
//
let serieMan = JSON.parse(JSON.stringify(serie));
let serieTotal = JSON.parse(JSON.stringify(serie));
serieTotal.name = '总数';
serieMan.name = '男';
let serieWoman = JSON.parse(JSON.stringify(serie));
serieWoman.name = '女';
ryData.map(item => {
xData.value.push(item.depart_name);
serieMan.data.push(item.man);
serieWoman.data.push(item.woman);
serieTotal.data.push(item.total);
isLoading.value = true;
if (orgCode.value.length <= 6) {
console.log(123242353)
uni.showLoading({
title: '全厂数据较多,耐心等待数据加载中...',
mask: true
});
} else {
uni.showLoading({
title: '数据加载中...',
mask: true
});
ySeries.value.push(serieTotal);
ySeries.value.push(serieMan);
ySeries.value.push(serieWoman);
legData = ['总数', '男', '女'];
option.value.legend.data = legData.value;
option.value.xAxis[0].data = xData.value;
option.value.series = ySeries.value;
option.value.title.text = bmText + '人员性别统计';
}
setTimeout(async () => {
if (!chartRef.value) return
const myChart = await chartRef.value.init(echarts)
myChart.setOption(option.value)
}, 300)
}).catch((err) => {
console.log(err);
let params = {
pageSize: 3000,
fields: ['xm', 'nl', 'xb', 'xb_dictText', 'orgCode', 'jcdw', 'jcxd', 'jcxdCode']
};
if (orgCode.value.length <= 9) {
params.orgCode = orgCode.value
} else {
params.jcxd_code = orgCode.value
}
queryRenyuanByDepartID(params).then((res) => {
if (res.success) {
processData(res.result.records);
//
isLoading.value = false;
uni.hideLoading();
}
}).catch((err) => {
console.log(err)
uni.showToast({
title: '数据加载失败',
icon: 'none'
});
})
} catch (error) {
console.log(error)
uni.showToast({
title: '数据加载失败',
icon: 'none'
});
} finally {
//
isLoading.value = false;
uni.hideLoading();
}
};
//
const processData = (data) => {
//
const validData = data.map(item => ({
...item,
nl: calculateAge(item.cssj)
})).filter(item => item.nl >= 21 && item.nl <= 64);
//
summary.total = validData.length;
summary.avgAge = validData.reduce((sum, cur) => sum + cur.nl, 0) / summary.total || 0;
//
// tableData.value = validData;
groupsData(validData);
//
generateChartData(validData);
};
// ...
const subOrgStaffs = ref({}); //
const ageGroupStaffs = ref({}); //
const groupsData = (data) => {
//
subOrgStaffs.value = {};
ageGroupStaffs.value = {};
data.reduce((acc, cur) => {
// console.log(cur)
let subOrg = "";
let ageRange = getAgeRange(cur.nl);
// console.log(cur.orgCode, cur.jcxdCode)
if (cur.orgCode <= 6) {
subOrg = cur.orgCode
} else {
subOrg = cur.jcxdCode
}
// subOrgStaffs
if (!subOrgStaffs.value[subOrg]) {
subOrgStaffs.value[subOrg] = [];
}
subOrgStaffs.value[subOrg].push(cur);
// ageGroupStaffs
if (!ageGroupStaffs.value[ageRange]) {
ageGroupStaffs.value[ageRange] = [];
}
ageGroupStaffs.value[ageRange].push(cur);
})
}
function getRyBynl(val) {
ryCountData.value = []
let queryParm = {};
queryParm.orgCode = departID.value
cxcRyDatacountByNl(queryParm).then((res) => {
console.log(res);
if (res.success) {
ryCountData.value = res.result.records
//
const getAgeRange = (age) => {
const ranges = ['21-30岁', '31-40岁', '41-50岁', '51-60岁', '61-64岁'];
const index = Math.floor((age - 21) / 10);
return ranges[index] || '其他';
};
//
const showStaffList = (subOrg, ageRange) => {
//
const targetStaffs = subOrgStaffs.value[subOrg].filter(staff =>
getAgeRange(staff.nl) === ageRange
);
staffList.value = targetStaffs;
popupTitle.value = `${subOrg} ${ageRange}人员列表(共${targetStaffs.length}人)`;
popup.value.open();
};
//
const getSubOrgStaffs = (subOrgCode) => {
return subOrgStaffs.value[subOrgCode] || [];
};
//
const getAgeGroupStaffs = (ageRange) => {
return ageGroupStaffs.value[ageRange] || [];
};
//
const generateChartData = (data) => {
//
const ageRanges = ['21-30岁', '31-40岁', '41-50岁', '51-60岁', '61-64岁'];
const jcdwGroups = data.reduce((acc, cur) => {
if (!acc[cur.jcdw]) {
acc[cur.jcdw] = {
ageGroups: [0, 0, 0, 0, 0] // 21-30,31-40,41-50,51-60,61-64
};
}
}).catch((err) => {
console.log(err);
})
}
const ageGroup = Math.floor((cur.nl - 21) / 10);
// console.log(ageGroup, cur.jcdw)
if (ageGroup >= 0 && ageGroup <= 4) {
acc[cur.jcdw].ageGroups[ageGroup]++;
}
return acc;
}, {});
//
const xData = Object.keys(jcdwGroups);
const seriesData = ageRanges.map((range, index) => ({
name: range,
type: 'bar',
data: xData.map(jcdw => jcdwGroups[jcdw].ageGroups[index] || 0),
itemStyle: {
color: ['#5470C6', '#91CC75', '#FAC858', '#EE6666', '#73C0DE'][index]
},
//
label: {
show: true,
position: 'top'
},
// 20
// barWidth: 20
}))
chartOption.value = {
title: {
text: '人员年龄分组统计',
padding: [0, 0, 0, 30],
},
toolbox: {
padding: [0, 30, 0, 0],
show: true,
feature: {
//
restore: {
show: true //
},
saveAsImage: {
show: true //
}
}
},
// tooltip: {
// trigger: 'axis',
// axisPointer: {
// type: 'shadow',
// label: {
// show: false
// }
// }
// },
grid: {
top: '15%',
left: '4%',
right: '4%',
bottom: '10%',
containLabel: true
},
legend: {
data: ageRanges,
itemGap: 5,
padding: [0, 15, 0, 15],
y: 'bottom',
itemHeight: 8, //
itemWidth: 8, //
type: 'scroll'
},
xAxis: {
type: 'category',
data: xData,
axisLabel: {
color: '#7F84B5',
fontWeight: 300,
interval: 0,
rotate: 0,
},
padding: [0, 10, 0, 10],
axisTick: {
show: false //线
},
axisLine: {
show: false //线
}
},
yAxis: [{
show: true,
boundaryGap: false, //线
type: 'value',
// name: 'Budget (million USD)',
// data: this.yList,
minInterval: 1,
axisLabel: {
interval: 0
},
splitLine: {
show: true,
lineStyle: {
//线
type: 'dashed'
}
},
axisTick: {
show: true //线
},
axisLine: {
show: false //线
}
}],
series: seriesData,
};
//
setTimeout(async () => {
if (!chart.value) return
const myChart = await chart.value.init(echarts)
myChart.setOption(chartOption.value)
myChart.on('click', (params) => {
console.log(params.seriesName)
tableData.value = getAgeGroupStaffs(params.seriesName)
})
}, 300)
// #ifdef APP
getHeight();
// #endif
};
onMounted(() => {
// #ifdef APP
getHeight();
// #endif
})
// #ifdef APP
const getHeight = () => {
//
const systemInfo = uni.getSystemInfoSync();
const screenHeight = systemInfo.screenHeight;
//
const query = uni.createSelectorQuery();
//
query
.select('#top1')
.boundingClientRect((rect1) => {
//
const topComponentsHeight = rect1.height
//
bottomHeight.value = screenHeight - topComponentsHeight - 415;
})
.exec();
};
// #endif
//
const initChart = () => {
setTimeout(async () => {
if (!chart.value) return
const myChart = await chart.value.init(echarts)
myChart.setOption(chartOption.value)
}, 300)
};
</script>
<style>
<style scoped>
.container {
margin: 20, 20, 20, 20rpx;
}
.input-group {
display: flex;
gap: 20rpx;
margin-bottom: 30rpx;
}
.input {
flex: 1;
border: 1rpx solid #ddd;
padding: 15rpx;
border-radius: 8rpx;
}
.query-btn {
background: #007AFF;
color: white;
padding: 0 40rpx;
border-radius: 8rpx;
}
.stats-box {
display: flex;
justify-content: space-around;
margin: 30rpx 0;
padding: 20rpx;
background: #f8f8f8;
border-radius: 12rpx;
}
.stat-item {
display: flex;
flex-direction: column;
align-items: center;
}
.label {
font-size: 24rpx;
color: #666;
}
.value {
font-size: 36rpx;
font-weight: bold;
color: #0000ff;
}
.chart-container {
height: 400rpx;
margin-top: 20rpx;
}
.titleStyle {
font-size: 12px;
color: #747474;
line-height: 30px;
height: 30px;
background: #F2F9FC;
text-align: center;
vertical-align: middle;
border-left: 1px solid #919191;
border-bottom: 1px solid #919191;
;
}
/* 内容样式 */
.dataStyle {
max-font-size: 14px;
/* 最大字体限制 */
min-font-size: 10px;
/* 最小字体限制 */
font-size: 12px;
color: #00007f;
line-height: 30px;
height: 30px;
font-weight: 500;
text-align: center;
vertical-align: middle;
border-bottom: 1px solid #919191;
border-left: 1px solid #919191;
text-overflow: ellipsis;
}
</style>

View File

@ -1,40 +1,54 @@
<template>
<view :class="['f-col','aic',{'gray':store.isgray==1}]">
<picker fields="month" mode="date" @change="bindPickerChange" :value="index">
<view class="date">{{index}} 点击选择月份</view>
</picker>
<view class="info">
<view class="info_title f-row aic">
<view class="">
<view :class="[{'gray':store.isgray==1}]">
<view style="margin-top: 10px;margin-bottom: 10px;">
<picker fields="month" mode="date" @change="bindPickerChange" :value="index">
<view class="date">{{index}} 点击选择月份</view>
</picker>
</view>
<uni-row>
<uni-col :span="7">
<view class="titleStyle">
日期
</view>
<view class="">
</uni-col>
<uni-col :span="4">
<view class="titleStyle">
带班领导
</view>
<view class="">
</uni-col>
<uni-col :span="4">
<view class="titleStyle">
值班领导
</view>
<view class="">
</uni-col>
<uni-col :span="9">
<view class="titleStyle">
值班干部
</view>
</view>
<view class="data_box">
<view class="data f-row aic" v-for="item,i in zhibanArr">
<view class="">
</uni-col>
</uni-row>
<uni-row>
<view v-for="(item,index) in zhibanArr">
<uni-col :span="7">
<view class="dataStyle">
{{item.date}}
</view>
<view class="">
</uni-col>
<uni-col :span="4">
<view class="dataStyle">
{{item.dbld_dictText}}
</view>
<view class="">
</uni-col><uni-col :span="4">
<view class="dataStyle">
{{item.zbld_dictText}}
</view>
<view class="">
</uni-col><uni-col :span="9">
<view class="dataStyle">
{{item.zbgbrealname}}
</view>
</view>
</uni-col>
</view>
</view>
</uni-row>
</view>
</template>
@ -53,6 +67,36 @@
} from '@/store';
const store = useStore()
import dayjs from 'dayjs';
let column = ref([{
name: 'date',
label: '日期',
width: 70,
align: 'center'
},
{
name: 'dbld_dictText',
label: '带班领导',
align: 'center',
width: 60
},
{
name: 'zbld_dictText',
label: '值班领导',
align: 'center',
width: 60
},
{
name: 'zbgbrealname',
label: '值班干部',
align: 'center',
width: 150
}
])
const zhibanArr = ref([])
onLoad(() => {
zhibanQuery()
@ -83,36 +127,36 @@
color: #333333;
}
.info {
background: #F8F8F8;
border-radius: 8rpx;
.titleStyle {
font-size: 12px;
color: #747474;
line-height: 25px;
height: 25px;
background: #F2F9FC;
text-align: center;
width: 690rpx;
margin-top: 23rpx;
vertical-align: middle;
border-left: 1px solid #919191;
border-bottom: 1px solid #919191;
;
}
.info_title {
font-size: 24rpx;
color: #333333;
padding: 24rpx 0;
border-bottom: 1px solid #EFEFEF;
/* 内容样式 */
.dataStyle {
max-font-size: 14px;
/* 最大字体限制 */
min-font-size: 10px;
/* 最小字体限制 */
font-size: 12px;
color: #00007f;
line-height: 25px;
height: 25px;
font-weight: 500;
text-align: center;
vertical-align: middle;
border-bottom: 1px solid #919191;
border-left: 1px solid #919191;
text-overflow: ellipsis;
view {
flex: 1;
}
}
.data_box {
font-size: 24rpx;
padding-bottom: 24rpx;
color: #888888;
.data {
margin-top: 23rpx;
view {
flex: 1;
}
}
}
}
</style>

View File

@ -37,12 +37,6 @@ export const useUpdateApp = defineStore('updateApp', () => {
} = res
result.apkUrl = baseUrl + result.apkUrl;
result.wgtUrl = baseUrl + result.wgtUrl
// res = {
// "update": "wgt",
// "wgtUrl": "D:\\opt\\AppUpdate\\wgt\\2.2.34.wgt",
// "apkUrl": null,
// "versionCode": "1.0.0"
// }
// updateOptions.force = res.is_force === 1
// updateOptions.content = res.update_content
updateOptions.wgtUrl = result.wgtUrl

View File

@ -7,7 +7,7 @@ import {isDef} from '../isDef'
* @returns null null
*/
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export function addUnit(value?: string | number): string | null {
if (!isDef(value)) {
return null;
@ -19,7 +19,7 @@ export function addUnit(value?: string | number): string | null {
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
function addUnit(value: string): string
function addUnit(value: number): string
function addUnit(value: any|null): string|null {

View File

@ -1,2 +1,3 @@
import {cubicBezier} from './bezier';
export let ease = cubicBezier(0.25, 0.1, 0.25, 1);
export let linear = cubicBezier(0,0,1,1);

View File

@ -1,10 +1,10 @@
// @ts-nocheck
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.uts'
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif

View File

@ -1,14 +1,14 @@
// @ts-nocheck
import { ComponentPublicInstance } from 'vue'
import { ease } from './ease';
import type { ComponentPublicInstance } from 'vue'
import { ease, linear } from './ease';
import { Timeline, Animation } from './';
export type UseTransitionOptions = {
duration ?: number
immediate ?: boolean
context ?: ComponentPublicInstance
}
// #ifndef APP-IOS || APP-ANDROID
import { ref, watch, Ref } from '@/uni_modules/lime-shared/vue'
// #ifndef UNI-APP-X && APP
import { ref, watch, type Ref } from '@/uni_modules/lime-shared/vue'
export function useTransition(percent : Ref<number>|(() => number), options : UseTransitionOptions) : Ref<number> {
const current = ref(0)
@ -47,7 +47,7 @@ export function useTransition(percent : Ref<number>|(() => number), options : Us
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
type UseTransitionReturnType = Ref<number>
export function useTransition(source : any, options : UseTransitionOptions) : UseTransitionReturnType {
const outputRef : Ref<number> = ref(0)
@ -69,7 +69,7 @@ export function useTransition(source : any, options : UseTransitionOptions) : Us
0,
ease,
nowValue => {
outputRef.value = nowValue //nowValue < 0.0001 ? 0 : Math.abs(v - nowValue) < 0.00001 ? v : nowValue;
outputRef.value = nowValue
clearTimeout(timer)
if(outputRef.value == v){
timer = setTimeout(()=>{
@ -78,14 +78,17 @@ export function useTransition(source : any, options : UseTransitionOptions) : Us
}, duration)
}
}
), null
),
null
);
}
if (context != null && typeof source == 'string') {
context.$watch(source, watchFunc, { immediate } as WatchOptions)
} else {
watch(source, watchFunc, { immediate } as WatchOptions)
} else if(typeof source == 'function'){
watch(source, watchFunc, { immediate })
} else if(source instanceof Ref<number>){
watch(source as Ref<number>, watchFunc, { immediate })
}
const stop = ()=>{

View File

@ -1,3 +1,4 @@
import { raf, cancelRaf} from '../raf'
// @ts-nocheck
export class Timeline {
state : string
@ -13,7 +14,7 @@ export class Timeline {
this.state = 'Initiated';
}
start() {
if (!(this.state === 'Initiated')) return;
if (!(this.state == 'Initiated')) return;
this.state = 'Started';
let startTime = Date.now();
@ -43,20 +44,26 @@ export class Timeline {
if (animation == null) return
this.animations.delete(animation);
}
clearTimeout(this.tickHandler);
// cancelAnimationFrame(this.tickHandler);
if (this.state != 'Started') return
this.tickHandler = setTimeout(() => {
this.tickHandler = raf(()=>{
this.tick!()
}, 1000 / 60)
// this.tickHandlers.push(this.tickHandler)
})
this.tickHandlers.push(this.tickHandler)
}
this.tick!()
if(this.tick != null) {
this.tick!()
}
}
pause() {
if (!(this.state === 'Started')) return;
this.state = 'Paused';
this.pauseStart = Date.now();
clearTimeout(this.tickHandler);
cancelRaf(this.tickHandler);
// cancelRaf(this.tickHandler);
}
resume() {
if (!(this.state === 'Paused')) return;

View File

@ -1,10 +1,8 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif
// #ifdef UNI-APP-X
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.uts'
// #endif
// #endif

View File

@ -1,9 +1,9 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.uts'
// #endif

View File

@ -1,6 +1,6 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
// #ifdef MP-ALIPAY
interface My {
@ -57,11 +57,11 @@ export function canIUseCanvas2d(): boolean {
// #ifdef MP-TOUTIAO
return gte('1.78.0');
// #endif
// #ifdef UNI-APP-X && WEB || UNI-APP-X && APP
return true;
// #endif
// #ifndef MP-WEIXIN || MP-ALIPAY || MP-TOUTIAO
return false
// #endif
// #ifdef APP-IOS || APP-ANDROID || APP-NVUE || APP-VUE
return false;
// #endif
}

View File

@ -1,3 +1,26 @@
## 0.2.72025-01-17
- fix: 针对canvas 平台判断优化
## 0.2.62025-01-09
- feat: 增加`areaData`中国省市区数据
## 0.2.52025-01-07
- fix: animation在app上类型问题
## 0.2.42025-01-04
- feat: getRect类型问题
## 0.2.32025-01-01
- chore: unitConvert使用uni.rpx2px
## 0.2.22024-12-11
- chore: 动画使用`requestAnimationFrame`
## 0.2.12024-11-20
- feat: 增加`characterLimit`
## 0.2.02024-11-14
- fix: vue2的类型问题
## 0.1.92024-11-14
- feat: 增加`shuffle`
## 0.1.82024-10-08
- fix: vue2 条件编译 // #ifdef APP-IOS || APP-ANDROID 会生效
## 0.1.72024-09-23
- fix: raf 类型跟随版本变更
## 0.1.62024-07-24
- fix: vue2 app ts需要明确的后缀所有补全
- chore: 减少依赖

View File

@ -1,10 +1,10 @@
// @ts-nocheck
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.ts'
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif

View File

@ -15,6 +15,9 @@
import { debounce } from '@/uni_modules/lime-shared/debounce'
import { fillZero } from '@/uni_modules/lime-shared/fillZero'
import { floatAdd } from '@/uni_modules/lime-shared/floatAdd'
import { floatMul } from '@/uni_modules/lime-shared/floatMul'
import { floatDiv } from '@/uni_modules/lime-shared/floatDiv'
import { floatSub } from '@/uni_modules/lime-shared/floatSub'
import { getClassStr } from '@/uni_modules/lime-shared/getClassStr'
import { getCurrentPage } from '@/uni_modules/lime-shared/getCurrentPage'
import { getStyleStr } from '@/uni_modules/lime-shared/getStyleStr'
@ -40,91 +43,102 @@
import { toNumber } from '@/uni_modules/lime-shared/toNumber'
import { unitConvert } from '@/uni_modules/lime-shared/unitConvert'
import { getCurrentInstance } from '@/uni_modules/lime-shared/vue'
import { capitalizedAmount } from '@/uni_modules/lime-shared/capitalizedAmount'
// #ifdef VUE2
type UTSJSONObject = any
// #endif
const context = getCurrentInstance()
getRect('#shared', context!).then(res =>{
console.log('res', res.bottom)
})
getAllRect('#shared', context).then(res =>{
console.log('res', res)
})
// getRect('#shared', context!).then(res =>{
// console.log('res', res.bottom)
// })
// getAllRect('#shared', context).then(res =>{
// console.log('res', res)
// })
console.log('camelCase::', camelCase("hello world"));
console.log('camelCase::', camelCase("my_name_is_john", true));
console.log('canIUseCanvas2d::', canIUseCanvas2d());
console.log('clamp::', clamp(5 ,0, 10));
console.log('cloneDeep::', cloneDeep<UTSJSONObject>({a:5}));
console.log('closest::', closest([1, 3, 5, 7, 9], 6));
// console.log('camelCase::', camelCase("hello world"));
// console.log('camelCase::', camelCase("my_name_is_john", true));
// console.log('canIUseCanvas2d::', canIUseCanvas2d());
// console.log('clamp::', clamp(5 ,0, 10));
// console.log('cloneDeep::', cloneDeep<UTSJSONObject>({a:5}));
// console.log('closest::', closest([1, 3, 5, 7, 9], 6));
const saveData = (data: any) => {
//
console.log(`Saving data: ${data}`);
}
// const saveData = (data: any) => {
// //
// console.log(`Saving data: ${data}`);
// }
const debouncedSaveData = debounce(saveData, 500);
debouncedSaveData('Data 1');
debouncedSaveData('Data 2');
// const debouncedSaveData = debounce(saveData, 500);
// debouncedSaveData('Data 1');
// debouncedSaveData('Data 2');
console.log('fillZero', fillZero(1))
console.log('floatAdd', floatAdd(0.1, 0.2))
console.log('getClassStr', getClassStr({hover: true}))
console.log('getStyleStr', getStyleStr({ color: 'red', fontSize: '16px', backgroundColor: '', border: null }))
console.log('hasOwn', hasOwn({a: true}, 'key'))
console.log('isBase64::', isBase64("SGVsbG8sIFdvcmxkIQ=="));
console.log('isBrowser::', isBrowser);
console.log('isDef::', isDef('6'));
console.log('isEmpty::', isEmpty({a: true}));
// console.log('fillZero', fillZero(1))
// console.log('floatAdd', floatAdd(0.1, 0.2), floatAdd(1.05, 0.05), floatAdd(0.1, 0.7), floatAdd(0.0001, 0.0002), floatAdd(123.456 , 789.012))
// console.log('floatMul', floatMul(0.1, 0.02), floatMul(1.0255, 100))
// console.log('floatDiv', floatDiv(10.44, 100), floatDiv(1.0255, 100), floatDiv(5.419909340994699, 0.2))
// console.log('floatSub', floatSub(0.4, 0.1), floatSub(1.0255, 100))
const now = () : number => System.nanoTime() / 1_000_000.0
console.log('capitalizedAmount', capitalizedAmount(0.4))
console.log('capitalizedAmount', capitalizedAmount(100))
console.log('capitalizedAmount', capitalizedAmount(100000000))
console.log('capitalizedAmount', capitalizedAmount('2023.04'))
console.log('capitalizedAmount', capitalizedAmount(-1024))
console.log('now', now(), Date.now())
// console.log('getClassStr', getClassStr({hover: true}))
// console.log('getStyleStr', getStyleStr({ color: 'red', fontSize: '16px', backgroundColor: '', border: null }))
// console.log('hasOwn', hasOwn({a: true}, 'key'))
// console.log('isBase64::', isBase64("SGVsbG8sIFdvcmxkIQ=="));
// console.log('isBrowser::', isBrowser);
// console.log('isDef::', isDef('6'));
// console.log('isEmpty::', isEmpty({a: true}));
const b = () =>{}
console.log('isFunction::', isFunction(b));
console.log('isNumber::', isNumber('6'));
console.log('isNumeric::', isNumeric('6'));
console.log('isObject::', isObject({}));
// const b = () =>{}
// console.log('isFunction::', isFunction(b));
// console.log('isNumber::', isNumber('6'));
// console.log('isNumeric::', isNumeric('6'));
// console.log('isObject::', isObject({}));
const promise = ():Promise<boolean> => {
return new Promise((resolve) => {
resolve(true)
})
}
const a = promise()
console.log('isPromise::', isPromise(a));
console.log('isString::', isString('null'));
console.log('kebabCase::', kebabCase('my love'));
console.log('raf::', raf(()=>{
console.log('raf:::1')
}));
console.log('doubleRaf::', doubleRaf(()=>{
console.log('doubleRaf:::1')
}));
console.log('random', random(0, 10))
console.log('random', random(0, 1, 2))
console.log('range', range(0, 10, 2))
console.log('sleep', sleep(300).then(res => {
console.log('log')
}))
// const promise = ():Promise<boolean> => {
// return new Promise((resolve) => {
// resolve(true)
// })
// }
// const a = promise()
// console.log('isPromise::', isPromise(a));
// console.log('isString::', isString('null'));
// console.log('kebabCase::', kebabCase('my love'));
// console.log('raf::', raf(()=>{
// console.log('raf:::1')
// }));
// console.log('doubleRaf::', doubleRaf(()=>{
// console.log('doubleRaf:::1')
// }));
// console.log('random', random(0, 10))
// console.log('random', random(0, 1, 2))
// console.log('range', range(0, 10, 2))
// console.log('sleep', sleep(300).then(res => {
// console.log('log')
// }))
const handleScroll = (a: string) => {
console.log("Scroll event handled!", a);
}
// const handleScroll = (a: string) => {
// console.log("Scroll event handled!", a);
// }
// // 使 handleScroll 500
const throttledScroll = throttle(handleScroll, 500);
throttledScroll('5');
const page = getCurrentPage()
console.log('getCurrentPage::', page)
// // // 使 handleScroll 500
// const throttledScroll = throttle(handleScroll, 500);
// throttledScroll('5');
// const page = getCurrentPage()
// console.log('getCurrentPage::', page)
console.log('toArray', toArray<number>(5))
console.log('toBoolean', toBoolean(5))
console.log('toNumber', toNumber('5'))
console.log('unitConvert', unitConvert('5'))
// console.log('toArray', toArray<number>(5))
// console.log('toBoolean', toBoolean(5))
// console.log('toNumber', toNumber('5'))
// console.log('unitConvert', unitConvert('5'))
// uni.getImageInfo({
// src: '/static/logo.png',
@ -132,6 +146,9 @@
// console.log('res', res)
// }
// })
export default {
}
</script>
<style>

View File

@ -1,5 +1,5 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
import {isBrowser} from '../isBrowser'
class Image {
currentSrc: string | null = null
@ -63,8 +63,9 @@ export function createImage(canvas?: any): HTMLImageElement | UniImage {
// #endif
// #ifdef APP-IOS || APP-ANDROID
export function createImage(){
console.error('当前环境不支持')
// #ifdef UNI-APP-X && APP
export function createImage():Image{
// console.error('当前环境不支持')
return new Image()
}
// #endif

View File

@ -1,10 +1,10 @@
// @ts-nocheck
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.ts'
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif

View File

@ -1,9 +1,9 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.ts'
// #endif

View File

@ -1,36 +1,36 @@
import {isNumber} from '../isNumber'
import { isNumber } from '../isNumber'
/**
*
* @param num1
* @param num2
* @returns
*/
export function floatAdd(num1: number, num2: number): number {
// 检查 num1 和 num2 是否为数字类型
if (!(isNumber(num1) || isNumber(num2))) {
console.warn('Please pass in the number type');
return NaN;
}
export function floatAdd(num1 : number, num2 : number) : number {
// 检查 num1 和 num2 是否为数字类型
if (!(isNumber(num1) || isNumber(num2))) {
console.warn('Please pass in the number type');
return NaN;
}
let r1: number, r2: number, m: number;
let r1 : number, r2 : number, m : number;
try {
// 获取 num1 小数点后的位数
r1 = num1.toString().split('.')[1].length;
} catch (error) {
r1 = 0;
}
try {
// 获取 num1 小数点后的位数
r1 = num1.toString().split('.')[1].length;
} catch (error) {
r1 = 0;
}
try {
// 获取 num2 小数点后的位数
r2 = num2.toString().split('.')[1].length;
} catch (error) {
r2 = 0;
}
try {
// 获取 num2 小数点后的位数
r2 = num2.toString().split('.')[1].length;
} catch (error) {
r2 = 0;
}
// 计算需要扩大的倍数
m = Math.pow(10, Math.max(r1, r2));
// 计算需要扩大的倍数
m = Math.pow(10, Math.max(r1, r2));
// 返回相加结果
return (num1 * m + num2 * m) / m;
// 返回相加结果
return (num1 * m + num2 * m) / m;
}

View File

@ -1,6 +1,6 @@
// @ts-nocheck
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
import { isNumber } from '../isNumber'
import { isString } from '../isString'
import { isDef } from '../isDef'
@ -13,7 +13,7 @@ import { isDef } from '../isDef'
*/
export function getClassStr<T>(obj : T) : string {
let classNames : string[] = [];
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
if (obj instanceof UTSJSONObject) {
(obj as UTSJSONObject).toMap().forEach((value, key) => {
if (isDef(value)) {
@ -30,7 +30,7 @@ export function getClassStr<T>(obj : T) : string {
})
}
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
// 遍历对象的属性
for (let key in obj) {
// 检查属性确实属于对象自身且其值为true

View File

@ -1,9 +1,9 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.uts'
// #endif

View File

@ -16,7 +16,7 @@ export const getLocalFilePath = (path : string) => {
// #endif
// #ifdef APP-ANDROID || APP-IOS
// #ifdef UNI-APP-X && APP
export { getResourcePath as getLocalFilePath } from '@/uni_modules/lime-file-utils'
// export const getLocalFilePath = (path : string) : string => {
// let uri = path

View File

@ -1,9 +1,9 @@
// @ts-nocheck
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.uts'
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif

View File

@ -1,5 +1,5 @@
// @ts-nocheck
export function getRect(selector : string, context: ComponentInternalInstance):Promise<NodeInfo> {
export function getRect(selector : string, context: ComponentPublicInstance):Promise<NodeInfo> {
return new Promise((resolve)=>{
uni.createSelectorQuery().in(context).select(selector).boundingClientRect(res =>{
resolve(res as NodeInfo)
@ -7,7 +7,7 @@ export function getRect(selector : string, context: ComponentInternalInstance):P
})
}
export function getAllRect(selector : string, context: ComponentInternalInstance):Promise<NodeInfo[]> {
export function getAllRect(selector : string, context: ComponentPublicInstance):Promise<NodeInfo[]> {
return new Promise((resolve)=>{
uni.createSelectorQuery().in(context).selectAll(selector).boundingClientRect(res =>{
resolve(res as NodeInfo[])

View File

@ -12,7 +12,7 @@ const dom = uni.requireNativePlugin('dom')
* @param node node
* @returns Promise
*/
export function getRect(selector : string, context : ComponentInternalInstance, node: boolean = false) {
export function getRect(selector : string, context : ComponentInternalInstance|ComponentPublicInstance, node: boolean = false) {
// 之前是个对象,现在改成实例,防止旧版会报错
if(context== null) {
return Promise.reject('context is null')
@ -67,7 +67,7 @@ export function getRect(selector : string, context : ComponentInternalInstance,
};
export function getAllRect(selector : string, context: ComponentInternalInstance, node:boolean = false) {
export function getAllRect(selector : string, context: ComponentInternalInstance|ComponentPublicInstance, node:boolean = false) {
if(context== null) {
return Promise.reject('context is null')
}

View File

@ -1,12 +1,12 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
interface CSSProperties {
[key : string] : string | number | null
}
// #endif
// #ifdef VUE3
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
type CSSProperties = UTSJSONObject
// #endif
// #endif
@ -26,7 +26,7 @@ export function toLowercaseSeparator(key : string):string {
*/
export function getStyleStr(style : CSSProperties) : string {
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
let styleStr = '';
style.toMap().forEach((value, key) => {
if(value !== null && value != '') {
@ -35,7 +35,7 @@ export function getStyleStr(style : CSSProperties) : string {
})
return styleStr
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
return Object.keys(style)
.filter(
(key) =>

View File

@ -1,9 +1,9 @@
// @ts-nocheck
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.ts'
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif

View File

@ -13,10 +13,10 @@ export function isDef(value: unknown): boolean {
// #ifdef UNI-APP-X
export function isDef(value : any|null) : boolean {
// #ifdef APP-ANDROID || APP-IOS
// #ifdef UNI-APP-X && APP
return value != null;
// #endif
// #ifndef APP-ANDROID || APP-IOS
// #ifndef UNI-APP-X && APP
return value != null && value != undefined;
// #endif
}

View File

@ -16,7 +16,7 @@ import {isNumber} from '../isNumber'
*/
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export function isEmpty(value : any | null) : boolean {
// 为null
if(!isDef(value)){
@ -55,7 +55,7 @@ export function isEmpty(value : any | null) : boolean {
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export function isEmpty(value: any): boolean {
// 检查是否为null或undefined
if (value == null) {

View File

@ -5,12 +5,12 @@
* @returns true false
*/
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export const isFunction = (val: any):boolean => typeof val == 'function';
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export const isFunction = (val: unknown): val is Function =>
typeof val === 'function';
// #endif

View File

@ -19,7 +19,7 @@ export function isNumber(value: any|null): boolean {
// #ifdef APP-IOS
return ['Int8', 'UInt8','Int16','UInt16','Int32','UInt32','Int64','UInt64','Int','UInt','Float','Float16','Float32','Float64','Double', 'number'].includes(typeof value)
// #endif
// #ifndef APP-ANDROID || APP-IOS
// #ifndef UNI-APP-X && APP
return typeof value === 'number' && !isNaN(value);
// #endif
}

View File

@ -6,14 +6,14 @@
* @returns true false
*/
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export function isNumeric(value: string | number | undefined | null): boolean {
return /^(-)?\d+(\.\d+)?$/.test(value);
}
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
import {isNumber} from '../isNumber';
import {isString} from '../isString';
export function isNumeric(value : any|null) : boolean {

View File

@ -5,14 +5,14 @@
* @returns true false
*/
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export const isObject = (val : unknown) : val is Record<any, any> =>
val !== null && typeof val === 'object';
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export const isObject = (val : any | null) : boolean =>{
return val !== null && typeof val === 'object';
}

View File

@ -4,7 +4,7 @@
* @param str
* @returns true false
*/
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
// export const isString = (str: unknown): str is string => typeof str === 'string';
export function isString (str: unknown): str is string {
return typeof str == 'string'
@ -12,8 +12,8 @@ export function isString (str: unknown): str is string {
// #endif
// #ifdef APP-IOS || APP-ANDROID
export function isString (str: any): boolean {
// #ifdef UNI-APP-X && APP
export function isString (str: any|null): boolean {
return typeof str == 'string'
}
// #endif

View File

@ -12,10 +12,10 @@
export function kebabCase(str : string, separator : string = "-") : string {
return str
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
.replace(/[A-Z]/g, (match : string, _ : number, _ : string) : string => `${separator}${match.toLowerCase()}`) // 将大写字母替换为连接符加小写字母
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
.replace(/[A-Z]/g, (match : string) : string => `${separator}${match.toLowerCase()}`) // 将大写字母替换为连接符加小写字母
// #endif
.replace(/[\s_-]+/g, separator) // 将空格、下划线和短横线替换为指定连接符

View File

@ -1,7 +1,7 @@
{
"id": "lime-shared",
"displayName": "lime-shared",
"version": "0.1.6",
"version": "0.2.7",
"description": "本人插件的几个公共函数获取当前页图片的base64转临时路径图片的exif信息等",
"keywords": [
"lime-shared",
@ -48,9 +48,10 @@
"vue3": "y"
},
"App": {
"app-vue": "y",
"app-uvue": "y",
"app-nvue": "y"
"app-vue": "y",
"app-uvue": "y",
"app-nvue": "y",
"app-harmony": "u"
},
"H5-mobile": {
"Safari": "y",

View File

@ -1,9 +1,9 @@
// @ts-nocheck
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export * from './vue.ts'
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export * from './uvue.uts'
// #endif

View File

@ -1,10 +1,10 @@
// @ts-nocheck
// #ifdef APP-IOS || APP-ANDROID
export * from './vue.ts'
// #ifdef UNI-APP-X && APP
export * from './uvue'
// #endif
// #ifndef APP-IOS || APP-ANDROID
export * from './uvue.ts'
// #ifndef UNI-APP-X && APP
export * from './vue'
// #endif

View File

@ -1,12 +1,11 @@
// @ts-nocheck
// import {isBrowser} from '../isBrowser'
// 是否支持被动事件监听
export const supportsPassive = true;
// #ifdef uniVersion < 4.25
// 请求动画帧
export function raf(fn: TimerCallback): number {
return setTimeout(fn, 1000 / 30);
return setTimeout(fn, 1000 / 60);
}
// 取消动画帧
@ -14,7 +13,36 @@ export function cancelRaf(id: number) {
clearTimeout(id);
}
// 双倍动画帧
export function doubleRaf(fn: TimerCallback): void {
raf(() => raf(fn)); // 在下一帧回调中再次请求动画帧,实现双倍动画帧效果
raf(():number => raf(fn)); // 在下一帧回调中再次请求动画帧,实现双倍动画帧效果
}
// #endif
// #ifdef uniVersion >= 4.25
// 请求动画帧
export function raf(fn: UniAnimationFrameCallback): number
export function raf(fn: UniAnimationFrameCallbackWithNoArgument): number
export function raf(fn: any): number {
if(typeof fn == 'UniAnimationFrameCallback') {
return requestAnimationFrame(fn as UniAnimationFrameCallback);
} else {
return requestAnimationFrame(fn as UniAnimationFrameCallbackWithNoArgument);
}
}
// 取消动画帧
export function cancelRaf(id: number) {
cancelAnimationFrame(id);
}
// 双倍动画帧
export function doubleRaf(fn: UniAnimationFrameCallback): void
export function doubleRaf(fn: UniAnimationFrameCallbackWithNoArgument): void
export function doubleRaf(fn: any): void {
raf(():number => raf(fn)); // 在下一帧回调中再次请求动画帧,实现双倍动画帧效果
}
// #endif

View File

@ -1,5 +1,4 @@
// @ts-nocheck
// import { isBrowser } from '../isBrowser'
type Callback = () => void//Function
// 是否支持被动事件监听
export const supportsPassive = true;
@ -7,7 +6,7 @@ export const supportsPassive = true;
// 请求动画帧
export function raf(fn : Callback) : number {
// #ifndef WEB
return setTimeout(fn, 1000 / 30); // 请求动画帧
return setTimeout(fn, 1000 / 60); // 请求动画帧
// #endif
// #ifdef WEB
return requestAnimationFrame(fn); // 请求动画帧

View File

@ -32,6 +32,7 @@ import {getRect} from '@/uni_modules/lime-shared/getRect'
+ [camelCase](#api_camelCase): 字符串转换为 camelCase 或 PascalCase 风格的命名约定
+ [kebabCase](#api_kebabCase): 将字符串转换为指定连接符的命名约定
+ [closest](#api_closest): 在给定数组中找到最接近目标数字的元素
+ [shuffle](#api_shuffle): 将给定的数组打乱
+ [isBase64](#api_isBase64): 判断字符串是否为base64
+ [isNumber](#api_isNumber): 检查一个值是否为数字类型
+ [isNumeric](#api_isNumeric): 检查一个值是否为数字类型或表示数字的字符串
@ -371,6 +372,19 @@ closest([1, 3, 5, 7, 9], 6) // 5
| √ | √ |
### shuffle <a id="api_shuffle"></a>
- 在给定数组中找到最接近目标数字的元素
```js
shuffle([1, 3, 5, 7, 9])
```
##### 兼容性
| uni-app | uni-app x |
|------------|----------------------------------|
| √ | √ |
### isBase64 <a id="api_isBase64"></a>
- 判断字符串是否为base64

View File

@ -6,7 +6,7 @@
*/
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
function sleep(delay: number = 300):Promise<boolean> {
return new Promise((resolve):void => {setTimeout(() => {resolve(true)}, delay)});
}
@ -16,7 +16,7 @@ export {
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export const sleep = (delay: number = 300) =>
new Promise(resolve => setTimeout(resolve, delay));

View File

@ -6,7 +6,7 @@
* @returns
*/
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export function throttle(fn: (...args: any[]) => void, delay: number) {
let flag = true; // 标记是否可以执行函数
@ -24,7 +24,7 @@ export function throttle(fn: (...args: any[]) => void, delay: number) {
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
// type Rfun = (...args: any[]) => void
// type Rfun = (...args: any[]) => void

View File

@ -4,12 +4,12 @@
* @param item
* @returns
*/
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export const toArray = <T>(item: T | T[]): T[] => Array.isArray(item) ? item : [item];
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
export function toArray<T extends any>(item: any): T[] {
return Array.isArray(item) ? item as T[] : [item as T]// as T[]
};

View File

@ -7,7 +7,7 @@ import { isString } from '../isString'
// function toBoolean(value : number) : boolean;
// function toBoolean(value : boolean) : boolean;
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
function toBoolean(value : any | null) : boolean {
// 根据输入值的类型,返回相应的布尔值
// if (isNumber(value)) {
@ -29,7 +29,7 @@ function toBoolean(value : any | null) : boolean {
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
function toBoolean(value : any | null) : value is NonNullable<typeof value> {
return !!value//value !== null && value !== undefined;
}

View File

@ -5,7 +5,7 @@
* @returns
*/
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
// function toNumber(val: string): number
// function toNumber(val: string): string
function toNumber(val: string): number|null {
@ -15,7 +15,7 @@ function toNumber(val: string): number|null {
export {toNumber}
// #endif
// #ifndef APP-IOS || APP-ANDROID
// #ifndef UNI-APP-X && APP
export function toNumber(val: string): number | string {
const n = parseFloat(val); // 使用 parseFloat 函数将字符串转换为浮点数
return isNaN(n) ? val : n; // 使用 isNaN 函数判断是否为非数字,返回转换后的数字或原始字符串

View File

@ -7,8 +7,8 @@ import { isNumeric } from '../isNumeric'
* @param value
* @returns 0
*/
// #ifndef APP-IOS || APP-ANDROID
export function unitConvert(value : string | number) : number {
// #ifndef UNI-APP-X && APP
export function unitConvert(value : string | number, base: number = 0) : number {
// 如果是字符串数字
if (isNumeric(value)) {
return Number(value);
@ -21,12 +21,15 @@ export function unitConvert(value : string | number) : number {
return 0;
}
const unit = results[3];
value = parseFloat(value);
const _value = parseFloat(value);
if (unit === 'rpx') {
return uni.upx2px(value);
return uni.upx2px(_value);
}
if (unit === 'px') {
return value * 1;
return _value * 1;
}
if(unit == '%') {
return _value / 100 * base
}
// 如果是其他单位,可以继续添加对应的转换逻辑
}
@ -35,9 +38,9 @@ export function unitConvert(value : string | number) : number {
// #endif
// #ifdef APP-IOS || APP-ANDROID
// #ifdef UNI-APP-X && APP
import { isNumber } from '../isNumber'
export function unitConvert(value : any | null) : number {
export function unitConvert(value : any | null, base: number = 0) : number {
if (isNumber(value)) {
return value as number
}
@ -53,13 +56,17 @@ export function unitConvert(value : any | null) : number {
return 0;
}
const unit = results[3];
const v = parseFloat(value);
const _value = parseFloat(value);
if (unit == 'rpx') {
const { windowWidth } = uni.getWindowInfo()
return windowWidth / 750 * v;
// const { windowWidth } = uni.getWindowInfo()
// return windowWidth / 750 * _value;
return uni.rpx2px(_value)
}
if (unit == 'px') {
return v;
return _value;
}
if(unit == '%') {
return _value / 100 * base
}
// 如果是其他单位,可以继续添加对应的转换逻辑
}

View File

@ -2,12 +2,12 @@
<view v-if="returnCodeOrID === 'orgCode'">
<uni-data-picker v-model="selectDepartID" ref="depart" :openSearch="true" :ellipsis="true"
placeholder="请选择单位code" popup-title="请选择单位" :localdata="departList" @nodeclick="onnodeclick"
@popupclosed="onpopupclosed" :map="{'text':'title','value':'orgCode'}"></uni-data-picker>
@popupclosed="onpopupclosed" @change="onchange" :map="{'text':'title','value':'orgCode'}"></uni-data-picker>
</view>
<view v-else>
<uni-data-picker v-model="selectDepartID" ref="depart" :openSearch="true" :ellipsis="true" placeholder="请选择单位id"
popup-title="请选择单位" :localdata="departList" @nodeclick="onnodeclick" @popupclosed="onpopupclosed"
:map="{'text':'title','value':'id'}"></uni-data-picker>
@change="onchange" :map="{'text':'title','value':'id'}"></uni-data-picker>
</view>
</template>
@ -46,6 +46,8 @@
let selectDepartIDS = ref([]) //ID
let tempSelectDepartID = ref("") //ID
let departInfo = ref({}) //""
let $emit = defineEmits(['change']);
const getDepartList = () => {
@ -59,17 +61,22 @@
})
}
const onnodeclick = ((e) => {
// console.log(e)
departInfo.value = e;
if (props.returnCodeOrID = "orgCode") {
tempSelectDepartID.value = e.orgCode
} else {
tempSelectDepartID.value = e.value
}
})
const onchange = ((e) => {
$emit('change', e.detail.value[e.detail.value.length - 1].value, {})
})
const onpopupclosed = ((e) => {
selectDepartID.value = tempSelectDepartID.value
$emit('change', selectDepartID.value)
$emit('change', selectDepartID.value, departInfo)
})
onLoad((e) => {
getDepartList();

View File

@ -1,4 +1,24 @@
# trq-depart-select
# 1.0.1
更新,添加返回值,将整个机构对象返回父组件
```javascript
const onpopupclosed = ((e) => {
selectDepartID.value = tempSelectDepartID.value
$emit('change', selectDepartID.value, departInfo)
})
```
增加选择到最后层级触发的change时间返回数据到父组件的功能
```javascript
const onchange = ((e) => {
$emit('change', e.detail.value[e.detail.value.length - 1].value, {})
})
```
# 1.0
属性 returnCodeOrID 默认值 orgCode 组件返回单位的orgCode 不设置属性或设置为其他,组件返回 单位ID