|
@@ -61,12 +61,12 @@ func (l *MiniArticleBackupSearchLogic) MiniArticleBackupSearch(req *types.MiniAr |
|
@@ -61,12 +61,12 @@ func (l *MiniArticleBackupSearchLogic) MiniArticleBackupSearch(req *types.MiniAr |
61
|
Height: val2.Height,
|
61
|
Height: val2.Height,
|
62
|
})
|
62
|
})
|
63
|
}
|
63
|
}
|
64
|
- resp.List[i] = types.MiniArticleBackupItem{
|
64
|
+ item := types.MiniArticleBackupItem{
|
65
|
Id: backupList[i].Id,
|
65
|
Id: backupList[i].Id,
|
66
|
- Title: backupList[i].Title,
|
|
|
67
|
- Content: content.String(),
|
|
|
68
|
- Images: images,
|
|
|
69
|
- Videos: videos,
|
66
|
+ Title: "",
|
|
|
67
|
+ Content: "",
|
|
|
68
|
+ Images: []string{},
|
|
|
69
|
+ Videos: []types.Video{},
|
70
|
CreatedAt: backupList[i].CreatedAt,
|
70
|
CreatedAt: backupList[i].CreatedAt,
|
71
|
Location: types.Location{
|
71
|
Location: types.Location{
|
72
|
Longitude: backupList[i].Location.Longitude,
|
72
|
Longitude: backupList[i].Location.Longitude,
|
|
@@ -77,6 +77,23 @@ func (l *MiniArticleBackupSearchLogic) MiniArticleBackupSearch(req *types.MiniAr |
|
@@ -77,6 +77,23 @@ func (l *MiniArticleBackupSearchLogic) MiniArticleBackupSearch(req *types.MiniAr |
77
|
Action: backupList[i].Action,
|
77
|
Action: backupList[i].Action,
|
78
|
Show: int(backupList[i].Show),
|
78
|
Show: int(backupList[i].Show),
|
79
|
}
|
79
|
}
|
|
|
80
|
+ //根据修改的内容替换展示内容
|
|
|
81
|
+ changeFiled := []string{}
|
|
|
82
|
+ for _, val := range item.ChangeField {
|
|
|
83
|
+ switch val {
|
|
|
84
|
+ case "WhoRead":
|
|
|
85
|
+ changeFiled = append(changeFiled, "修改了分发对象")
|
|
|
86
|
+ case "WhoReview":
|
|
|
87
|
+ changeFiled = append(changeFiled, "修改了评论范围")
|
|
|
88
|
+ case "Section":
|
|
|
89
|
+ item.Title = backupList[i].Title
|
|
|
90
|
+ item.Content = content.String()
|
|
|
91
|
+ item.Images = images
|
|
|
92
|
+ item.Videos = videos
|
|
|
93
|
+ }
|
|
|
94
|
+ }
|
|
|
95
|
+ item.ChangeField = changeFiled
|
|
|
96
|
+
|
80
|
}
|
97
|
}
|
81
|
return resp, nil
|
98
|
return resp, nil
|
82
|
} |
99
|
} |