fix:: 请求响应码用常量

This commit is contained in:
TsMask
2025-06-07 16:32:04 +08:00
parent c67fbb7998
commit 33b95a6e30
73 changed files with 441 additions and 375 deletions

View File

@@ -1,22 +1,5 @@
package resp
const (
// CODE_ERROR 响应-code错误失败
CODE_ERROR = 400001
// MSG_ERROR 响应-msg错误失败
MSG_ERROR = "error"
// CODE_SUCCESS 响应-msg正常成功
CODE_SUCCESS = 200001
// MSG_SUCCCESS 响应-code正常成功
MSG_SUCCCESS = "success"
// 响应-code加密数据
CODE_ENCRYPT = 200999
// 响应-msg加密数据
MSG_ENCRYPT = "encrypt"
)
// Resp 响应结构体
type Resp struct {
Code int `json:"code"` // 响应状态码