|
@@ -9,6 +9,7 @@ import (
|
|
|
"github.com/go-xweb/xweb"
|
|
|
"qfw/util/elastic"
|
|
|
"config"
|
|
|
+ "strconv"
|
|
|
)
|
|
|
|
|
|
var mongodb = tools.MQFW
|
|
@@ -37,7 +38,8 @@ func (f *FollowEnt) EntList() error {
|
|
|
//}
|
|
|
//f.T["datas"] = entArr
|
|
|
f.T["followLimit"] = config.Sysconfig["followentlimit"]
|
|
|
- datas, ok := mongodb.Find("jylab_followent", `{"s_userid":"`+f.GetSession("userId").(string)+`"}`, `{"l_createtime":-1}`, `{"_id":1,"winner":1,"s_userid":1,"s_openid":1,"l_createtime":1,"s_id":1}`, false, 0, config.Sysconfig["followentlimit"].(int))
|
|
|
+ limit,_ := strconv.Atoi(config.Sysconfig["followentlimit"].(string))
|
|
|
+ datas, ok := mongodb.Find("jylab_followent", `{"s_userid":"`+f.GetSession("userId").(string)+`"}`, `{"l_createtime":-1}`, `{"_id":1,"winner":1,"s_userid":1,"s_openid":1,"l_createtime":1,"s_id":1}`, false, 0, limit)
|
|
|
f.T["flag"] = false
|
|
|
if ok && datas != nil && len(*datas) > 0 {
|
|
|
for k, v := range *datas {
|