This commit is contained in:
2024-09-25 16:35:07 +08:00
parent e952657166
commit 43f78fb688
14 changed files with 347 additions and 0 deletions

View File

@ -47,3 +47,13 @@ func SuccessData(c *gin.Context, data any) {
func Success(c *gin.Context) {
Send(c, http.StatusOK, OK, nil)
}
// Error 失败
func Error(c *gin.Context) {
Send(c, http.StatusOK, FAIL, nil)
}
// ErrorData 数据
func ErrorData(c *gin.Context, data any) {
Send(c, http.StatusOK, FAIL, data)
}