refactor: 接口命名规则统一为kebab-case串式命名法

This commit is contained in:
xiaoxian521
2023-09-27 15:09:15 +08:00
parent 73b5d3ec41
commit 320ee2b206
17 changed files with 26 additions and 26 deletions

View File

@@ -10,7 +10,7 @@ type Result = {
/** 卡片列表 */
export const getCardList = (data?: object) => {
return http.request<Result>("post", "/getCardList", { data });
return http.request<Result>("post", "/get-card-list", { data });
};
/** 版本日志 */

View File

@@ -7,5 +7,5 @@ type Result = {
/** 地图数据 */
export const mapJson = (params?: object) => {
return http.request<Result>("get", "/getMapInfo", { params });
return http.request<Result>("get", "/get-map-info", { params });
};

View File

@@ -6,5 +6,5 @@ type Result = {
};
export const getAsyncRoutes = () => {
return http.request<Result>("get", "/getAsyncRoutes");
return http.request<Result>("get", "/get-async-routes");
};

View File

@@ -35,5 +35,5 @@ export const getLogin = (data?: object) => {
/** 刷新token */
export const refreshTokenApi = (data?: object) => {
return http.request<RefreshTokenResult>("post", "/refreshToken", { data });
return http.request<RefreshTokenResult>("post", "/refresh-token", { data });
};