Auto merge base into i18n

This commit is contained in:
GitHub Actions 2025-02-25 03:51:54 +00:00
commit c17d405456
2 changed files with 13 additions and 13 deletions

View File

@ -67,7 +67,7 @@
"build:quickapp-webview": "uni build -p quickapp-webview", "build:quickapp-webview": "uni build -p quickapp-webview",
"build:quickapp-webview-huawei": "uni build -p quickapp-webview-huawei", "build:quickapp-webview-huawei": "uni build -p quickapp-webview-huawei",
"build:quickapp-webview-union": "uni build -p quickapp-webview-union", "build:quickapp-webview-union": "uni build -p quickapp-webview-union",
"prepare": "git init && husky install ", "prepare": "git init && husky install",
"type-check": "vue-tsc --noEmit", "type-check": "vue-tsc --noEmit",
"cz": "czg", "cz": "czg",
"openapi-ts-request": "openapi-ts" "openapi-ts-request": "openapi-ts"

View File

@ -4,18 +4,18 @@ import { isMpWeixin } from './platform'
const getLastPage = () => { const getLastPage = () => {
// getCurrentPages() 至少有1个元素所以不再额外判断 // getCurrentPages() 至少有1个元素所以不再额外判断
// const lastPage = getCurrentPages().at(-1) // const lastPage = getCurrentPages().at(-1)
// 上面那个在低版本安卓中打包报错所以改用下面这个【虽然我加了src/interceptions/prototype.ts但依然报错】 // 上面那个在低版本安卓中打包报错,所以改用下面这个【虽然我加了 src/interceptions/prototype.ts但依然报错】
const pages = getCurrentPages() const pages = getCurrentPages()
return pages[pages.length - 1] return pages[pages.length - 1]
} }
/** 判断当前页面是否是tabbar页 */ /** 判断当前页面是否是 tabbar 页 */
export const getIsTabbar = () => { export const getIsTabbar = () => {
if (!tabBar) { if (!tabBar) {
return false return false
} }
if (!tabBar.list.length) { if (!tabBar.list.length) {
// 通常有tabBar的话list不能有空且至少有2个元素这里其实不用处理 // 通常有 tabBar 的话list 不能有空且至少有2个元素这里其实不用处理
return false return false
} }
const lastPage = getLastPage() const lastPage = getLastPage()
@ -25,8 +25,8 @@ export const getIsTabbar = () => {
/** /**
* path redirectPath * path redirectPath
* path /pages/login/index * path '/pages/login/index'
* redirectPath /pages/demo/base/route-interceptor * redirectPath '/pages/demo/base/route-interceptor'
*/ */
export const currRoute = () => { export const currRoute = () => {
const lastPage = getLastPage() const lastPage = getLastPage()
@ -73,9 +73,9 @@ export const getUrlObj = (url: string) => {
return { path, query } return { path, query }
} }
/** /**
* pages * pages
* key作为判断依据 needLogin, route-block 使 * key needLogin, route-block 使
* keypages key, key * key pages key, key
*/ */
export const getAllPages = (key = 'needLogin') => { export const getAllPages = (key = 'needLogin') => {
// 这里处理主包 // 这里处理主包
@ -108,19 +108,19 @@ export const getAllPages = (key = 'needLogin') => {
} }
/** /**
* pages * pages
* path * path
*/ */
export const getNeedLoginPages = (): string[] => getAllPages('needLogin').map((page) => page.path) export const getNeedLoginPages = (): string[] => getAllPages('needLogin').map((page) => page.path)
/** /**
* pages * pages
* path * path
*/ */
export const needLoginPages: string[] = getAllPages('needLogin').map((page) => page.path) export const needLoginPages: string[] = getAllPages('needLogin').map((page) => page.path)
/** /**
* BaseUrl * baseUrl
*/ */
export const getEnvBaseUrl = () => { export const getEnvBaseUrl = () => {
// 请求基准地址 // 请求基准地址
@ -149,7 +149,7 @@ export const getEnvBaseUrl = () => {
} }
/** /**
* UPLOAD_BASEURL * UPLOAD_BASEURL
*/ */
export const getEnvBaseUploadUrl = () => { export const getEnvBaseUploadUrl = () => {
// 请求基准地址 // 请求基准地址