|
@@ -62,13 +62,13 @@ func (this *ReportBillboardController) FllowList() {
|
|
|
chartPermissionId, _ := this.GetInt("ChartPermissionId")
|
|
|
|
|
|
// 查询有已归类行业报告的行业IDs
|
|
|
- //activeIndustryIds, e := models.GetActiveArticleIndustryIds()
|
|
|
- //if e != nil {
|
|
|
- // br.Msg = "获取失败"
|
|
|
- // br.ErrMsg = "获取已归类行业失败, Err:" + e.Error()
|
|
|
- // return
|
|
|
- //}
|
|
|
- //activeIndustryLen := len(activeIndustryIds)
|
|
|
+ activeIndustryIds, e := models.GetActiveArticleIndustryIds()
|
|
|
+ if e != nil {
|
|
|
+ br.Msg = "获取失败"
|
|
|
+ br.ErrMsg = "获取已归类行业失败, Err:" + e.Error()
|
|
|
+ return
|
|
|
+ }
|
|
|
+ activeIndustryLen := len(activeIndustryIds)
|
|
|
|
|
|
topNum := utils.PageSize15
|
|
|
var condition, subCond string
|
|
@@ -77,10 +77,10 @@ func (this *ReportBillboardController) FllowList() {
|
|
|
condition += ` AND man.chart_permission_id = ? `
|
|
|
pars = append(pars, chartPermissionId)
|
|
|
}
|
|
|
- //if activeIndustryLen > 0 {
|
|
|
- // condition += ` AND man.industrial_management_id IN (` + utils.GetOrmInReplace(activeIndustryLen) + `)`
|
|
|
- // pars = append(pars, activeIndustryIds)
|
|
|
- //}
|
|
|
+ if activeIndustryLen > 0 {
|
|
|
+ condition += ` AND man.industrial_management_id IN (` + utils.GetOrmInReplace(activeIndustryLen) + `)`
|
|
|
+ pars = append(pars, activeIndustryIds)
|
|
|
+ }
|
|
|
//nowTime := time.Now().Local()
|
|
|
//startTime := nowTime.AddDate(0, -1, 0)
|
|
|
//endTime := nowTime.AddDate(0, 0, -1)
|