|
@@ -74,6 +74,11 @@ func UpdateCygxActivitySpecialSignupNum(cont context.Context) (err error) {
|
|
//处理专项调研的展示
|
|
//处理专项调研的展示
|
|
func GetActivityLabelSpecialList(user *models.WxUserItem, isPower int, chartPermissionIds, permissionNameStr string) (item *models.ActivityTypeHome, err error) {
|
|
func GetActivityLabelSpecialList(user *models.WxUserItem, isPower int, chartPermissionIds, permissionNameStr string) (item *models.ActivityTypeHome, err error) {
|
|
itemList := new(models.ActivityTypeHome)
|
|
itemList := new(models.ActivityTypeHome)
|
|
|
|
+ if user.CompanyId <= 1 {
|
|
|
|
+ itemList.List = make([]*models.CygxActivityLabelList, 0)
|
|
|
|
+ item = itemList
|
|
|
|
+ return
|
|
|
|
+ }
|
|
userType, e := GetSpecialUserType(user)
|
|
userType, e := GetSpecialUserType(user)
|
|
if e != nil {
|
|
if e != nil {
|
|
err = errors.New("GetSpecialUserType, Err: " + e.Error())
|
|
err = errors.New("GetSpecialUserType, Err: " + e.Error())
|
|
@@ -514,7 +519,7 @@ func GetActivitySpecialSearcheList(user *models.WxUserItem, condition string, st
|
|
var pars, parsSpecil []interface{}
|
|
var pars, parsSpecil []interface{}
|
|
if keywords != "" {
|
|
if keywords != "" {
|
|
keywords = "%" + keywords + "%"
|
|
keywords = "%" + keywords + "%"
|
|
- conditionSpecil += ` AND (art.research_theme LIKE ? OR art.label LIKE ? OR art.industrial_name LIKE ? OR art.industrial_subject_name LIKE ? ) `
|
|
|
|
|
|
+ conditionSpecil += ` AND art.days > 0 AND (art.research_theme LIKE ? OR art.label LIKE ? OR art.industrial_name LIKE ? OR art.industrial_subject_name LIKE ? ) `
|
|
parsSpecil = append(parsSpecil, keywords, keywords, keywords, keywords)
|
|
parsSpecil = append(parsSpecil, keywords, keywords, keywords, keywords)
|
|
}
|
|
}
|
|
list, totalSearche, e := models.GetActivitySpecialSearcheList(condition, pars, conditionSpecil, parsSpecil, startSize, pageSize)
|
|
list, totalSearche, e := models.GetActivitySpecialSearcheList(condition, pars, conditionSpecil, parsSpecil, startSize, pageSize)
|