瀏覽代碼

wip:权限判断修改及增加快捷入口

wangkaiyue 3 年之前
父節點
當前提交
e8d44efaaf

+ 6 - 4
src/jfw/front/frontRouter.go

@@ -5,7 +5,6 @@ import (
 	"jfw/config"
 	"jfw/public"
 	"jfw/wx"
-	"log"
 	"qfw/util/jy"
 	"regexp"
 	"strings"
@@ -174,10 +173,13 @@ func (this *CommonRouter) doPcBigPage(pageSign, types string) error {
 	}
 	//没有购买大会员跳转大会员介绍页
 	if !strings.HasPrefix(pageSign, "svip/ent_ser_portrait") {
-		if array := strings.Split(pageSign, "/"); len(array) > 0 {
-			pageSign = array[0]
+		for _, v := range strings.Split(pageSign, "/") {
+			if v == "" || v == "desktop" {
+				continue
+			}
+			pageSign = v
+			break
 		}
-		log.Println(bigVipFreePageReg.MatchString(pageSign), "+++", pageSign)
 		bigBaseMsg := jy.GetBigVipUserBaseMsg(userid, public.Mysql, public.MQFW)
 		if !bigVipFreePageReg.MatchString(pageSign) {
 			if bigBaseMsg.Status <= 0 && bigBaseMsg.Vip_BuySet.Upgrade != 1 {

+ 3 - 2
src/jfw/modules/bigmember/src/entity/marketAnalysis/marketAnalysisEntity.go

@@ -220,6 +220,9 @@ func (mae *MarketAnalysisEntity) getQueryItem() (map[string]interface{}, error)
 
 //GetPartResult 分块儿获取报告内容
 func (mae *MarketAnalysisEntity) GetPartResult(flag int) (map[string]interface{}, error) {
+	if flag == marketQueryItem { //返回查询内容
+		return mae.getQueryItem()
+	}
 	//控制并发&&超时返回超时异常
 	select {
 	case <-time.After(time.Duration(config.Config.MarketAnalysisPool.TimeOut) * time.Second * 20):
@@ -228,8 +231,6 @@ func (mae *MarketAnalysisEntity) GetPartResult(flag int) (map[string]interface{}
 	}
 	defer func() { MarketAnalysisPool <- true }()
 	switch flag {
-	case marketQueryItem:
-		return mae.getQueryItem()
 	case marketScaleMain:
 		return mae.MarketTime(), nil
 	case marketProject:

+ 8 - 0
src/jfw/modules/publicapply/src/userbase/commonfunctions.json

@@ -143,6 +143,14 @@
 				"img":"/commonFunctions/pc_subreport_month.png"
 			}
 		},
+		{
+			"name":"定制化分析报告",
+			"charge":true,
+			"pc":{
+				"url":"/swordfish/page_big_pc/desktop/analysis_report",
+				"img":"/commonFunctions/analysis_report.png"
+			}
+		},
 		{
 			"name":"我的订单",
 			"charge":false,