对接后端

This commit is contained in:
ovo 2024-12-06 22:01:50 +08:00
parent 1e49191b9a
commit 2f51cc4641
1 changed files with 25 additions and 1 deletions

View File

@ -2,6 +2,30 @@ import request from '@/utils/request'
import type { ApiResponse, PageResult } from './types'
// 定义接口的请求参数类型
/**
*
* :
* 使 interface
* 使 Partial<T>
* 使 0 | 1
* :
* request.get<T>() - GET请求
* request.post<T>() - POST请求
* request.put<T>() - PUT请求
* T
* :
* 使 try/catch
*
* :
* 使 FormData
* Content-Type
* :
* TypeScript API
*
*/
export interface LoginParams {
phone: string
password: string