import { action, makeObservable, observable } from "mobx"; // 档案文件夹 import baseHttp from "@/service/base"; import BaseStore from "./baseStore"; import { TagDataType } from "@/model/userModel"; class HomeConfig { static os: string = "public/os" static tr: string = "public/tr" static af: string = "public/af" static mm: string = "public/mm" static rm: string = "public/rm" static ae: string = "public/ae" } class HomeStore extends BaseStore { constructor() { super(HomeConfig) makeObservable(this, { getOgCount: action, ogMap: observable, alist: observable, }) } async getOgCount() { let res = await baseHttp.get(HomeConfig.os, {}); this.ogMap = res.data.record } async getTr() { return await baseHttp.get(HomeConfig.tr, {}); } async getAf() { return await baseHttp.get(HomeConfig.af, {}); } async getMm() { return await baseHttp.get(HomeConfig.mm, {}); } async getRm() { return await baseHttp.get(HomeConfig.rm, {}); } async getAe() { return await baseHttp.get(HomeConfig.ae, {}); } ogMap!: Object; alist!: Array; } const homeStore = new HomeStore() export default homeStore;