|
@@ -16,6 +16,7 @@ type MessageService struct {
|
|
|
// 修改消息阅读状态
|
|
|
func (service *MessageService) ChangeReadStatus(data *message.ChangeReadStatusRequest) (int64, string) {
|
|
|
msg := entity.Mysql.FindOne("message", map[string]interface{}{"id": data.Id, "isdel": 1, "appid": data.Appid}, "", "")
|
|
|
+ log.Println("查询到消息:", msg)
|
|
|
if msg == nil {
|
|
|
return 0, "该消息不存在"
|
|
|
}
|
|
@@ -23,7 +24,7 @@ func (service *MessageService) ChangeReadStatus(data *message.ChangeReadStatusRe
|
|
|
if !b {
|
|
|
return 0, "修改消息阅读状态失败"
|
|
|
}
|
|
|
- EtcdCountMinusOne(qutil.ObjToString((*msg)["receive_userid"]), strconv.Itoa(int((*msg)["msgType"].(float64))))
|
|
|
+ EtcdCountMinusOne(qutil.ObjToString((*msg)["receive_userid"]), strconv.Itoa(int((*msg)["msg_type"].(float64))))
|
|
|
return 1, "修改消息阅读状态成功"
|
|
|
}
|
|
|
|