修改状态码

This commit is contained in:
eson
2023-06-06 17:36:10 +08:00
parent b8790b7f79
commit ab9df9bc42
6 changed files with 10 additions and 9 deletions

View File

@@ -7,6 +7,7 @@ type StatusResponse struct {
}
var (
StatusOK = &StatusResponse{200, "success"} // 成功
DefaultError = &StatusResponse{510, "unknown error"} // 错误
CodeOK = &StatusResponse{200, "success"} // 成功
CodeServiceErr = &StatusResponse{510, "unknown error"} // 错误
CodeUnAuth = &StatusResponse{401, "unauthorized"} // 未授权
)