diff --git a/.env.development b/.env.development
index b6fc12c..e059f52 100644
--- a/.env.development
+++ b/.env.development
@@ -1,3 +1,4 @@
# 开发环境
# 请求接口地址
VITE_REQUEST_BASE_URL = https://36.112.48.190
+#VITE_REQUEST_BASE_URL = http://10.75.15.247:8080
diff --git a/.env.production b/.env.production
index 5ca2ca3..9338f38 100644
--- a/.env.production
+++ b/.env.production
@@ -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
\ No newline at end of file
diff --git a/.gitignore b/.gitignore
index ee4ee9f..c768048 100644
--- a/.gitignore
+++ b/.gitignore
@@ -61,3 +61,5 @@
/node_modules/.vite/deps/dayjs.js
/node_modules/.vite/deps/dayjs.js.map
/node_modules/.vite/deps/package.json
+/uni_modules
+/node_modules
diff --git a/api/renyuan.js b/api/renyuan.js
index 6990e57..2eb4f44 100644
--- a/api/renyuan.js
+++ b/api/renyuan.js
@@ -80,4 +80,20 @@ export function cxcRyDataTongji(url, parm) { // 员工信息统计
method: 'get',
data: parm
})
+}
+
+export function cxcRyDatAstatistics(parm) { // 员工分组统计
+ return https({
+ url: '/cxc_rlzy.zb/cxcRlzyZb/statistics',
+ method: 'get',
+ data: parm
+ })
+}
+
+export function cxcRyDatAstatisticsDetails(parm) { // 员工信息统计
+ return https({
+ url: '/cxc_rlzy.zb/cxcRlzyZb/details',
+ method: 'get',
+ data: parm
+ })
}
\ No newline at end of file
diff --git a/pages.json b/pages.json
index 52fd167..571274f 100644
--- a/pages.json
+++ b/pages.json
@@ -233,6 +233,14 @@
"navigationBarTitleText": "人员年龄分组统计信息",
"navigationBarTextStyle": "white"
+ }
+ },
+ {
+ "path": "pages/views/renliziyuan/renyuanxinxi/qttongji",
+ "style": {
+ "navigationBarTitleText": "其他统计信息",
+ "navigationBarTextStyle": "white"
+
}
}
],
diff --git a/pages/views/renliziyuan/renyuanxinxi/index.vue b/pages/views/renliziyuan/renyuanxinxi/index.vue
index 7a820b5..782e15d 100644
--- a/pages/views/renliziyuan/renyuanxinxi/index.vue
+++ b/pages/views/renliziyuan/renyuanxinxi/index.vue
@@ -8,10 +8,13 @@
-
+
+
+
+
+
-
@@ -29,6 +32,12 @@
url: "/pages/views/renliziyuan/renyuanxinxi/tongji"
})
}
+
+ function toQtTongji() {
+ uni.navigateTo({
+ url: "/pages/views/renliziyuan/renyuanxinxi/qttongji"
+ })
+ }
\ No newline at end of file
diff --git a/uni_modules/lime-shared/addUnit/index.ts b/uni_modules/lime-shared/addUnit/index.ts
index 25bc2b1..78476c9 100644
--- a/uni_modules/lime-shared/addUnit/index.ts
+++ b/uni_modules/lime-shared/addUnit/index.ts
@@ -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 {
diff --git a/uni_modules/lime-shared/animation/ease.ts b/uni_modules/lime-shared/animation/ease.ts
index 9358c6d..0af156e 100644
--- a/uni_modules/lime-shared/animation/ease.ts
+++ b/uni_modules/lime-shared/animation/ease.ts
@@ -1,2 +1,3 @@
import {cubicBezier} from './bezier';
-export let ease = cubicBezier(0.25, 0.1, 0.25, 1);
\ No newline at end of file
+export let ease = cubicBezier(0.25, 0.1, 0.25, 1);
+export let linear = cubicBezier(0,0,1,1);
\ No newline at end of file
diff --git a/uni_modules/lime-shared/animation/index.ts b/uni_modules/lime-shared/animation/index.ts
index 5665983..5979064 100644
--- a/uni_modules/lime-shared/animation/index.ts
+++ b/uni_modules/lime-shared/animation/index.ts
@@ -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
diff --git a/uni_modules/lime-shared/animation/useTransition.ts b/uni_modules/lime-shared/animation/useTransition.ts
index 818e591..b9502c2 100644
--- a/uni_modules/lime-shared/animation/useTransition.ts
+++ b/uni_modules/lime-shared/animation/useTransition.ts
@@ -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), options : UseTransitionOptions) : Ref {
const current = ref(0)
@@ -47,7 +47,7 @@ export function useTransition(percent : Ref|(() => number), options : Us
// #endif
-// #ifdef APP-IOS || APP-ANDROID
+// #ifdef UNI-APP-X && APP
type UseTransitionReturnType = Ref
export function useTransition(source : any, options : UseTransitionOptions) : UseTransitionReturnType {
const outputRef : Ref = 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){
+ watch(source as Ref, watchFunc, { immediate })
}
const stop = ()=>{
diff --git a/uni_modules/lime-shared/animation/uvue.uts b/uni_modules/lime-shared/animation/uvue.uts
index 9a10db0..37e2bc9 100644
--- a/uni_modules/lime-shared/animation/uvue.uts
+++ b/uni_modules/lime-shared/animation/uvue.uts
@@ -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;
diff --git a/uni_modules/lime-shared/arrayBufferToFile/index.ts b/uni_modules/lime-shared/arrayBufferToFile/index.ts
index fd67048..49ee530 100644
--- a/uni_modules/lime-shared/arrayBufferToFile/index.ts
+++ b/uni_modules/lime-shared/arrayBufferToFile/index.ts
@@ -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
\ No newline at end of file
diff --git a/uni_modules/lime-shared/base64ToPath/index.ts b/uni_modules/lime-shared/base64ToPath/index.ts
index 28a3bf5..af9a9d2 100644
--- a/uni_modules/lime-shared/base64ToPath/index.ts
+++ b/uni_modules/lime-shared/base64ToPath/index.ts
@@ -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
diff --git a/uni_modules/lime-shared/canIUseCanvas2d/index.ts b/uni_modules/lime-shared/canIUseCanvas2d/index.ts
index 95211d1..be5623a 100644
--- a/uni_modules/lime-shared/canIUseCanvas2d/index.ts
+++ b/uni_modules/lime-shared/canIUseCanvas2d/index.ts
@@ -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
}
diff --git a/uni_modules/lime-shared/changelog.md b/uni_modules/lime-shared/changelog.md
index 9b9b7dc..a5a6125 100644
--- a/uni_modules/lime-shared/changelog.md
+++ b/uni_modules/lime-shared/changelog.md
@@ -1,3 +1,26 @@
+
+## 0.2.7(2025-01-17)
+- fix: 针对canvas 平台判断优化
+## 0.2.6(2025-01-09)
+- feat: 增加`areaData`中国省市区数据
+## 0.2.5(2025-01-07)
+- fix: animation在app上类型问题
+## 0.2.4(2025-01-04)
+- feat: getRect类型问题
+## 0.2.3(2025-01-01)
+- chore: unitConvert使用uni.rpx2px
+## 0.2.2(2024-12-11)
+- chore: 动画使用`requestAnimationFrame`
+## 0.2.1(2024-11-20)
+- feat: 增加`characterLimit`
+## 0.2.0(2024-11-14)
+- fix: vue2的类型问题
+## 0.1.9(2024-11-14)
+- feat: 增加`shuffle`
+## 0.1.8(2024-10-08)
+- fix: vue2 条件编译 // #ifdef APP-IOS || APP-ANDROID 会生效
+## 0.1.7(2024-09-23)
+- fix: raf 类型跟随版本变更
## 0.1.6(2024-07-24)
- fix: vue2 app ts需要明确的后缀,所有补全
- chore: 减少依赖
diff --git a/uni_modules/lime-shared/cloneDeep/index.ts b/uni_modules/lime-shared/cloneDeep/index.ts
index 03f85cd..3428c49 100644
--- a/uni_modules/lime-shared/cloneDeep/index.ts
+++ b/uni_modules/lime-shared/cloneDeep/index.ts
@@ -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
\ No newline at end of file
diff --git a/uni_modules/lime-shared/components/lime-shared/lime-shared.vue b/uni_modules/lime-shared/components/lime-shared/lime-shared.vue
index 284e8f0..e2d7fe2 100644
--- a/uni_modules/lime-shared/components/lime-shared/lime-shared.vue
+++ b/uni_modules/lime-shared/components/lime-shared/lime-shared.vue
@@ -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({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({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 => {
- 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 => {
+ // 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(5))
- console.log('toBoolean', toBoolean(5))
- console.log('toNumber', toNumber('5'))
- console.log('unitConvert', unitConvert('5'))
+ // console.log('toArray', toArray(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 {
+
+ }