Procházet zdrojové kódy

feat:完善 api 包下的注释

YunaiV před 4 měsíci
rodič
revize
bf0bea0e8e
2 změnil soubory, kde provedl 5 přidání a 11 odebrání
  1. 2 11
      src/api/infra/file/index.ts
  2. 3 0
      src/api/system/login-log/index.ts

+ 2 - 11
src/api/infra/file/index.ts

@@ -21,21 +21,12 @@ export interface FileCreateReqVO {
   size?: number
 }
 
-/**
- * 获取文件预签名地址
- *
- * @param name 文件名
- * @param directory 目录(可选)
- */
+/** 获取文件预签名地址 */
 export function getFilePresignedUrl(name: string, directory?: string) {
   return http.get<FilePresignedUrlRespVO>('/infra/file/presigned-url', { name, directory })
 }
 
-/**
- * 创建文件记录
- *
- * @param data 文件信息
- */
+/** 创建文件记录 */
 export function createFile(data: FileCreateReqVO) {
   return http.post<string>('/infra/file/create', data)
 }

+ 3 - 0
src/api/system/login-log/index.ts

@@ -1,6 +1,7 @@
 import type { PageParam, PageResult } from '@/http/types'
 import { http } from '@/http/http'
 
+/** 登录日志信息 */
 export interface LoginLog {
   id?: number
   traceId?: string
@@ -14,10 +15,12 @@ export interface LoginLog {
   createTime?: Date
 }
 
+/** 获取登录日志分页列表 */
 export function getLoginLogPage(params: PageParam) {
   return http.get<PageResult<LoginLog>>('/system/login-log/page', params)
 }
 
+/** 获取登录日志详情 */
 export function getLoginLog(id: number) {
   return http.get<LoginLog>(`/system/login-log/get?id=${id}`)
 }