refactor: ♻️ aPI 文件根据模块划分

This commit is contained in:
ray
2024-10-18 22:28:02 +08:00
parent 0cc300a032
commit af460b5dc3
43 changed files with 150 additions and 297 deletions

View File

@@ -1,4 +1,4 @@
import UserAPI, { type UserForm } from "@/api/user";
import UserAPI, { type UserForm } from "@/api/system/user";
import type { IModalConfig } from "@/components/CURD/types";
const modalConfig: IModalConfig<UserForm> = {

View File

@@ -1,6 +1,6 @@
import UserAPI from "@/api/user";
import UserAPI from "@/api/system/user";
import RoleAPI from "@/api/role";
import type { UserPageQuery } from "@/api/user";
import type { UserPageQuery } from "@/api/system/user";
import type { IContentConfig } from "@/components/CURD/types";
const contentConfig: IContentConfig<UserPageQuery> = {

View File

@@ -1,4 +1,4 @@
import UserAPI, { type UserForm } from "@/api/user";
import UserAPI, { type UserForm } from "@/api/system/user";
import type { IModalConfig } from "@/components/CURD/types";
import { DeviceEnum } from "@/enums/DeviceEnum";
import { useAppStore } from "@/store";

View File

@@ -1,4 +1,4 @@
import DeptAPI from "@/api/dept";
import DeptAPI from "@/api/system/dept";
import type { ISearchConfig } from "@/components/CURD/types";
const searchConfig: ISearchConfig = {

View File

@@ -57,7 +57,7 @@
@submit-click="handleSubmitClick"
>
<template #gender="scope">
<dictionary v-model="scope.formData[scope.prop]" code="gender" />
<Dict v-model="scope.formData[scope.prop]" code="gender" />
</template>
</page-modal>
@@ -68,7 +68,7 @@
@submit-click="handleSubmitClick"
>
<template #gender="scope">
<dictionary v-model="scope.formData[scope.prop]" code="gender" />
<Dict v-model="scope.formData[scope.prop]" code="gender" />
</template>
</page-modal>
</template>
@@ -89,9 +89,9 @@
</template>
<script setup lang="ts">
import UserAPI from "@/api/user";
import DeptAPI from "@/api/dept";
import RoleAPI from "@/api/role";
import UserAPI from "@/api/system/user";
import DeptAPI from "@/api/system/dept";
import RoleAPI from "@/api/system/role";
import type { IObject, IOperatData } from "@/components/CURD/types";
import usePage from "@/components/CURD/usePage";
import addModalConfig from "./config/add";