fix: 修复扫码进入的问题
This commit is contained in:
17
src/app.ts
17
src/app.ts
@@ -24,19 +24,6 @@ class App extends Component<AppProps> {
|
||||
// 这里可以自定义弹窗(或直接默认同意)
|
||||
resolve({ event: 'agree' }); // 同意隐私协议
|
||||
});
|
||||
|
||||
// Taro.loadFontFace({
|
||||
// family: 'Quicksand',
|
||||
// source: 'url("https://bimwe.oss-cn-shanghai.aliyuncs.com/front/ball/other/57dc951f-f10e-45b7-9157-0b1e468187fd.ttf")',
|
||||
// global: true, // 全局生效
|
||||
// success(res) {
|
||||
// console.log('字体加载成功', res);
|
||||
// },
|
||||
// fail(err) {
|
||||
// console.error('字体加载失败', err);
|
||||
// }
|
||||
// })
|
||||
sceneRedirectLogic(options.query, options.path);
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
@@ -45,7 +32,9 @@ class App extends Component<AppProps> {
|
||||
// this.getLocation()
|
||||
}
|
||||
|
||||
componentDidShow() { }
|
||||
componentDidShow(options) {
|
||||
sceneRedirectLogic(options.query, options.path);
|
||||
}
|
||||
|
||||
componentDidHide() { }
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@ import Taro from "@tarojs/taro";
|
||||
|
||||
// 普通函数,不调用 useLoad
|
||||
export const sceneRedirectLogic = (options, defaultPage: string) => {
|
||||
console.log(options, 12345)
|
||||
if (!options.scene) return;
|
||||
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user