1
0
mirror of https://github.com/ialley-workshop-open/uni-halo.git synced 2026-06-12 21:29:31 +08:00

v1.0.0-beta 源码正式开源

This commit is contained in:
小莫唐尼
2022-12-06 15:08:29 +08:00
commit 636ae7b169
461 changed files with 116817 additions and 0 deletions
+26
View File
@@ -0,0 +1,26 @@
export const CheckNetWork = () => {
let _text = ''
uni.getNetworkType({
success: (res) => {
switch (res) {
case '2g':
case '3g':
_text = '当前网络较慢,请稍等...'
break;
case 'none':
_text = '啊偶,您的网络似乎断开啦~'
break;
}
if (_text) {
uni.$eShowModal({
title: '提示',
content: _text,
showCancel: false,
cancelColor: '#999999',
confirmText: '知道啦',
confirmColor: '#03a9f4'
}).then(res => {}).catch(err => {})
}
}
})
}