Bladeren bron

no message

xingzai 11 maanden geleden
bovenliggende
commit
b16cb86ea3
2 gewijzigde bestanden met toevoegingen van 4 en 3 verwijderingen
  1. 1 1
      models/cygx_yanxuan_special.go
  2. 3 2
      services/resource_data.go

+ 1 - 1
models/cygx_yanxuan_special.go

@@ -132,7 +132,7 @@ JOIN cygx_yanxuan_special_author AS b ON a.user_id = b.user_id
 func GetYanxuanSpecialListHome(userId int, condition string, pars []interface{}, startSize, pageSize int) (items []*CygxYanxuanSpecialItem, err error) {
 func GetYanxuanSpecialListHome(userId int, condition string, pars []interface{}, startSize, pageSize int) (items []*CygxYanxuanSpecialItem, err error) {
 	o := orm.NewOrm()
 	o := orm.NewOrm()
 	sql := ``
 	sql := ``
-	sql = `SELECT a.*,b.id AS special_column_id,b.bg_img,b.head_img,b.introduction,b.label,b.mobile,b.nick_name,b.real_name,b.special_name,b.status AS author_status
+	sql = `SELECT a.id,a.publish_time,a.title ,a.content,a.type,   b.id AS special_column_id,b.bg_img,b.head_img,b.introduction,b.label,b.mobile,b.nick_name,b.real_name,b.special_name,b.status AS author_status
 FROM cygx_yanxuan_special AS a
 FROM cygx_yanxuan_special AS a
 JOIN cygx_yanxuan_special_author AS b ON a.user_id = b.user_id 
 JOIN cygx_yanxuan_special_author AS b ON a.user_id = b.user_id 
  WHERE 1=1 `
  WHERE 1=1 `

+ 3 - 2
services/resource_data.go

@@ -7,6 +7,7 @@ import (
 	"hongze/hongze_web_mfyx/utils"
 	"hongze/hongze_web_mfyx/utils"
 	"strconv"
 	"strconv"
 	"strings"
 	"strings"
+	"time"
 )
 )
 
 
 func GetResourceDataList(condition string, pars []interface{}, startSize, pageSize int, user *models.WxUserItem) (items []*models.CygxResourceDataNewResp, err error) {
 func GetResourceDataList(condition string, pars []interface{}, startSize, pageSize int, user *models.WxUserItem) (items []*models.CygxResourceDataNewResp, err error) {
@@ -156,7 +157,7 @@ func GetResourceDataList(condition string, pars []interface{}, startSize, pageSi
 			mapItems[fmt.Sprint("activity", v.ActivityId)].Activity = v
 			mapItems[fmt.Sprint("activity", v.ActivityId)].Activity = v
 		}
 		}
 	}
 	}
-
+	fmt.Println(time.Now().UnixMilli())
 	//处理研选专栏
 	//处理研选专栏
 	lenyanxuanSpecialIds := len(yanxuanSpecialIds)
 	lenyanxuanSpecialIds := len(yanxuanSpecialIds)
 	if lenyanxuanSpecialIds > 0 {
 	if lenyanxuanSpecialIds > 0 {
@@ -177,7 +178,7 @@ func GetResourceDataList(condition string, pars []interface{}, startSize, pageSi
 			mapItems[fmt.Sprint(utils.CYGX_OBJ_YANXUANSPECIAL, v.Id)].YanxuanSpecial = v
 			mapItems[fmt.Sprint(utils.CYGX_OBJ_YANXUANSPECIAL, v.Id)].YanxuanSpecial = v
 		}
 		}
 	}
 	}
-
+	fmt.Println(time.Now().UnixMilli())
 	for _, vList := range list {
 	for _, vList := range list {
 		for _, v := range mapItems {
 		for _, v := range mapItems {
 			//如果这些类型都为空,那么就不合并
 			//如果这些类型都为空,那么就不合并