作者 yangfu

fix: 文章详情修改

... ... @@ -80,10 +80,10 @@ type (
}
ArticleSection {
Id int64 `json:"id"` //段落id
Content string `json:"content"` // 文本内容
Content string `json:"content,optional"` // 文本内容
SortBy int `json:"sortBy"` // 排序
TotalComment int `json:"totalComment"` // 评论的数量
Images []string `json:"images"` // 照片列表
Images []string `json:"images,optional"` // 照片列表
ParagraphType int `json:"paragraphType"` // 段落类型 0:无样式 1:模板文本 2:模板图片
ParagraphTemplate Paragraph `json:"paragraphTemplate"` // 段落模板
}
... ... @@ -494,7 +494,7 @@ type (
Template int `json:"template,optional"` // 使用哪个模板进行编辑 0、无 1、演绎式 2、归纳式
Section []ArticleSection `json:"section,optional"` // 填写的内容
Title string `json:"title"` // 标题
Images []string `json:"images"` // 图片
Images []string `json:"images,optional"` // 图片
Videos []Video `json:"video"` // 视频
WhoRead []int64 `json:"whoRead"` // 谁可以看
WhoReview []int64 `json:"whoReview"` // 评论人
... ...
... ... @@ -2,6 +2,7 @@ package article
import (
"context"
"gitlab.fjmaimaimai.com/allied-creation/sumifcc-discuss/cmd/discuss/api/internal/logic/core"
"github.com/samber/lo"
"gitlab.fjmaimaimai.com/allied-creation/sumifcc-discuss/cmd/discuss/interanl/pkg/domain"
... ... @@ -62,6 +63,9 @@ func (l *SystemArticleGetHistoryLogic) SystemArticleGetHistory(req *types.System
Content: item.Content,
SortBy: item.SortBy,
TotalComment: item.TotalComment,
Images: item.Images,
ParagraphTemplate: core.NewTypesParagraph(item.ParagraphTemplate),
ParagraphType: item.ParagraphType,
})
})
//图片
... ...
... ... @@ -1004,10 +1004,10 @@ type MiniArticleGetResponse struct {
type ArticleSection struct {
Id int64 `json:"id"` //段落id
Content string `json:"content"` // 文本内容
Content string `json:"content,optional"` // 文本内容
SortBy int `json:"sortBy"` // 排序
TotalComment int `json:"totalComment"` // 评论的数量
Images []string `json:"images"` // 照片列表
Images []string `json:"images,optional"` // 照片列表
ParagraphType int `json:"paragraphType"` // 段落类型 0:无样式 1:模板文本 2:模板图片
ParagraphTemplate Paragraph `json:"paragraphTemplate"` // 段落模板
}
... ... @@ -1373,7 +1373,7 @@ type SystemArticleUpdateRequest struct {
Template int `json:"template,optional"` // 使用哪个模板进行编辑 0、无 1、演绎式 2、归纳式
Section []ArticleSection `json:"section,optional"` // 填写的内容
Title string `json:"title"` // 标题
Images []string `json:"images"` // 图片
Images []string `json:"images,optional"` // 图片
Videos []Video `json:"video"` // 视频
WhoRead []int64 `json:"whoRead"` // 谁可以看
WhoReview []int64 `json:"whoReview"` // 评论人
... ...