diff --git a/env/.env b/env/.env index fbfe786..e719d4e 100644 --- a/env/.env +++ b/env/.env @@ -2,7 +2,7 @@ VITE_APP_TITLE = 'unibest' VITE_APP_PORT = 9000 VITE_UNI_APPID = '__UNI__D1E5001' -VITE_WX_APPID = 'wxe2428e8fe6767e45' +VITE_WX_APPID = 'wxdee751952c8c2027' # h5部署网站的base,配置到 manifest.config.ts 里的 h5.router.base VITE_APP_PUBLIC_BASE=/ diff --git a/src/api/login.ts b/src/api/login.ts index ad5b26d..069ba64 100644 --- a/src/api/login.ts +++ b/src/api/login.ts @@ -1,4 +1,10 @@ -import type { ICaptcha, IUpdateInfo, IUpdatePassword, IUserInfoVo, IUserLogin } from './login.typings' +import type { + ICaptcha, + IUpdateInfo, + IUpdatePassword, + IUserInfoVo, + IUserLogin, +} from './login.typings' import { http } from '@/utils/http' /** @@ -63,8 +69,8 @@ export function getWxCode() { return new Promise((resolve, reject) => { uni.login({ provider: 'weixin', - success: res => resolve(res), - fail: err => reject(new Error(err)), + success: (res) => resolve(res), + fail: (err) => reject(new Error(err)), }) }) } @@ -81,3 +87,7 @@ export function getWxCode() { export function wxLogin(data: { code: string }) { return http.post('/user/wxLogin', data) } + +export function routineLoginApi(data: { code: string }) { + return http.post('/api/auth/routineLogin', data) +} diff --git a/src/manifest.json b/src/manifest.json index 3ae77af..80c0869 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -83,7 +83,7 @@ }, "quickapp": {}, "mp-weixin": { - "appid": "wxe2428e8fe6767e45", + "appid": "wxdee751952c8c2027", "setting": { "urlCheck": false, "es6": true, diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index 9e95928..460227a 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -101,7 +101,7 @@ @@ -426,7 +426,7 @@