瀏覽代碼

no message

xingzai 10 月之前
父節點
當前提交
1409b741c9
共有 2 個文件被更改,包括 6 次插入0 次删除
  1. 3 0
      models/resource_data.go
  2. 3 0
      services/cygx_yanxuan_special.go

+ 3 - 0
models/resource_data.go

@@ -17,6 +17,9 @@ type CygxResourceData struct {
 	PublishDate       string    `description:"发布时间"`
 	PublishDate       string    `description:"发布时间"`
 	Abstract          string    `description:"摘要"`
 	Abstract          string    `description:"摘要"`
 	SearchTag         string    `description:"搜索标签"`
 	SearchTag         string    `description:"搜索标签"`
+	SearchTitle       string    `description:"搜索匹配用的标题"`
+	SearchContent     string    `description:"搜索匹配用的内容"`
+	SearchOrderTime   string    `description:"搜索排序时间"`
 }
 }
 
 
 type CygxResourceDataResp struct {
 type CygxResourceDataResp struct {

+ 3 - 0
services/cygx_yanxuan_special.go

@@ -269,6 +269,9 @@ func UpdateYanxuanSpecialResourceData(sourceId int) {
 		item.Source = source
 		item.Source = source
 		item.PublishDate = publishDate
 		item.PublishDate = publishDate
 		item.CreateTime = time.Now()
 		item.CreateTime = time.Now()
+		item.SearchTitle = detail.Title
+		item.SearchContent = ""
+		item.SearchOrderTime = publishDate
 		if totalData == 0 {
 		if totalData == 0 {
 			_, e := models.AddCygxResourceData(item)
 			_, e := models.AddCygxResourceData(item)
 			if e != nil {
 			if e != nil {