|
@@ -280,6 +280,7 @@ func GetResourceDataEsList(list []*SearchComprehensiveItem, user *models.WxUserI
|
|
|
uid := user.UserId
|
|
|
titleHighlight := make(map[int]string)
|
|
|
bodyHighlight := make(map[int][]string)
|
|
|
+ yanXuanbodyHighlight := make(map[int][]string)
|
|
|
mapItems := make(map[string]*models.CygxResourceDataNewResp)
|
|
|
for _, v := range list {
|
|
|
//预处理文章
|
|
@@ -339,6 +340,7 @@ func GetResourceDataEsList(list []*SearchComprehensiveItem, user *models.WxUserI
|
|
|
industrialResourceIdsYx = append(industrialResourceIdsYx, v.SourceId)
|
|
|
} else if v.Source == utils.CYGX_OBJ_YANXUANSPECIAL {
|
|
|
yanxuanSpecialIds = append(yanxuanSpecialIds, v.SourceId)
|
|
|
+ yanXuanbodyHighlight[v.SourceId] = v.Body
|
|
|
} else if v.Source == utils.CYGX_OBJ_ASKSERIEVIDEO {
|
|
|
askserieVideoIds = append(askserieVideoIds, strconv.Itoa(v.SourceId))
|
|
|
}
|
|
@@ -766,6 +768,12 @@ func GetResourceDataEsList(list []*SearchComprehensiveItem, user *models.WxUserI
|
|
|
for _, v := range listyanxuanSpecial {
|
|
|
v.PublishTime = utils.TimeRemoveHms2(v.PublishTime)
|
|
|
v.Annotation, _ = GetReportContentTextSubNew(v.Content)
|
|
|
+ if len(yanXuanbodyHighlight[v.Id]) > 0 {
|
|
|
+ v.BodyHighlight = yanXuanbodyHighlight[v.Id]
|
|
|
+ } else {
|
|
|
+ v.BodyHighlight = append(v.BodyHighlight, v.Annotation)
|
|
|
+ }
|
|
|
+ v.Annotation = "" //强制置空,兼容前端优先级
|
|
|
mapItems[fmt.Sprint(utils.CYGX_OBJ_YANXUANSPECIAL, v.Id)].YanxuanSpecial = v
|
|
|
}
|
|
|
}
|
|
@@ -810,6 +818,9 @@ func GetResourceDataEsList(list []*SearchComprehensiveItem, user *models.WxUserI
|
|
|
if v.IndustrialResource != nil && v.SourceId == vList.SourceId && v.Source == vList.Source {
|
|
|
v.IndustrialResource.UpdateTime = strings.Replace(vList.PublishDate, "00:00:00", "", -1)
|
|
|
}
|
|
|
+ if v.YanxuanSpecial != nil && v.SourceId == vList.SourceId {
|
|
|
+ v.YanxuanSpecial.Title = vList.Title
|
|
|
+ }
|
|
|
if v.SourceId == vList.SourceId && v.Source == vList.Source {
|
|
|
items = append(items, v)
|
|
|
}
|
|
@@ -852,7 +863,7 @@ func EsAddYanxuanSpecial(sourceId int) {
|
|
|
item.BodyText = bodyText
|
|
|
item.Abstract = bodyText
|
|
|
item.IndustryName = detail.IndustryTags
|
|
|
- item.SubjectNames = detail.SpecialName
|
|
|
+ item.SubjectNames = detail.CompanyTags + detail.Tags
|
|
|
if detail.Status == 3 {
|
|
|
EsAddOrEditComprehensiveData(item) //如果发布了就新增
|
|
|
} else {
|