作者 yangfu

Merge branch 'dev' into test

... ... @@ -50,7 +50,10 @@ func (l *MiniSearchArticleDraftMeLogic) MiniSearchArticleDraftMe(req *types.Mini
draftInfo := draftList[i]
var paragraphs = make([]types.Paragraph, 0)
lo.ForEach(draftInfo.Section, func(p *domain.ArticleSection, index int) {
paragraphs = append(paragraphs, core.NewTypesParagraph(p.ParagraphTemplate))
item := core.NewTypesParagraph(p.ParagraphTemplate)
item.Text = p.Content
item.Images = p.Images
paragraphs = append(paragraphs, item)
})
if len(paragraphs) == 0 && len(draftInfo.Content) > 0 {
... ...
... ... @@ -347,6 +347,7 @@ func NewArticleSectionFromParagraphs(paragraphs []types.Paragraph, companyId int
ParagraphType: paragraph.Type,
ParagraphTemplate: core.NewDomainParagraph(paragraph),
}
section.Images = paragraph.Images
articleSections = append(articleSections, &section)
sortBy++
}
... ...