Эх сурвалжийг харах

Merge branch 'release' into develop

liumiaomiao 9 жил өмнө
parent
commit
b3f469a312

+ 3 - 2
core/src/qfw/member/membermanager.go

@@ -427,7 +427,7 @@ func (m *Member) RegisterComplete() error {
 //登录
 //登录
 func (m *Member) Login() {
 func (m *Member) Login() {
 	var status string = "n"
 	var status string = "n"
-	var info, freeze string
+	var info, freeze, code string
 	s_pwd := m.GetString("s_pwd") //密码
 	s_pwd := m.GetString("s_pwd") //密码
 	if s_pwd != "" {              //密码为空不可登录
 	if s_pwd != "" {              //密码为空不可登录
 		var loginType string            //登录类型
 		var loginType string            //登录类型
@@ -448,6 +448,7 @@ func (m *Member) Login() {
 			} else {
 			} else {
 				//获取绑定企业信息
 				//获取绑定企业信息
 				if r["s_enterpriseid"] != nil && r["s_enterpriseid"].(string) != "" {
 				if r["s_enterpriseid"] != nil && r["s_enterpriseid"].(string) != "" {
+					code = r["s_enterpriseid"].(string)
 					//enter := *FindOne("enterprise", `M{"_id":"`+r["s_enterpriseid"].(string)+`"}`)
 					//enter := *FindOne("enterprise", `M{"_id":"`+r["s_enterpriseid"].(string)+`"}`)
 					enter := *FindById("enterprise", r["s_enterpriseid"].(string), nil)
 					enter := *FindById("enterprise", r["s_enterpriseid"].(string), nil)
 					if enter != nil && enter["OpLocDistrict"] != nil {
 					if enter != nil && enter["OpLocDistrict"] != nil {
@@ -472,7 +473,7 @@ func (m *Member) Login() {
 	} else {
 	} else {
 		info = "p_error" //密码错误
 		info = "p_error" //密码错误
 	}
 	}
-	m.Write("{\"info\":\"" + info + "\",\"status\":\"" + status + "\",\"freeze\":\"" + freeze + "\"}")
+	m.Write("{\"info\":\"" + info + "\",\"status\":\"" + status + "\",\"freeze\":\"" + freeze + "\",\"code\":\"" + code + "\"}")
 }
 }
 
 
 //找回密码之后直接登录
 //找回密码之后直接登录

+ 1 - 1
core/src/qfw/swordfish/swordfishmanage.go

@@ -60,7 +60,7 @@ func (s *SwordFish) RsssetAjaxReq() error {
 
 
 //跳转到用户中心剑鱼信息列表
 //跳转到用户中心剑鱼信息列表
 func (s *SwordFish) Infolist() error {
 func (s *SwordFish) Infolist() error {
-	ms := mongodb.FindById("user", s.GetSession("userId").(string), `{"o_msgset:1"}`)
+	ms := mongodb.FindById("user", s.GetSession("userId").(string), `{"o_msgset":1}`)
 	s.T["msgset"] = ms
 	s.T["msgset"] = ms
 	return s.Render("/swordfish/infolist.html", &s.T)
 	return s.Render("/swordfish/infolist.html", &s.T)
 }
 }

+ 10 - 0
core/src/web/staticres/wxswordfish/style.css

@@ -322,6 +322,11 @@ img{
 	-o-animation-timing-function:ease-in;
 	-o-animation-timing-function:ease-in;
 	-o-animation-iteration-count:1;
 	-o-animation-iteration-count:1;
 	-o-animation-play-state:running;
 	-o-animation-play-state:running;
+	webkit-transform: translateZ(0);
+	-moz-transform: translateZ(0);
+	-ms-transform: translateZ(0);
+	-o-transform: translateZ(0);
+	transform: translateZ(0);
 }
 }
 @-webkit-keyframes slidedown {
 @-webkit-keyframes slidedown {
 	0%{
 	0%{
@@ -351,6 +356,11 @@ img{
 	-o-animation-timing-function:ease-in;
 	-o-animation-timing-function:ease-in;
 	-o-animation-iteration-count:1;
 	-o-animation-iteration-count:1;
 	-o-animation-play-state:running;
 	-o-animation-play-state:running;
+	webkit-transform: translateZ(0);
+	-moz-transform: translateZ(0);
+	-ms-transform: translateZ(0);
+	-o-transform: translateZ(0);
+	transform: translateZ(0);
 }
 }
 
 
 @-webkit-keyframes slideup {
 @-webkit-keyframes slideup {

+ 5 - 5
core/src/web/templates/common/login.html

@@ -140,7 +140,7 @@ function setTimes(num,n){
 						//登陆成功
 						//登陆成功
 						clearInterval(t);
 						clearInterval(t);
 						compulsoryreRresh = true;
 						compulsoryreRresh = true;
-						afterLoginSkip();
+						afterLoginSkip(data);
 						$("img.login-logo").css("marginLeft",180);
 						$("img.login-logo").css("marginLeft",180);
 						$("div.modal-content").animate({
 						$("div.modal-content").animate({
 						    width:'550px'
 						    width:'550px'
@@ -217,7 +217,7 @@ $(function (){
 			}else{
 			}else{
 				//注册页面登录之后
 				//注册页面登录之后
 				$("#loginStatus").trigger("login");
 				$("#loginStatus").trigger("login");
-				afterLoginSkip();
+				afterLoginSkip(data);
 			}
 			}
 			//
 			//
 			if($("#loginModal [name='rememberMe']").is(':checked')==true){
 			if($("#loginModal [name='rememberMe']").is(':checked')==true){
@@ -242,7 +242,7 @@ $(function (){
 		
 		
 	});
 	});
 });
 });
-function afterLoginSkip(){
+function afterLoginSkip(data){
 	switch(loginBackType){
 	switch(loginBackType){
 		case -1:
 		case -1:
 			window.location.href = window.location.href;
 			window.location.href = window.location.href;
@@ -266,14 +266,14 @@ function afterLoginSkip(){
 			window.location.href = "/member/show/memberindex";
 			window.location.href = "/member/show/memberindex";
 			break;
 			break;
 		case 8://录入产品服务信息
 		case 8://录入产品服务信息
-			if(data.code==null){
+			if(data.code==null || data.code == ""){
 				window.location.href = '/member/show/memberindex';
 				window.location.href = '/member/show/memberindex';
 			}else{
 			}else{
 				window.location.href = '/member/yellowpage/show/showService/'+data.code;
 				window.location.href = '/member/yellowpage/show/showService/'+data.code;
 			}
 			}
 			break;
 			break;
 		case 9://录入企业信息
 		case 9://录入企业信息
-			if(data.code==null){
+			if(data.code==null || data.code == ""){
 				window.location.href = '/member/show/memberindex';
 				window.location.href = '/member/show/memberindex';
 			}else{
 			}else{
 				window.location.href = '/member/yellowpage/edit/enterprise/'+data.code;
 				window.location.href = '/member/yellowpage/edit/enterprise/'+data.code;

+ 1 - 5
core/src/web/templates/member/microwebsite.html

@@ -127,11 +127,7 @@ $(function(){
 	});
 	});
 	$(".step-1 span").click(function(){
 	$(".step-1 span").click(function(){
 		if(isPreview){
 		if(isPreview){
-			if(this.id == "editService"){
-				loginModalShow(8);
-			}else{
-				loginModalShow(9);
-			}
+			loginModalShow();
 			return;
 			return;
 		}
 		}
 		$(".step-1 span").removeClass("selected");
 		$(".step-1 span").removeClass("selected");

+ 25 - 21
core/src/web/templates/swordfish/infolist.html

@@ -8,6 +8,30 @@
 	var lasttime=1,s_words,a_visitedindex,a_publishtime,le,f_id,a_interest;
 	var lasttime=1,s_words,a_visitedindex,a_publishtime,le,f_id,a_interest;
 $(function(){
 $(function(){
 	$(".b-nav>ul>li:eq(3)").addClass("b-nav-active");
 	$(".b-nav>ul>li:eq(3)").addClass("b-nav-active");
+	var s_words = [];
+	var a_interest = [];
+	if({{.T.msgset.o_msgset.bid.a_key}}){
+		s_words={{.T.msgset.o_msgset.bid.a_key}};
+	}
+	if({{.T.msgset.o_msgset.tender.a_key}}){
+		a_interest={{.T.msgset.o_msgset.tender.a_key}};
+	}
+	if(s_words.length!=0){
+		$("#okeywords").append(s_words.join(" ; ").replace(/\+/gm," "));
+	}else{
+		$("#zhaob").addClass("hide");
+	}
+	if(a_interest.length!=0){
+		$("#ointerest").append(a_interest.join(" ; ").replace(/\+/gm," "));
+	}else{
+		$("#zhongb").addClass("hide");
+	}
+	if(s_words.length==0 && a_interest.length==0){
+		$("#zhongb").before("关键词");
+	}
+	if(s_words.length!=0 && a_interest.length!=0){
+		$("#zhongb").append(",");
+	}
 	//
 	//
 	$.ajax({    
 	$.ajax({    
 		type:'post',        
 		type:'post',        
@@ -38,27 +62,7 @@ $(function(){
 				a_publishtime=temp["a_publishtime"];
 				a_publishtime=temp["a_publishtime"];
 				f_id=temp["_id"];
 				f_id=temp["_id"];
 			}
 			}
-			if({{.T.msgset.o_msgset.bid.a_key}}){
-				s_words={{.T.msgset.o_msgset.bid.a_key}};
-			}
-			if({{.T.msgset.o_msgset.tender.a_key}}){
-				a_interest={{.T.msgset.o_msgset.tender.a_key}};
-			}
-			$("#conlist").append('<div id="ycwords">'+str+'</div>');
-			if(s_words.length!=0){
-				$("#okeywords").append(s_words.join(" ; ").replace(/\+/gm," "));
-			}else{
-				$("#zhaob").addClass("hide");
-			}
-			if(a_interest.length!=0){
-				$("#ointerest").append(a_interest.join(" ; ").replace(/\+/gm," "));
-			}else{
-				$("#zhongb").addClass("hide");
-			}
-			if(s_words.length!=0 && a_interest.length!=0){
-				$("#zhongb").append(",");
-			}
-			
+			$("#conlist").append('<div id="ycwords">'+str+'</div>');			
 			//信息条总数
 			//信息条总数
 			le=$(".tslist").length;
 			le=$(".tslist").length;
 			//
 			//

+ 1 - 1
weixin/src/qfw/weixin/clickhandler.go

@@ -21,7 +21,7 @@ func ClickHandler(w ResponseWriter, r *Request) {
 					w.ReplyText("您已经提交认证信息,正在审核中,请耐心等待")
 					w.ReplyText("您已经提交认证信息,正在审核中,请耐心等待")
 				} else if state == 1 {
 				} else if state == 1 {
 					//w.ReplyText("身份验证通过。\n请点击<a href='http://" + wf.SysConfig.Domain + "/ent/wsite/edit/" + r.FromUserName + "'>进入微官网</a>")
 					//w.ReplyText("身份验证通过。\n请点击<a href='http://" + wf.SysConfig.Domain + "/ent/wsite/edit/" + r.FromUserName + "'>进入微官网</a>")
-					urlstr := "https://open.weixin.qq.com/connect/oauth2/authorize?appid=" + wf.SysConfig.Appid + "&redirect_uri=http://" + wf.SysConfig.Domain + "/weixinoauth?action=msiteaction&response_type=code&scope=snsapi_base&state=1#wechat_redirect"
+					urlstr := "https://open.weixin.qq.com/connect/oauth2/authorize?appid=" + wf.SysConfig.Appid + "&redirect_uri=http://" + wf.SysConfig.Domain + "/weixinoauth/action/msiteaction&response_type=code&scope=snsapi_base&state=1#wechat_redirect"
 					w.ReplyText("身份验证通过,\n请点击<a href='" + urlstr + "'>进入微官网</a>")
 					w.ReplyText("身份验证通过,\n请点击<a href='" + urlstr + "'>进入微官网</a>")
 				} else if err == nil && state == -1 {
 				} else if err == nil && state == -1 {
 					w.ReplyText("您提交的认证信息审核未通过,请重新提交认证信息")
 					w.ReplyText("您提交的认证信息审核未通过,请重新提交认证信息")