|
@@ -6,8 +6,6 @@ import (
|
|
"app.yhyue.com/moapp/MessageCenter/rpc/messageclient"
|
|
"app.yhyue.com/moapp/MessageCenter/rpc/messageclient"
|
|
"app.yhyue.com/moapp/MessageCenter/util"
|
|
"app.yhyue.com/moapp/MessageCenter/util"
|
|
"context"
|
|
"context"
|
|
- "encoding/json"
|
|
|
|
- "fmt"
|
|
|
|
"github.com/zeromicro/go-zero/core/logx"
|
|
"github.com/zeromicro/go-zero/core/logx"
|
|
)
|
|
)
|
|
|
|
|
|
@@ -28,17 +26,17 @@ func NewNewUserSaveMsgLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Ne
|
|
func (l *NewUserSaveMsgLogic) NewUserSaveMsg(req *types.NewUserSaveMsgReq) (resp *types.NewUserSaveMsgResp, err error) {
|
|
func (l *NewUserSaveMsgLogic) NewUserSaveMsg(req *types.NewUserSaveMsgReq) (resp *types.NewUserSaveMsgResp, err error) {
|
|
lsi := l.svcCtx.MessageCenter
|
|
lsi := l.svcCtx.MessageCenter
|
|
msgInfo := req.MsgInfo
|
|
msgInfo := req.MsgInfo
|
|
- msgLogId, err := (msgInfo["msgLogId"]).(json.Number).Int64()
|
|
|
|
|
|
+ /*msgLogId, err := (msgInfo["msgLogId"]).(json.Number).Int64()
|
|
msgType, err := (msgInfo["msgType"]).(json.Number).Int64()
|
|
msgType, err := (msgInfo["msgType"]).(json.Number).Int64()
|
|
- fmt.Println("msgInfo:", msgInfo)
|
|
|
|
|
|
+ fmt.Println("msgInfo:", msgInfo)*/
|
|
_, err = lsi.NewUserMsg(l.ctx, &messageclient.NewUserInsertMsgReq{
|
|
_, err = lsi.NewUserMsg(l.ctx, &messageclient.NewUserInsertMsgReq{
|
|
Appid: util.ObjToString(msgInfo["appid"]),
|
|
Appid: util.ObjToString(msgInfo["appid"]),
|
|
Title: util.ObjToString(msgInfo["title"]),
|
|
Title: util.ObjToString(msgInfo["title"]),
|
|
Content: util.ObjToString(msgInfo["content"]),
|
|
Content: util.ObjToString(msgInfo["content"]),
|
|
- MsgType: msgType,
|
|
|
|
|
|
+ MsgType: util.Int64All(msgInfo["msgType"]),
|
|
Link: util.ObjToString(msgInfo["link"]),
|
|
Link: util.ObjToString(msgInfo["link"]),
|
|
UserIds: req.UserIds,
|
|
UserIds: req.UserIds,
|
|
- MsgLogId: msgLogId,
|
|
|
|
|
|
+ MsgLogId: util.Int64All(msgInfo["msgLogId"]),
|
|
PositionIds: req.PositionIds,
|
|
PositionIds: req.PositionIds,
|
|
Row4: util.ObjToString(msgInfo["row4"]),
|
|
Row4: util.ObjToString(msgInfo["row4"]),
|
|
ProductName: util.ObjToString(msgInfo["productName"]),
|
|
ProductName: util.ObjToString(msgInfo["productName"]),
|