首次完整推送,

V:1.20240808.006
This commit is contained in:
fm453
2024-08-13 18:32:37 +08:00
parent 15be3e9373
commit c62d15b288
939 changed files with 111777 additions and 0 deletions

191
lang/en.js Normal file
View File

@ -0,0 +1,191 @@
export default {
tabbar: 'Home,Work,Mine',
agreementsTitle: 'User service agreement,Privacy policy',
common: {
wechatFriends: "friends",
wechatBbs: "bbs",
weibo: "weibo",
more: "more",
agree: "agree",
copy: "copy",
wechatApplet: "applet",
cancelShare: "cancel sharing",
updateSucceeded: "update succeeded",
phonePlaceholder: "Please enter your mobile phone number",
verifyCodePlaceholder: "Please enter the verification code",
newPasswordPlaceholder: "Please enter a new password",
confirmNewPasswordPlaceholder: "Please confirm the new password",
confirmPassword: "Please confirm the password",
verifyCodeSend: "Verification code has been sent to via SMS",
passwordDigits: "The password is 6 - 20 digits",
getVerifyCode: "Get Code",
noAgree: "You have not agreed to the privacy policy agreement",
gotIt: "got it",
login: "sign in",
error: "error",
complete: "complete",
submit: "Submit",
formatErr: "Incorrect mobile phone number format",
sixDigitCode: "Please enter a 6-digit verification code",
resetNavTitle: "Reset password"
},
list: {
inputPlaceholder: "Please enter the search content",
},
search: {
cancelText: "cancel",
searchHistory: "search history",
searchDiscovery: "search discovery",
deleteAll: "delete all",
delete: "delete",
deleteTip: "Are you sure to clear the search history ?",
complete: "complete",
searchHiddenTip: "Current search found hidden",
},
grid: {
grid: "Grid Assembly",
visibleToAll: "Visible to all",
invisibleToTourists: "Invisible to tourists",
adminVisible: "Admin visible",
clickTip: "Click the",
clickTipGrid: "grid",
},
mine: {
showText: "Text",
signIn: "Check In Reward",
signInByAd: "Check In Reward By AD",
toEvaluate: "To Evaluate",
readArticles: "Read Articles",
myScore: "My Score",
invite: "Invite Friends",
feedback: "Problems And Feedback",
settings: "Settings",
about: "About",
checkUpdate: "Check for Updates",
clicked: "You Clicked",
checkScore: "Please check your points after logging in",
currentScore: "The current score is ",
noScore: "There are currently no points",
notLogged: "not logged in",
},
userinfo: {
navigationBarTitle: "My Profile",
ProfilePhoto: "Profile Photo",
nickname: "Nickname",
notSet: "not set",
phoneNumber: "Phone Number",
notSpecified: "Not Specified",
setNickname: "Set Nickname ",
setNicknamePlaceholder: "Please enter a nickname to set",
bindPhoneNumber: "One click binding of local number",
bindOtherLogin: "Other number binding",
noChange: "No change",
uploading: "uploading",
requestFail: "Request for service failed",
setting: "setting",
deleteSucceeded: "Delete succeeded",
setSucceeded: "Set successfully",
},
smsCode: {
resendVerifyCode: "resend",
phoneErrTip: "Mobile phone number format error",
sendSuccessTip: "SMS verification code sent successfully",
},
loadMore: {
noData: "No Data",
noNetwork: "Network error",
toSet: "Go to settings",
error: "error",
},
uniFeedback: {
navigationBarTitle: "Problems and feedback",
msgTitle: "Message content",
imgTitle: "Picture list",
contacts: "contacts",
phone: "contact number",
submit: "submit",
},
settings: {
navigationBarTitle: "Settings",
userInfo: "Personal Data",
changePassword: "change password",
clearTmp: "clean cache",
pushServer: "push function",
fingerPrint: "fingerprint unlock",
facial: "face unlock",
deactivate: "Deactivate",
logOut: "Logout",
login: "Login",
changeLanguage: "Language",
please: "please",
successText: "success",
failTip: "Authentication failed. Please try again",
authFailed: "authentication failed",
deviceNoOpen: "The device is not turned on",
fail: "fail",
tips: "tips",
exitLogin: "Do you want to log out",
cancelText: "cancel",
confirmText: "confirm",
clearing: "clearing",
clearedSuccessed: "Cleared successfully",
},
deactivate: {
cancelText: "cancel",
nextStep: "next step",
navigationBarTitle: "Logout prompt"
},
about: {
sacnQR: "Scan the QR Code and your friends can also download it",
client: "applCantion",
and: "And",
about: "About",
},
invite: {
download: "Download",
},
login: {
phoneLogin: "After logging in, you can show yourself",
phoneLoginTip: "Unregistered mobile phone numbers will be automatically registered after verification",
getVerifyCode: "Get Code",
},
uniQuickLogin: {
accountLogin: "Account",
SMSLogin: "SMS",
wechatLogin: "wechat",
appleLogin: "Apple",
oneClickLogin: "One click login",
QQLogin: "QQ",
xiaomiLogin: "Xiaomi",
getProviderFail: "Failed to get service provider",
loginErr: "Login service initialization error",
chooseOtherLogin: "Click the third-party login",
},
pwdLogin: {
pwdLogin: "User name password login",
placeholder: "Please enter mobile number / user name",
passwordPlaceholder: "Please input a password",
verifyCodePlaceholder: "Please enter the verification code",
login: "sign in",
forgetPassword: "Forget password",
register: "Registered account",
},
register: {
navigationBarTitle: "register",
usernamePlaceholder: "Please enter user name",
nicknamePlaceholder: "Please enter user nickname",
passwordDigitsPlaceholder: "Please enter a 6-20 digit password",
passwordAgain: "Enter the password again",
registerAndLogin: "Register and log in",
},
listDetail: {
follow: "Click follow",
newsErr: "Error, news ID is empty",
},
newsLog: {
navigationBarTitle: "Reading Log"
},
bindMobile: {
navigationBarTitle: "Bind Mobile"
}
}

100
lang/i18n.js Normal file
View File

@ -0,0 +1,100 @@
import langEn from './en'
import zhHans from './zh-Hans'
import _app_Config from '../app.config.js'
const {
i18n: {
enable: i18nEnable
}
} = _app_Config
const messages = {
'en': langEn,
'zh-Hans': zhHans
}
let currentLang
if (i18nEnable) {
currentLang = uni.getStorageSync('CURRENT_LANG')
} else {
currentLang = "zh-Hans"
}
// console.log(uni.getStorageSync('CURRENT_LANG'),currentLang);
if (!currentLang) {
if (uni.getLocale) {
console.log('获取应用语言:', uni.getLocale());
let language = 'en'
if (uni.getLocale() != 'en') {
language = 'zh-Hans'
}
uni.setStorageSync('CURRENT_LANG', language)
currentLang = language
} else {
uni.getSystemInfo({
success: function(res) {
console.log('获取设备信息:', res);
let language = 'zh-Hans'
if (res.language == 'en') {
language = 'en'
}
uni.setStorageSync('CURRENT_LANG', language)
currentLang = language
},
fail: (err) => {
console.error(err)
}
})
}
}
let i18nConfig = {
locale: currentLang, // set locale
messages // set locale messages
}
// #ifdef VUE2
import Vue from 'vue'
import VueI18n from 'vue-i18n'
Vue.use(VueI18n)
const i18n = new VueI18n(i18nConfig)
// #endif
// #ifdef VUE3
import {
createI18n
} from 'vue-i18n'
const i18n = createI18n(i18nConfig)
// #endif
export default i18n
if (i18nEnable) {
console.log(`
你已开启多语言国际化将自动根据语言获取【lang/en.js】或【lang/en.js】文件中配置的tabbar的值
覆盖你在pages.json中的tabbar的值
如果你不需要多语言国际化请打开配置文件app.config.js找到 -> i18n -> enable把值设置为false
`);
let initLanguageAfter = () => {
function $i18n(e) {
// #ifdef VUE3
return i18n.global.messages[i18n.global.locale][e]
// #endif
return i18n.messages[i18n.locale][e]
}
setTimeout(function() {
//底部tabbar更新
$i18n('tabbar').split(',').forEach((text, index) => {
// console.log(text);
uni.setTabBarItem({
index,
text,
complete: e => {
// console.log("e: " + JSON.stringify(e));
}
})
})
}, 1)
}
initLanguageAfter()
uni.$on('changeLanguage', e => {
console.log('changeLanguage', e);
initLanguageAfter(e)
})
}

198
lang/zh-Hans.js Normal file
View File

@ -0,0 +1,198 @@
export default {
tabbar: '首页,功能,我的',
agreementsTitle: '用户服务协议,隐私政策',
common: {
wechatFriends: "微信好友",
wechatBbs: "微信朋友圈",
weibo: "微博",
more: "更多",
agree: "同意",
copy: "复制",
wechatApplet: "微信小程序",
cancelShare: "取消分享",
updateSucceeded: "更新成功",
phonePlaceholder: "请输入手机号",
verifyCodePlaceholder: "请输入验证码",
newPasswordPlaceholder: "请输入新密码",
confirmNewPasswordPlaceholder: "请确认新密码",
confirmPassword: "请确认密码",
verifyCodeSend: "验证码已通过短信发送至",
passwordDigits: "密码为6 - 20位",
getVerifyCode: "获取验证码",
noAgree: "你未同意隐私政策协议",
gotIt: "知道了",
login: "登录",
error: "错误",
complete: "完成",
submit: "提交",
formatErr: "手机号码格式不正确",
sixDigitCode: "请输入6位验证码",
resetNavTitle: "重置密码"
},
list: {
inputPlaceholder: "请输入搜索内容",
},
search: {
cancelText: '取消',
searchHistory: "搜索历史",
searchDiscovery: "搜索发现",
deleteAll: "全部删除",
delete: "删除",
deleteTip: "确认清空搜索历史吗?",
complete: "完成",
searchHiddenTip: "当前搜索发现已隐藏",
},
grid: {
grid: "宫格组件",
visibleToAll: "所有人可见",
invisibleToTourists: "游客不可见",
adminVisible: "管理员可见",
clickTip: "点击第",
clickTipGrid: "个宫格",
},
mine: {
showText: "文字",
scanText: "扫码",
appsText: "应用",
scoreText: "积分",
noticeText: "消息",
signIn: "普通签到",
signInByAd: "看广告签到",
toEvaluate: "去评分",
readArticles: "阅读过的文章",
myScore: "我的积分",
invite: "分销推荐",
feedback: "问题与反馈",
settings: "设置",
checkUpdate: "检查更新",
about: "关于",
clicked: "你点击了",
checkScore: "请登录后查看积分",
currentScore: "当前积分为",
noScore: "当前无积分",
notLogged: "未登录",
newsList: "新闻",
articleList: "文章",
},
userinfo: {
navigationBarTitle: "个人资料",
ProfilePhoto: "头像",
nickname: "昵称",
notSet: "未设置",
phoneNumber: "手机号",
notSpecified: "未绑定",
setNickname: "设置昵称",
setNicknamePlaceholder: "请输入要设置的昵称",
bindPhoneNumber: "本机号码一键绑定",
bindOtherLogin: "其他号码绑定",
noChange: "没有变化",
uploading: "正在上传",
requestFail: "请求服务失败",
setting: "设置中",
deleteSucceeded: "删除成功",
setSucceeded: "设置成功",
},
smsCode: {
resendVerifyCode: "重新发送",
phoneErrTip: "手机号格式错误",
sendSuccessTip: "短信验证码发送成功",
},
loadMore: {
noData: "暂无数据",
noNetwork: "网络异常",
toSet: "前往设置",
error: "错误",
},
uniFeedback: {
navigationBarTitle: "问题与反馈",
msgTitle: "留言内容",
imgTitle: "图片列表",
contacts: "联系人",
phone: "联系电话",
submit: "提交",
},
settings: {
navigationBarTitle: "设置",
userInfo: "账号资料",
changePassword: "修改密码",
clearTmp: "清理缓存",
pushServer: "推送功能",
fingerPrint: "指纹解锁",
facial: "人脸解锁",
deactivate: "注销账号",
logOut: "退出登录",
login: "登录",
failTip: "认证失败请重试",
authFailed: "认证失败",
changeLanguage: "切换语言",
please: "请用",
successText: "成功",
deviceNoOpen: "设备未开启",
fail: "失败",
tips: "提示",
exitLogin: "是否退出登录?",
clearing: "清除中",
clearedSuccessed: "清除成功",
confirmText: "确定",
cancelText: '取消',
},
deactivate: {
cancelText: '取消',
nextStep: "下一步",
navigationBarTitle: "注销提示"
},
about: {
sacnQR: "扫描二维码,您的朋友也可以下载",
client: "客户端",
and: "和",
about: "关于",
},
invite: {
download: "下载",
},
login: {
phoneLogin: "登录后即可展示自己",
phoneLoginTip: "未注册的手机号验证通过后将自动注册",
getVerifyCode: "获取验证码",
},
uniQuickLogin: {
accountLogin: "账号登录",
SMSLogin: "短信验证码",
wechatLogin: "微信登录",
appleLogin: "苹果登录",
oneClickLogin: "一键登录",
QQLogin: "QQ登录",
xiaomiLogin: "小米登录",
getProviderFail: "获取服务供应商失败",
loginErr: "登录服务初始化错误",
chooseOtherLogin: "点击了第三方登录",
},
pwdLogin: {
pwdLogin: "用户名密码登录",
placeholder: "请输入手机号/用户名",
passwordPlaceholder: "请输入密码",
verifyCodePlaceholder: "请输入验证码",
login: "登录",
forgetPassword: "忘记密码",
register: "注册账号",
},
register: {
navigationBarTitle: "注册",
usernamePlaceholder: "请输入用户名",
nicknamePlaceholder: "请输入用户昵称",
registerAndLogin: "注册并登录",
passwordDigitsPlaceholder: "请输入6-20位密码",
passwordAgain: "再次输入密码",
},
listDetail: {
follow: "点击关注",
newsErr: "出错了新闻ID为空",
},
newsLog: {
navigationBarTitle: "阅读记录"
},
bindMobile: {
navigationBarTitle: "绑定手机号码"
}
}