|
@@ -518,9 +518,18 @@ func afterDelete(communityQuestionComment *yb_community_question_comment.YbCommu
|
|
|
go alarm_msg.SendAlarmMsg("问答评论信息删除后,标记站内消息失败"+time.Now().Format("2006-01-02 15:04:05")+";Err:"+err.Error(), 3)
|
|
|
}
|
|
|
}()
|
|
|
- sourceType := company_approval_message.CompanyApprovalMessageSourceTypeByQuestionComment
|
|
|
- if communityQuestionComment.Source == 2 {
|
|
|
+
|
|
|
+ sourceType := 0
|
|
|
+ switch communityQuestionComment.Source {
|
|
|
+ case 1:
|
|
|
+ sourceType = company_approval_message.CompanyApprovalMessageSourceTypeByQuestionComment
|
|
|
+ case 2:
|
|
|
sourceType = company_approval_message.CompanyApprovalMessageSourceTypeByVideoComment
|
|
|
+ case 3:
|
|
|
+ sourceType = company_approval_message.CompanyApprovalMessageSourceTypeByRoadVideoComment
|
|
|
+ default:
|
|
|
+ err = errors.New("sourceType有误")
|
|
|
+ return
|
|
|
}
|
|
|
err = company_approval_message.CancelCompanyApprovalMessage(int(communityQuestionComment.CommunityQuestionCommentID), int8(sourceType))
|
|
|
return
|