refactor: method name

This commit is contained in:
zchengo
2023-01-25 16:10:16 +08:00
parent 35886fde4f
commit def12ca66e
5 changed files with 27 additions and 27 deletions
+2 -2
View File
@@ -32,13 +32,13 @@ func (n *NoticeApi) Update(context *gin.Context) {
response.Result(errCode, nil, context)
}
func (n *NoticeApi) GetCount(context *gin.Context) {
func (n *NoticeApi) GetUnReadCount(context *gin.Context) {
uid, _ := strconv.Atoi(context.Request.Header.Get("uid"))
if uid <= 0 {
response.Result(response.ErrCodeParamInvalid, nil, context)
return
}
unReadNotice, errCode := n.noticeService.UnReadCount(int64(uid))
unReadNotice, errCode := n.noticeService.GetUnReadCount(int64(uid))
response.Result(errCode, unReadNotice, context)
}