|
@@ -378,6 +378,9 @@ func (this *ReportController) EditDayWeekChapter() {
|
|
br.IsSendEmail = false
|
|
br.IsSendEmail = false
|
|
return
|
|
return
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ updateCols := make([]string, 0)
|
|
|
|
+
|
|
// 报告的最后编辑人
|
|
// 报告的最后编辑人
|
|
reportInfo.LastModifyAdminId = sysUser.AdminId
|
|
reportInfo.LastModifyAdminId = sysUser.AdminId
|
|
reportInfo.LastModifyAdminName = sysUser.RealName
|
|
reportInfo.LastModifyAdminName = sysUser.RealName
|
|
@@ -411,21 +414,27 @@ func (this *ReportController) EditDayWeekChapter() {
|
|
|
|
|
|
if req.Title != `` {
|
|
if req.Title != `` {
|
|
reportChapterInfo.Title = req.Title
|
|
reportChapterInfo.Title = req.Title
|
|
|
|
+ updateCols = append(updateCols, "Title")
|
|
}
|
|
}
|
|
//reportChapterInfo.AddType = req.AddType
|
|
//reportChapterInfo.AddType = req.AddType
|
|
reportChapterInfo.Author = req.Author
|
|
reportChapterInfo.Author = req.Author
|
|
reportChapterInfo.Content = html.EscapeString(req.Content)
|
|
reportChapterInfo.Content = html.EscapeString(req.Content)
|
|
reportChapterInfo.ContentSub = html.EscapeString(contentSub)
|
|
reportChapterInfo.ContentSub = html.EscapeString(contentSub)
|
|
reportChapterInfo.IsEdit = 1
|
|
reportChapterInfo.IsEdit = 1
|
|
- reportChapterInfo.CreateTime = req.CreateTime
|
|
|
|
|
|
+ reportChapterInfo.ModifyTime = time.Now()
|
|
|
|
+
|
|
|
|
+ // 担心外部没有传入时间,如果没有传入,那么就不修改
|
|
|
|
+ if req.CreateTime != `` {
|
|
|
|
+ reportChapterInfo.CreateTime = req.CreateTime
|
|
|
|
+ updateCols = append(updateCols, "CreateTime")
|
|
|
|
+ }
|
|
|
|
|
|
reportChapterInfo.LastModifyAdminId = sysUser.AdminId
|
|
reportChapterInfo.LastModifyAdminId = sysUser.AdminId
|
|
reportChapterInfo.LastModifyAdminName = sysUser.RealName
|
|
reportChapterInfo.LastModifyAdminName = sysUser.RealName
|
|
reportChapterInfo.ContentModifyTime = time.Now()
|
|
reportChapterInfo.ContentModifyTime = time.Now()
|
|
reportChapterInfo.ContentStruct = html.EscapeString(req.ContentStruct)
|
|
reportChapterInfo.ContentStruct = html.EscapeString(req.ContentStruct)
|
|
|
|
|
|
- updateCols := make([]string, 0)
|
|
|
|
- updateCols = append(updateCols, "Title", "AddType", "Author", "Content", "ContentSub", "IsEdit", "CreateTime")
|
|
|
|
|
|
+ updateCols = append(updateCols, "Author", "Content", "ContentSub", "IsEdit", "ModifyTime")
|
|
|
|
|
|
updateCols = append(updateCols, "LastModifyAdminId", "LastModifyAdminName", "ContentModifyTime", "ContentStruct")
|
|
updateCols = append(updateCols, "LastModifyAdminId", "LastModifyAdminName", "ContentModifyTime", "ContentStruct")
|
|
|
|
|