1234567891011121314151617181920212223242526272829303132 |
- import { Dict_Apis } from "@/dict";
- import { initAuth } from "@queenjs-modules/auth";
- export function initAuthDef() {
- const auth = initAuth({
- config: {
- httpConfig: {
- baseURL: Dict_Apis.auth,
- },
- key: "queenshow",
- loginPath: "/login",
- loginJumpPath: "/",
- logoutJumpPath: "/login",
- needCompanyLogin: false,
- needRegister: true,
- needResetPwd: true,
- regInfo: {
- key: "queenshow",
- },
- },
- https: {
- getProfile() {
- return (this as any).request("/profile?appKey=" + this.config.key, {
- method: "GET",
- silence: false,
- });
- },
- },
- });
- auth.actions.initUser();
- }
|