正在显示
5 个修改的文件
包含
16 行增加
和
9 行删除
@@ -112,7 +112,6 @@ limit ? | @@ -112,7 +112,6 @@ limit ? | ||
112 | sqlCount := fmt.Sprintf(`select count(0) from ( | 112 | sqlCount := fmt.Sprintf(`select count(0) from ( |
113 | select id,user_id,create_at,source_content from chance | 113 | select id,user_id,create_at,source_content from chance |
114 | where user_id=? and company_id=? and review_status in (%v) | 114 | where user_id=? and company_id=? and review_status in (%v) |
115 | -order by create_at desc | ||
116 | ) a left JOIN chance_data b on a.id =b.chance_id`, utils.JoinInt8s(reviewStatus, ",")) | 115 | ) a left JOIN chance_data b on a.id =b.chance_id`, utils.JoinInt8s(reviewStatus, ",")) |
117 | if err = utils.ExecuteQueryOne(&total, sqlCount, uid, cid); err != nil { | 116 | if err = utils.ExecuteQueryOne(&total, sqlCount, uid, cid); err != nil { |
118 | return | 117 | return |
@@ -520,13 +520,16 @@ type CommonListItem struct { | @@ -520,13 +520,16 @@ type CommonListItem struct { | ||
520 | ReviewStatus int `json:"reviewStatus"` //审核状态 | 520 | ReviewStatus int `json:"reviewStatus"` //审核状态 |
521 | } | 521 | } |
522 | type ChanceItem struct { | 522 | type ChanceItem struct { |
523 | - Id int64 `json:"id"` | ||
524 | - CreateTime int64 `json:"createTime"` | ||
525 | - Provider *BaseUserInfo `json:"provider"` | ||
526 | - FormList []*Form `json:"formList" valid:"Required"` | ||
527 | - Speechs []Speech `json:"speechs"` | ||
528 | - Pictures []Picture `json:"pictures"` | ||
529 | - Videos []Video `json:"videos"` | 523 | + Id int64 `json:"id"` |
524 | + CreateTime int64 `json:"createTime"` | ||
525 | + CreateTimeCopy int64 `json:"createTimeCopy"` | ||
526 | + UpdateTime int64 `json:"updateTime"` | ||
527 | + ApproveTime int64 `json:"approveTime"` | ||
528 | + Provider *BaseUserInfo `json:"provider"` | ||
529 | + FormList []*Form `json:"formList" valid:"Required"` | ||
530 | + Speechs []Speech `json:"speechs"` | ||
531 | + Pictures []Picture `json:"pictures"` | ||
532 | + Videos []Video `json:"videos"` | ||
530 | } | 533 | } |
531 | type ChanceData struct { | 534 | type ChanceData struct { |
532 | ThumbsUpTotal int `json:"thumbsupTotal"` //点赞总数 | 535 | ThumbsUpTotal int `json:"thumbsupTotal"` //点赞总数 |
@@ -151,3 +151,7 @@ func logMsg(msg *models.UserMsg, name string) { | @@ -151,3 +151,7 @@ func logMsg(msg *models.UserMsg, name string) { | ||
151 | log.Info(fmt.Sprintf("发送消息 消息类型:%v Receiver:%v(%v) Message:%v SourceId:%v SourceType:%v", | 151 | log.Info(fmt.Sprintf("发送消息 消息类型:%v Receiver:%v(%v) Message:%v SourceId:%v SourceType:%v", |
152 | msg.MsgType, msg.ReceiveUserId, name, msg.Message, msg.SourceId, msg.SourceType)) | 152 | msg.MsgType, msg.ReceiveUserId, name, msg.Message, msg.SourceId, msg.SourceType)) |
153 | } | 153 | } |
154 | + | ||
155 | +func SaveApproveLog(orm orm.Ormer, code int, userId int64, param ...interface{}) (err error) { | ||
156 | + return | ||
157 | +} |
@@ -1194,6 +1194,7 @@ func MyApproveChance(header *protocol.RequestHeader, request *protocol.MyApprove | @@ -1194,6 +1194,7 @@ func MyApproveChance(header *protocol.RequestHeader, request *protocol.MyApprove | ||
1194 | item := protocol.ChanceItem{ | 1194 | item := protocol.ChanceItem{ |
1195 | Id: chance.ChanceId, | 1195 | Id: chance.ChanceId, |
1196 | Provider: provider, | 1196 | Provider: provider, |
1197 | + //CreateTime:chance.c | ||
1197 | //CreateTime: chance.CreateTime.Unix() * 1000, | 1198 | //CreateTime: chance.CreateTime.Unix() * 1000, |
1198 | } | 1199 | } |
1199 | jsonUnmarshal(chance.SourceContent, &item.FormList) | 1200 | jsonUnmarshal(chance.SourceContent, &item.FormList) |
@@ -89,7 +89,7 @@ func UploadFile(request *protocol.FileRequest) (rsp *protocol.FileResponse, err | @@ -89,7 +89,7 @@ func UploadFile(request *protocol.FileRequest) (rsp *protocol.FileResponse, err | ||
89 | log.Error(err) | 89 | log.Error(err) |
90 | return | 90 | return |
91 | } | 91 | } |
92 | - rsp.Paths = append(rsp.Paths, filepath.Join(virtualPath, filename)) | 92 | + rsp.Paths = append(rsp.Paths, virtualPath+filename) |
93 | ResizeImage(request.FileType, sourcePath, prefix, subfix, f) | 93 | ResizeImage(request.FileType, sourcePath, prefix, subfix, f) |
94 | } | 94 | } |
95 | return | 95 | return |
-
请 注册 或 登录 后发表评论