| | |
| | | import Taro from '@tarojs/taro'; |
| | | import { defineStore } from 'pinia'; |
| | | import { store } from '@/stores'; |
| | | import * as settingsServices from '@12333/services/apiV2/settings'; |
| | | |
| | | export interface Options { |
| | | path: string; |
| | |
| | | redirectPath: string; |
| | | isTabSwitch: boolean; |
| | | isFirstEnter: boolean; |
| | | isWeappCheck: boolean; |
| | | } |
| | | |
| | | export const useSystemStore = defineStore({ |
| | |
| | | menuButtonTop: 0, |
| | | |
| | | isFirstEnter: true, |
| | | |
| | | isWeappCheck: true, |
| | | }), |
| | | |
| | | actions: { |
| | | async getAppConfig() { |
| | | try { |
| | | let res = await settingsServices.getWxmpSettings({}); |
| | | this.isWeappCheck = res.wxmpAuditInProcess; |
| | | } catch (error) {} |
| | | }, |
| | | |
| | | init(options: Options) { |
| | | this.options = options; // 放一下页面相关的数据例如scene等 页面高度之类的不存! |
| | | }, |