瀏覽代碼

快照页地址 修改

wangshan 8 年之前
父節點
當前提交
d878c9d334

+ 1 - 1
src/jfw/front/shorturl.go

@@ -88,7 +88,7 @@ func (s *Short) Article(clientType, id string) error {
 		s.T["signature"] = wx.SignJSSDK(s.Site() + s.Url())
 		userId, _ := s.GetSession("userId").(string)
 		var obj map[string]interface{}
-		obj = wxvisitD(sid, surl, userId)
+		obj = wxvisitD(sid, userId)
 		if len(obj) > 0 {
 			//获取打赏文案
 			util.ReadConfig(&config.Sysconfig)

+ 4 - 4
src/jfw/front/swordfish.go

@@ -31,7 +31,7 @@ const (
 	bidSearch_maxPageSize = 10 //招标搜索分页--最大页数
 	wx_maxPageNum         = 20
 	wx_pageSize           = 50
-	bidSearch_field_1     = `"_id","title","publishtime","toptype","subtype","type","area","href","bidopentime","winner","buyer","bidamount","budget","s_subscopeclass","projectname","projectcode","projectinfo"`
+	bidSearch_field_1     = `"_id","title","publishtime","toptype","subtype","type","area","bidopentime","winner","buyer","bidamount","budget","s_subscopeclass","projectname","projectcode","projectinfo"`
 	bidSearch_field       = bidSearch_field_1 + `,"detail"`
 	bidSearch_sort        = `{"publishtime":-1}`
 )
@@ -990,7 +990,7 @@ func (m *Front) VisitRedirect() {
 	m.T["signature"] = wx.SignJSSDK(m.Site() + m.Url())
 	userId, _ := m.GetSession("userId").(string)
 	var obj map[string]interface{}
-	obj = wxvisitD(sid, surl, userId)
+	obj = wxvisitD(sid, userId)
 	if len(obj) > 0 {
 		//获取打赏文案
 		m.T["rewardText"], m.T["advertText"] = getRewardText()
@@ -1002,7 +1002,7 @@ func (m *Front) VisitRedirect() {
 		m.Redirect(surl)
 	}
 }
-func wxvisitD(sid, surl, userId string) (objdata map[string]interface{}) {
+func wxvisitD(sid, userId string) (objdata map[string]interface{}) {
 	defer util.Catch()
 	var obj map[string]interface{}
 	if len(sid) > 5 {
@@ -1013,7 +1013,7 @@ func wxvisitD(sid, surl, userId string) (objdata map[string]interface{}) {
 		obj = *aobj
 		if ok && obj != nil && len(obj) >= 3 {
 			obj["_id"] = util.EncodeArticleId2ByCheck(sid)
-			obj["url"] = surl
+			obj["url"] = obj["href"]
 			pt := obj["publishtime"]
 			obj["l_publishtime"] = pt
 			obj["publishtime"] = util.FormatDateWithObj(&pt, util.Date_Full_Layout)

+ 2 - 2
src/jfw/modules/entsesearch/src/web/staticres/jylab/entsesearch/js/common.js

@@ -97,9 +97,9 @@ function newredirect(zbadd,link,sid,sds){
 		link="http://"+link
 	}
 	if(sds){
-		window.location.href=zbadd+"/article/content/"+sid+".html?url="+escape(link)+"&keywords="+encodeURIComponent(sds);
+		window.location.href=zbadd+"/article/content/"+sid+".html?keywords="+encodeURIComponent(sds);
 	}else{
-		window.location.href=zbadd+"/article/content/"+sid+".html?url="+escape(link);
+		window.location.href=zbadd+"/article/content/"+sid+".html";
 	}
 }
 function pcredirect(link,sid){

+ 2 - 2
src/jfw/modules/followent/src/web/staticres/jylab/followent/js/common.js

@@ -97,9 +97,9 @@ function newredirect(zbadd,link,sid,sds){
 		link="http://"+link
 	}
 	if(sds){
-		window.location.href=zbadd+"/article/content/"+sid+".html?url="+escape(link)+"&keywords="+encodeURIComponent(sds);
+		window.location.href=zbadd+"/article/content/"+sid+".html?keywords="+encodeURIComponent(sds);
 	}else{
-		window.location.href=zbadd+"/article/content/"+sid+".html?url="+escape(link);
+		window.location.href=zbadd+"/article/content/"+sid+".html";
 	}
 }
 function pcredirect(link,sid){

+ 2 - 2
src/web/staticres/js/common.js

@@ -97,9 +97,9 @@ function newredirect(zbadd,link,sid,sds){
 		link="http://"+link
 	}
 	if(sds){
-		window.location.href=zbadd+"/article/content/"+sid+".html?url="+escape(link)+"&keywords="+encodeURIComponent(sds);
+		window.location.href=zbadd+"/article/content/"+sid+".html?keywords="+encodeURIComponent(sds);
 	}else{
-		window.location.href=zbadd+"/article/content/"+sid+".html?url="+escape(link);
+		window.location.href=zbadd+"/article/content/"+sid+".html?";
 	}
 }
 function pcredirect(link,sid){

+ 12 - 4
src/web/templates/weixin/search/superSearch.html

@@ -694,14 +694,22 @@
 			setSessionStorage();
 			//跳转
             link = link.replace(/\n/g,"");
-            if(!/^http/.test(link)){
+            if(link!=""&&!/^http/.test(link)){
                 link="http://"+link
             }
             if(sds){
-                window.open("{{Msg "seo" "ZBADDRESS"}}/article/content/"+sid+".html?url="+escape(link)+"&keywords="+encodeURIComponent(sds)+"?industry="+reqParam.industry);
+				if(reqParam.industry!=""){
+                	window.open("{{Msg "seo" "ZBADDRESS"}}/article/content/"+sid+".html?keywords="+encodeURIComponent(sds)+"?industry="+reqParam.industry);
+				}else{
+					window.open("{{Msg "seo" "ZBADDRESS"}}/article/content/"+sid+".html?keywords="+encodeURIComponent(sds));
+				}
             }else{
-                window.open("{{Msg "seo" "ZBADDRESS"}}/article/content/"+sid+".html?url="+escape(link)+"?industry="+reqParam.industry);
-            }
+				if(reqParam.industry!=""){
+                	window.open("{{Msg "seo" "ZBADDRESS"}}/article/content/"+sid+".html?industry="+reqParam.industry);
+            	}else{
+					window.open("{{Msg "seo" "ZBADDRESS"}}/article/content/"+sid+".html");
+				}
+			}
         }
         function noMoreData(me){
             // 锁定