renzheng 9 years ago
parent
commit
666956018a

+ 13 - 13
core/src/luckdraw.json

@@ -3,36 +3,36 @@
 	"endDate":1455552000,
 	"getAmount":[{
 		"min":0,
-		"max":40,
+		"max":35,
 		"proportion":0
 	},{
 		"min":50,
-		"max":85,
-		"proportion":37.21
+		"max":80,
+		"proportion":16.71
 	},{
 		"min":95,
-		"max":130,
+		"max":120,
 		"proportion":0.5
 	},{
 		"min":140,
 		"max":175,
-		"proportion":20
+		"proportion":50
 	},{
-		"min":185,
+		"min":190,
 		"max":220,
 		"proportion":1
 	},{
-		"min":230,
-		"max":265,
-		"proportion":37.21
+		"min":235,
+		"max":270,
+		"proportion":16.71
 	},{
-		"min":275,
+		"min":280,
 		"max":310,
 		"proportion":0.08
 	},{
-		"min":320,
-		"max":355,
-		"proportion":4
+		"min":325,
+		"max":350,
+		"proportion":15
 	}],
 	"promotioncode":"2001001501",
 	"weixin":{

+ 34 - 24
core/src/qfw/active/activemanage.go

@@ -30,15 +30,15 @@ type Activemanage struct {
 //分享成功后建立redis判断值
 func (a *Activemanage) Addredis() error {
 	//
-	openid := a.Session().Get("openid").(string)
+	openid := a.Session().Get("s_m_openid").(string)
 	n := time.Now()
 	tmp := n.Unix()
 	n2 := n.AddDate(0, 0, 1)
 	yxq := time.Date(n2.Year(), n2.Month(), n2.Day(), 23, 59, 59, 0, time.Local).Unix() - tmp
-	yxqs := fmt.Sprintf("%d", yxq)
-	yxqt, _ := strconv.Atoi(yxqs)
+	//yxqs := fmt.Sprintf("%d", yxq)
+	//yxqt, _ := strconv.Atoi(yxqs)
 	key := fmt.Sprintf("cj_%s_%s", openid, n2.Format("2006_01_02"))
-	redis.Put("other", key, "cj", yxqt)
+	redis.Put("other", key, "cj", int(yxq))
 
 	return nil
 }
@@ -59,6 +59,11 @@ func (a *Activemanage) Luckdraw(activecode, id string) error {
 			a.T["msg"] = "您的微信号无效!!"
 			return a.Render("/active/luckdraw.html", &a.T)
 		}
+		a.SetSession("userName", username)
+		a.SetSession("userId", userid)
+		a.SetSession("s_m_openid", openid)
+		a.SetSession("s_actcode", activecode)
+
 		a.T["signature"] = mob.GetSignature(a.Url())
 		u := FindOne("winningrecord", "{'s_openid':'"+openid+"'}")
 		if *u != nil {
@@ -67,17 +72,14 @@ func (a *Activemanage) Luckdraw(activecode, id string) error {
 				a.T["flog"] = "A"
 				Tm := time.Now().AddDate(0, 0, 1)
 				if ret := redis.Get("other", "cj_"+openid+"_"+Tm.Format("2006_01_02")); ret == nil {
-					a.T["msg"] = "小主,快分享朋友圈或好友即获得明天的抽奖资格吧!千万不要再忘记了,大奖可能就在明天~"
+					a.T["msg"] = "  小主,快分享朋友圈或好友即获得明天的抽奖资格吧!千万不要再忘记了,大奖可能就在明天~"
 				} else {
-					a.T["msg"] = "小主莫贪心,每人每天只有一次抽奖机会呦!分享后明天再来吧!<br/><br/>  小主翻个牌子,动动小手分享活动,么么哒……(分享点击页面右上方···分享到朋友圈)"
+					a.T["msg"] = "  小主已获得明天的抽奖资格!明天记得要来啊~"
 				}
 				return a.Render("/active/luckdraw.html", &a.T)
 			}
 		}
-		a.SetSession("username", username)
-		a.SetSession("userid", userid)
-		a.SetSession("openid", openid)
-		a.SetSession("s_actcode", activecode)
+
 		return a.Render("/active/luckdraw.html", &a.T)
 	} else {
 		return nil
@@ -91,7 +93,7 @@ func (a *Activemanage) Getluckdraw() error {
 	msg := ""
 	id := ""
 	today := time.Now()
-	openid := a.GetSession("openid").(string)
+	openid := a.GetSession("s_m_openid").(string)
 	s_actcode := a.GetSession("s_actcode").(string)
 	if openid == "" {
 		msg = "  小主你太长时间没点击开始抽奖了,重新进来吧!"
@@ -102,7 +104,7 @@ func (a *Activemanage) Getluckdraw() error {
 			if ret := redis.Get("other", "cj_"+openid+"_"+time.Now().Format("2006_01_02")); ret == nil {
 				//a.T = *u
 				a.T["flog"] = "A"
-				a.T["msg"] = "小主莫贪心,每天只有一次抽奖机会呦!分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
+				a.T["msg"] = "  小主莫贪心,每天只有一次抽奖机会呦!分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
 				return a.Write(`{"flog":"` + flog + `","msg":"` + msg + `"}`)
 			}
 			redis.Del("other", "cj_"+openid+"_"+time.Now().Format("2006_01_02"))
@@ -144,8 +146,8 @@ func (a *Activemanage) Getluckdraw() error {
 		}
 		if coreutil.PayBonus(&bm) {
 			redpackage := make(bson.M)
-			redpackage["s_userid"] = a.GetSession("userid")
-			redpackage["s_username"] = a.GetSession("username")
+			redpackage["s_userid"] = a.GetSession("userId").(string)
+			redpackage["s_username"] = a.GetSession("userName").(string)
 			redpackage["s_openid"] = openid
 			redpackage["i_amount"] = amount
 			redpackage["s_billno"] = bm.Mchbillno
@@ -156,8 +158,16 @@ func (a *Activemanage) Getluckdraw() error {
 			redpackage["i_day"] = today.Day()
 			redpackage["s_actcode"] = s_actcode
 			Save("redpackage", redpackage)
+		} else {
+			redpackage_fail := make(bson.M)
+			redpackage_fail["s_username"] = a.GetSession("userName").(string)
+			redpackage_fail["s_openid"] = openid
+			redpackage_fail["i_amount"] = amount
+			redpackage_fail["l_createdate"] = today.Unix()
+			Save("redpackage_fail", redpackage_fail)
+
 		}
-		msg = "  小主是真真的好运气," + s_prize + "落入您囊中。红包将由系统自动发放到您的微信,请注意查收。<br/><br/>分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
+		msg = "  小主是真真的好运气," + s_prize + "落入您囊中。红包将由系统自动发放到您的微信,请注意查收。<br/><br/>  分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
 	} else if (i > 275 && i < 310) || (i > 95 && i < 130) {
 		//时间判断,提醒不同
 		//now := time.Now()
@@ -166,18 +176,18 @@ func (a *Activemanage) Getluckdraw() error {
 		//
 		//	msg = "  小主是真真的好运气," + s_prize + "落入您囊中!<br/>  请在微信留下您的联系方式(手机号或qq号),企明星客服会在下一个工作日9:00-17:00给小主回复哦!<br/>  小主翻个牌子,动动小手分享活动,么么哒……(分享点击页面右上方···分享到朋友圈)"
 		//} else { //在工作时间
-		msg = "  小主是真真的好运气," + s_prize + "落入您囊中。请将您的联系方式和邮寄地址留言给企明星。我们会在活动截止后尽快为您发出。<br/><br/>分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
+		msg = "  小主是真真的好运气," + s_prize + "落入您囊中。请将您的联系方式和邮寄地址留言给企明星。我们会在活动截止后尽快为您发出。<br/><br/>  分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
 		//}
 	} else if i > 140 && i < 175 {
-		obid := BsonIdToSId(a.GetSession("userid"))
+		obid := BsonIdToSId(a.GetSession("userId"))
 		b := credit.UpuserCreditSession(obid, "b6", "B", nil, a.Action)
 		if b == true {
-			msg = "  小主是真真的好运气,200积分落入您囊中。积分将由系统自动发放到您的企明星账户,请登录www.qmx.top查看。<br/><br/>分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
+			msg = "  小主是真真的好运气,200积分落入您囊中。积分将由系统自动发放到您的企明星账户,请登录www.qmx.top查看。<br/><br/>  分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
 		} else {
 			msg = "  抽奖出错!小主不要桑心,联系企明星管理员,200积分还是您的!"
 		}
 	} else { //不中奖
-		msg = "  小主不要桑心,这次没有中奖哦,明天记得要来拼运气啊!<br/><br/>分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
+		msg = "  小主不要桑心,这次没有中奖哦,明天记得要来拼运气啊!<br/><br/>  分享至朋友圈或好友即可以获得明天抽奖资格呦!乖,快去分享吧!大奖可能就在明天~~"
 	}
 	return a.Write(`{"flog":"` + flog + `","msg":"` + msg + `","rotate":` + strconv.Itoa(int(i)) + `}`)
 
@@ -201,22 +211,22 @@ func getLuckDraw() int {
 		} else if amount > 275 && amount < 310 {
 			count := Count("winningrecord", "{'s_prize':'《牛奶可乐经济学》'}")
 			if count > 6 {
-				amount = 240
+				amount = 245
 			}
 		} else if amount > 95 && amount < 130 {
 			count := Count("winningrecord", "{'s_prize':'限量版U盘'}")
 			if count > 100 {
-				amount = 260
+				amount = 255
 			}
 		} else if amount > 185 && amount < 220 {
 			count := Count("winningrecord", "{'s_prize':'五元现金红包'}")
 			if count > 200 {
-				amount = 60
+				amount = 65
 			}
 		} else if amount > 320 && amount < 355 {
 			count := Count("winningrecord", "{'s_prize':'一元现金红包'}")
-			if count > 1500 {
-				amount = 80
+			if count > 2500 {
+				amount = 75
 			}
 		}
 		return amount

+ 1 - 1
core/src/qfw/front/index.go

@@ -77,7 +77,7 @@ func (i *Index) LoadIndex() error {
 			}
 		}
 		//认证企业
-		entquery := `{"i_identificationstatus":1,"i_freeze":{"$ne":2}}`
+		entquery := `{"i_identificationstatus":1,"i_freeze":{"$ne":2},"i_identificationtype":{"$in":[1,5]}}`
 		entdata := *Find("identification", entquery, []string{"-l_auditdate"}, `{"s_enterprisename":1,"l_auditdate":1,"s_enterpriseid":1}`, false, 0, 8)
 		if entdata != nil {
 			for _, v := range entdata {

+ 1 - 1
core/src/qfw/mobile/mobile.go

@@ -10,7 +10,7 @@ type Mobile struct {
 	search         xweb.Mapper `xweb:"/ent/(.*)/search"`
 	detail         xweb.Mapper `xweb:"/ent/(.*)/detail/(.*)/(.*)"`
 	pageerror      xweb.Mapper `xweb:"/ent/(.*)/505"`
-	guide          xweb.Mapper `xweb:"/swordfish/guide"`
+	guide          xweb.Mapper `xweb:"/swordfish/guide/(.*)"`
 	share          xweb.Mapper `xweb:"/swordfish/share/([^.]*)"`
 	wxrssset       xweb.Mapper `xweb:"/swordfish/page"`
 	getMyCredit    xweb.Mapper `xweb:"/member/credit/getcredit"`

+ 8 - 4
core/src/qfw/mobile/wxmenu.go

@@ -22,11 +22,15 @@ var se util.SimpleEncrypt
 func init() {
 	se = util.SimpleEncrypt{Key: "topnet"}
 }
-
-func (m *Mobile) Guide() error {
+func (m *Mobile) Guide(sign string) error {
 	m.T["signature"] = GetSignature(m.Url())
 	m.T["shareid"] = cutil.FindMyShareId("topjy", m.Session().Get("s_m_openid").(string))
-	return m.Render("/swordfish/wxindex.html", &m.T)
+	m.T["sign"] = sign
+	if sign == "share" {
+		return m.Render("/swordfish/wxshareguide.html", &m.T)
+	} else {
+		return m.Render("/swordfish/wxindex.html", &m.T)
+	}
 }
 func (m *Mobile) Share(shareid string) error {
 	m.T["shareid"] = shareid
@@ -58,7 +62,7 @@ func (m *Mobile) Wxrssset() error {
 						"i_m_guide": 1,
 					},
 				}, false, false)
-				return m.Redirect("/swordfish/guide")
+				return m.Redirect("/swordfish/guide/first")
 			}
 			if (*userInfo)["o_msgset"] != nil {
 				for _, v := range (*userInfo)["o_msgset"].(map[string]interface{}) {

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

@@ -21,7 +21,7 @@ func (s *SwordFish) Swordfish() error {
 			s.T["data"] = r
 		}
 		content, _ := s.Render4Cache("/swordfish/index.html", &s.T)
-		redis.Put("other", "swordfish", string(content), 30*60*1000) //缓存半个小时
+		redis.Put("other", "swordfish", string(content), 30*60) //缓存半个小时
 		return s.SetBody(content)
 	}
 }
@@ -158,7 +158,7 @@ func getNewest() (list []interface{}) {
 		now := time.Now()
 		unix := time.Date(now.Year(), now.Month(), now.Day(), now.Hour()-2, now.Minute(), now.Second(), now.Nanosecond(), time.Local).Unix()
 		r := mongodb.Find("bidding", bson.M{"comeintime": bson.M{"$lte": unix}}, `{"comeintime":-1}`, `{"title":1,"href":1,"publishtime":1}`, false, 0, 5)
-		redis.Put("other", "swordfish_newest_list", *r, 30*60*1000) //缓存半个小时
+		redis.Put("other", "swordfish_newest_list", *r, 30*60) //缓存半个小时
 		for _, v := range *r {
 			list = append(list, v)
 		}

+ 4 - 5
core/src/web/staticres/css/dev-qfw.css

@@ -581,7 +581,7 @@ a{
 	border-left: 3px solid #FF5A5F;
 	width: 250px;
 	height: 45px;
-	margin:10px 0 10px 1px;
+	margin:1px 0 10px 1px;
 	line-height: 45px;
 	padding-left: 20px;
 	background: #FFF;
@@ -2268,7 +2268,6 @@ style="color:#D03102;margin-right:5px;"
 .b-top{
 	height: 25px;
 	line-height: 25px;
-	padding-right: 87px;
 	background-color: #464645;
 	font-size: 12px;
 	font-family: tahoma, arial, 'Hiragino Sans GB', 宋体, sans-serif;
@@ -2365,8 +2364,7 @@ style="color:#D03102;margin-right:5px;"
 .b-head .b-loginbtn{
 	width: 40px;
 	height: 40px;
-	margin-top: 13px;
-	margin-right: 30px;
+	margin-right: 10px;
 }
 .b-head .headimg{
 	width: 40px;
@@ -2374,8 +2372,9 @@ style="color:#D03102;margin-right:5px;"
 	margin-right: 5px;
 }
 .b-head .b-loginStatus{
-	padding: 0px 15px;
+	padding-left: 15px;
 	position: relative;
+	cursor: pointer;
 }
 .b-head .b-logined:hover{
 	background-color: #F7F9FB;

+ 1 - 1
core/src/web/staticres/css/index-new.css

@@ -209,7 +209,7 @@ a:focus, a:hover{
     color: #A0A0A0;
 }
 .a-index  .index-new-xwzx-con .index-new-xwzx-content{
-	height:40px;
+	height:45px;
 	width:200px;
     font-family: tahoma, arial, 'Hiragino Sans GB', 宋体, sans-serif;
     font-size: 12px;

BIN
core/src/web/staticres/images/activeimages/lotteryBg.png


BIN
core/src/web/staticres/images/choujiang.png


BIN
core/src/web/staticres/images/choujiang2.png


BIN
core/src/web/staticres/wxswordfish/images/index.png


+ 1 - 2
core/src/web/staticres/wxswordfish/style.css

@@ -378,8 +378,7 @@ img{
 .swiper-slide img{
 	/*position: relative;
 	top: 50%;
-	margin-top: -302px;
-	*/
+	margin-top: -302px;*/
 	width: 100%;
 	height: 100%;
 }

+ 1 - 1
core/src/web/templates/active/luckdraw.html

@@ -19,7 +19,7 @@
 <style>
 *{padding:0; margin:0;}
 .lotteryMain{ width:100%;}
-.lotteryBg{ width:100%; height:608px; margin:0 auto; background:url(/images/activeimages/lotteryBg.jpg) no-repeat top center; position:relative; overflow:hidden;background-size: 375px 508px;}
+.lotteryBg{ width:100%; height:608px; margin:0 auto; background:url(/images/activeimages/lotteryBg.png) no-repeat top center; position:relative; overflow:hidden;background-size: 375px 508px;}
 #run{ width:145px; height:145px; position:absolute; left:50%; top:50%;  margin-left:-73px; margin-top:-53px; z-index:1; transform:rotate(0deg); -ms-transform:rotate(0deg); }
 #btn_run{ width:80px; height:80px; background:url(/images/activeimages/btn_start.png) no-repeat; border:none; outline:none; position:absolute; left:50%; top:50%; margin-left:-40px; margin-top:-22px; z-index:2;cursor:pointer;background-position:0px 0px;background-size: 100% 100%;}
 .col-xs-12 p{

+ 1 - 1
core/src/web/templates/common/hotdemand.html

@@ -11,7 +11,7 @@
 						<ul style="    padding: 15px 0 20 10px;">
 							<li class="a-com-title" style="height:26px;"><div><a href="{{$v.s_link}}">{{$v.s_remark}}</a></div></li>
 							<li style="height:26px;color:#FF5A5F;font-size:14px;font-weight:600;overflow: hidden;" class="a-com-type">{{$v.o_extend.type}}</li>
-							<li style="height:26px;">{{if eq $v.o_extend.status "1"}}<img src="/images/u252.png">{{else}}<img src="/images/u288.png">{{end}}</li>
+							<li style="height:26px;"><img src="/images/u288.png"></li>
 							<li class="a-com-name" style="height:26px;"><div>{{$v.o_extend.entName}}</div></li>
 						</ul>
 					</li>

+ 5 - 2
core/src/web/templates/common/top.html

@@ -67,7 +67,7 @@ function b_loadTop(){
 				if(hasMsgCount){
 					html += '<a class="b-round-dot"></a>';
 				}
-				html += '</span><a href="/member/show/memberindex">'+result.nickName+'</a>';
+				html += '</span>'+result.nickName;
 				html += '<div id="head-hideMenu" class="head-hideMenu"><ul>'
 					    	+'<li onclick="window.location.href=\'/member/msgcenter\'"><i class="glyphicon youjian"></i><span>消息中心';
 				if(hasMsgCount){
@@ -78,6 +78,9 @@ function b_loadTop(){
 						+'<li onclick="window.location.href=\'/front/logout\'" class="border-b-0"><i class="glyphicon tuichu"></i>退出</li>';
 						+'</ul></div>';
 				$("#b-loginStatus").addClass("b-logined").html(html)
+				.click(function(){
+					window.location.href = "/member/show/memberindex";
+				})
 				.mouseover(function(){
 					$("#head-hideMenu").show();
 				}).mouseleave(function(){
@@ -96,7 +99,7 @@ function b_loadTop(){
 				}
 			}else{
 				isLogined = false;
-				var html = '<img class="b-loginbtn cursor-pointer" onclick="loginModalShow();" src="/images/swordfish/headimg.png">';
+				var html = '<span onclick="loginModalShow();"><img class="b-loginbtn" src="/images/swordfish/headimg.png">登录/注册</span>';
 				$("#b-loginStatus").html(html);
 				$("#bottom-bar>li").removeClass("invisible");
 				//登录

+ 1 - 0
core/src/web/templates/service/demand.html

@@ -18,6 +18,7 @@
 	.text-primary.a-com-title{
 		border-left:0px;
 		background:#F6F8FA;
+		margin-top:9px;
 		border:1px solid #E5E6E9;
 	}
 </style>

+ 3 - 1
core/src/web/templates/service/detail.html

@@ -41,6 +41,9 @@
 		    margin-left: -47px;
    		 margin-right: -15px;
 	}
+	.a-c-right>.a-com-title{
+		margin-top:2px;
+	}
 	.white_content {
 	display: none;
 	position: absolute;
@@ -352,7 +355,6 @@
 		{{include "/service/appointment.html"}}
     </div>
 	<div class="a-c-right">
-	{{include "/common/releasedemand.html"}}
 	{{include "/common/hotservice.html"}}
 	</div>
 </div>

+ 0 - 1
core/src/web/templates/service/list.html

@@ -292,7 +292,6 @@
 	</div>
 		</div>
 <div class="a-c-right hidden-xs">
-{{include "/common/releasedemand.html"}}
 {{if eq "demand" .T.querymap.c_searchtype}}
 {{include "/common/hotdemand.html"}}
 {{else}}

+ 3 - 0
core/src/web/templates/service/viewsingledemand.html

@@ -49,6 +49,9 @@
 				white-space: nowrap;
 				line-height:21px !important;
 			}
+			.a-c-right>.a-com-title {
+				margin-top:10px !important;
+			}
 		</style>
 		    {{include "/common/inc.html"}}
     <!-- extra CSS -->

+ 2 - 2
core/src/web/templates/swordfish/rssset.html

@@ -37,7 +37,7 @@
 					{{if .T.msgset.tender}}
 						{{if .T.msgset.tender.day}}
 							{{if gt 6 .T.msgset.tender.day}}
-							本栏目推送服务期还剩{{.T.msgset.tender.day}}天。想要服务不间断,请确保积分充足。 <a href="/member/credit/myCredit">去做任务赚积分</a>
+							本栏目推送服务期还剩<span style="color:red"> {{.T.msgset.tender.day}} </span>天。想要服务不间断,请确保积分充足。 <a href="/member/credit/myCredit">去做任务赚积分</a>
 							{{end}}
 						{{end}}
 					{{end}}
@@ -73,7 +73,7 @@
 					{{if .T.msgset.bid}}
 						{{if .T.msgset.bid.day}}
 							{{if gt 6 .T.msgset.bid.day}}
-							本栏目推送服务期还剩{{.T.msgset.bid.day}}天。想要服务不间断,请确保积分充足。 <a href="/member/credit/myCredit">去做任务赚积分</a>
+							本栏目推送服务期还剩<span style="color:red"> {{.T.msgset.bid.day}} </span>天。想要服务不间断,请确保积分充足。 <a href="/member/credit/myCredit">去做任务赚积分</a>
 							{{end}}
 						{{end}}
 					{{end}}

+ 6 - 4
core/src/web/templates/swordfish/wxindex.html

@@ -28,7 +28,7 @@
 			<img src="/wxswordfish/images/guide-5.png">
 		</div>
 		<div class="swiper-slide">
-			<img src="/wxswordfish/images/guide-6.png">
+			<img src="/wxswordfish/images/guide-1.png">
 		</div>
     </div>
     <!-- 如果需要分页器 -->
@@ -47,12 +47,14 @@ $(function(){
 	var currentIndex = 0;
 	var mySwiper = new Swiper('.swiper-container', {
         pagination: '.swiper-pagination',
-        paginationClickable: true,
+        paginationClickable: false,
         direction: 'vertical',
 		touchMoveStopPropagation: false,
 		virtualTranslate: true,
+		onInit: function(swiper){
+			$(swiper.slides[5]).children("img").attr("src","/wxswordfish/images/guide-6.png");
+		},
 		onSlideChangeStart: function(swiper){
-			console.info();
 			var prevSlide = $(swiper.slides[swiper.previousIndex]);
 			prevSlide.addClass("slide-active");
 			var activeSlide = $(swiper.slides[swiper.activeIndex]);
@@ -93,7 +95,7 @@ $(function(){
 	}*/
 });
 function pageJump(){
-	{{if session "userId"}}
+	{{if eq .T.sign "first"}}
 		window.location.href = '/swordfish/page';
 	{{else}}
 		history.go(-1);

+ 117 - 0
core/src/web/templates/swordfish/wxshareguide.html

@@ -0,0 +1,117 @@
+<html>
+<head>
+<title>企明星-剑鱼-演示</title>
+<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
+<link href="/wxswordfish/style.css" rel="stylesheet">
+<link href="/swiper/swiper.min.css" rel="stylesheet">
+<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
+<script src="/js/jquery.js"></script>
+<script src="/wxswordfish/share.js"></script>
+<script src="/swiper/swiper.min.js"></script>
+</head>
+<body>
+<div class="swiper-container">
+    <div class="swiper-wrapper">
+        <div class="swiper-slide">
+			<img src="/wxswordfish/images/share-cj.jpg" alt="Cinque Terre">
+		</div>
+       	<div class="swiper-slide">
+			<img src="/wxswordfish/images/guide-2.png">
+		</div>
+       	<div class="swiper-slide">
+			<img src="/wxswordfish/images/guide-3.png">
+		</div>
+		<div class="swiper-slide">
+			<img src="/wxswordfish/images/guide-4.png">
+		</div>
+		<div class="swiper-slide">
+			<img src="/wxswordfish/images/guide-5.png">
+		</div>
+		<div class="swiper-slide">
+			<img src="/wxswordfish/images/share-cj.jpg">
+		</div>
+    </div>
+    <!-- 如果需要分页器 -->
+   	<div class="swiper-pagination"></div>
+	<div class="guide-bottom">
+		<img class="arrow-up" src="/wxswordfish/images/up.png">
+		<img src="/wxswordfish/images/index.png" class="jumpGuide" onclick="history.go(-1);">
+	</div>
+</div>
+<img id="QRcode" style="position:absolute;z-index: 2;" src="/front/weixinshare/{{.T.shareid}}" >
+<script type="text/javascript">
+$(function(){
+	initShare({{.T.signature}},{{.T.shareid}});
+	var width = $(window).width();
+	var height = $(window).height();
+	var defaultHeight = 480;
+	var max = 750;
+	if(width > max){
+		width = max;
+	}
+	width = width*0.48;
+	var top = 380;
+	if(height > defaultHeight){
+		top = 380 / defaultHeight * height;
+	}
+	$("#QRcode").css({"width":width,"top": top-width,"left":"50%","margin-left": -(width/2)});
+	$(".bottom-toolbar,.feedback-dialog").remove();
+	var currentIndex = 0;
+	var flag = true;
+	var mySwiper = new Swiper('.swiper-container', {
+		loop: true,
+        pagination: '.swiper-pagination',
+        paginationClickable: false,
+        direction: 'vertical',
+		touchMoveStopPropagation: false,
+		virtualTranslate: true,
+		onInit: function(swiper){
+			$("[data-swiper-slide-index='5']>img").attr("src","/wxswordfish/images/guide-6.png");
+		},
+		onSlideChangeStart: function(swiper){
+			if(flag){
+				flag = false;
+				return;
+			}
+			var prevSlide = $(swiper.slides[swiper.previousIndex]);
+			prevSlide.addClass("slide-active");
+			var activeSlide = $(swiper.slides[swiper.activeIndex]);
+			if(currentIndex == 0 && swiper.activeIndex == 0){
+				activeSlide.addClass("slide-down");
+			}else{
+				if(currentIndex > swiper.activeIndex){
+					activeSlide.addClass("slide-down");
+				}else if(currentIndex < swiper.activeIndex){
+					activeSlide.addClass("slide-up");
+				}
+			}
+			currentIndex = swiper.activeIndex;
+			if(currentIndex == 7){
+				currentIndex = 0;
+			}
+			if(swiper.isEnd || swiper.activeIndex == 1){
+				$("#QRcode").show();
+			}else{
+				$("#QRcode").hide();
+			}
+			activeSlide.one("webkitAnimationEnd",function(){
+				$(this).removeClass("slide-up").removeClass("slide-down");
+				prevSlide.removeClass("slide-active");
+			});
+		}
+    });
+	/*
+	var imgHeight = 1159;
+	var imgWidth = 750;
+	var width = document.body.clientWidth;
+	var height = document.body.clientHeight;
+	if(imgWidth > width){
+		var h = width / imgWidth * imgHeight;
+		$(".swiper-slide img").css({width: width,height: h,marginTop: -(h / 2)});
+	}else if(imgHeight > height){
+		$(".swiper-slide img").css({width: height / imgHeight * imgWidth,height: height,marginTop: -(height / 2)});
+	}*/
+});
+</script>
+</body>
+</html>

+ 4 - 8
core/src/web/templates/swordfish/wxtoolbar.html

@@ -76,7 +76,7 @@
 var feedback = null;
 $(function(){
 	$("#goToGuide").click(function(){
-		window.location.href = "/swordfish/guide";
+		window.location.href = "/swordfish/guide/other";
 	});
 	$("#feedback").click(function(){
 		if(feedback == null){
@@ -86,13 +86,9 @@ $(function(){
 		$("#feedback-textarea").focus().parent().removeClass("red-border");
 	});
 	$("[id='goToShare']").click(function(){
-		/*if(typeof(shareid) == "undefined" || shareid == ""){
-			window.location.href = "/swordfish/share/-1";
-		}else{
-			window.location.href = "/swordfish/share/"+shareid;
-		}*/
-		$(".share-dialog").show();
-		$("html,body").addClass("overflow-hidden");
+		window.location.href = "/swordfish/guide/share";
+		/*$(".share-dialog").show();
+		$("html,body").addClass("overflow-hidden");*/
 	});
 	$("#share-dialog-back").click(function(){
 		$(".share-dialog").hide();

+ 35 - 33
weixin/src/config.json

@@ -1,37 +1,39 @@
 {
-    "port": "82",
-    "domain": "127.0.0.1",
-    "imgpath": "/opt/qfw_dev",
-    "redisServers": "enterprise=192.168.3.14:1379,service=192.168.3.14:2379,other=192.168.3.14:3379,sso=192.168.3.14:1379",
-    "mongodbServers": "192.168.3.18:27080",
-    "elasticsearch": "http://192.168.3.18:9800",
-    "elasticPoolSize": 30,
-    "mongodbPoolSize": 5,
-    "mongodbName": "qfw",
-    "rpcport": "83",
-    "serviceTip": "服务指南",
-    "appcontext": "weixin",
-    "appid": "wx9852f95aa927e646",
-    "token": "topnet2015",
-    "appsecret": "d4624c36b6795d1d99dcf0547af5443d",
-    "aboutmeurl": "http://mp.weixin.qq.com/s?__biz=MzA5MTk0MTk5Ng==&mid=211196233&idx=1&sn=4cfc27b0f739358654c28a985150f1c0#rd",
-    "conactusurl": "",
-    "wsqurl": "http://s.p.qq.com/pub/jump?d=AAAXeGLZ",
+	"port":"82",
+	"domain":"www.qimingxing.info",
+	"imgpath":"/opt/qfw_dev/web/staticres",
+	"mongodbServers": "10.116.86.154:27080",
+	"elasticsearch":"http://10.116.86.154:9800",
+        "elasticPoolSize": 30,
+	"mongodbPoolSize":5,
+	"mongodbName":"qfw",	"redisServers":"enterprise=10.116.86.154:1379,service=10.116.86.154:2379,other=10.116.86.154:3379,sso=10.116.86.154:1379,credit=10.116.86.154:4379",
+	"rpcport":"83",
+	"serviceTip":"服务指南",
+	"appcontext":"weixin",
+	"appid":"wx9fbe26c14a196021",
+	"token":"topnet2015",
+	"appsecret":"3243545279b584dd574a595071395be4",
+        "aboutmeurl":"http://www.qimingxing.info/article/aboutme",
+        "conactusurl":"http://www.qimingxing.info/article/contactus",
+	"wsqurl": "http://s.p.qq.com/pub/jump?d=AAAXeGLZ",
 	"entAuthTip":",请按向导进行操作。第1步(共2步):请输入完整的企业名称。\n(认证过程只涉及您所在企业的公开信息。除非事先获得您的授权,企明星不会将您的个人隐私信息公开或透露给第三方机构。输入q或Q,退出认证操作。)",
 	"perAuthTip":",请按向导进行操作。第1步(共2步):请输入商家名称。\n(除非事先获得您的授权,企明星不会将您的个人隐私信息公开或透露给第三方机构。输入q或Q,退出认证操作。)",
 	"othAuthTip":",请按向导进行操作。第1步(共2步):请输入完整的组织机构名称。\n(认证过程只涉及您所在机构的公开信息。除非事先获得您的授权,企明星不会将您的个人隐私信息公开或透露给第三方机构。输入q或Q,退出认证操作。)",
-	"oWelcomeTip":"您已成功注册企明星!\n企明星是一个为全国企业提供专业化服务的互联网平台。",
-        "loginTip":"您已经成功登录企明星,请在电脑端操作。",
-        "freezeTip":"您的帐号已经冻结,请联系管理员。",
-        "messagetpl":{
-                "identifytplid":"sKn4r0or615ETYC-aI5OACPO_Q4-B8GYmgWoqcDghN4",
-                "offLinemsgtplid":"ExIeyFfoDNVJXhRDq09JbsjH_zbEJCB6gw6rxcV7atw",
-                "msgnotifytplid":"fcke7PqteAtclzHV3ScdiePH48vxaH6M5aJF0O_7by8",
-                "managernotifytplid":"DIwMrPQToOhGfa6ZAQCCrqquzbLKajiXsKY0K_lQtWQ"
-        },"activity":{
-                "activitycode":"topcj",
-                "title":"企明星新年抽奖活动进行中",
-                "picurl":"http://www.qimingxing.info/images/choujiang.png"
-        },"weixinautorpl":"小主的吩咐我们已经收到了,请留下您的联系方式(手机号或qq号),企明星客服会在下一个工作日9:00-17:00给小主回复哦!",
-		"creditRpc":"127.0.0.1:8765"
-}
+	"welcomeTip":"您已成功注册企明星!企明星是一个为全国企业提供专业化服务的互联网平台。企明星提供企业服务交易、剑鱼招标订阅、免费企业查询等多项服务。\n新春到,剑鱼送祝福,企明星幸运抽奖活动火热举行中,回复抽奖,即可参与活动。",
+	"oWelcomeTip":"您已成功注册企明星!企明星是一个为全国企业提供专业化服务的互联网平台。企明星提供企业服务交易、剑鱼招标订阅、免费企业查询等多项服务。\n新春到,剑鱼送祝福,企明星幸运抽奖活动火热举行中,回复抽奖,即可参与活动。",
+	"loginTip":"您已经成功登录企明星。",
+	"freezeTip":"您的帐号已经冻结,请联系管理员。",
+	"messagetpl":{
+		"identifytplid":"oGxkPyaV42z3KWykt58Tow9mBe_ImJvi8R3ajorVWOY",
+		"offLinemsgtplid":"ExIeyFfoDNVJXhRDq09JbsjH_zbEJCB6gw6rxcV7atw",
+		"msgnotifytplid":"b7iuAMiTCIolnPhTdueKBVYThEMf2D-Bh2M_9v3J-68",
+		"managernotifytplid":"dplgu5Q644vzPdqcPXY7RqgItS3eXACmU1XDl27CvTA"
+	},
+	"activity":{
+		"activitycode":"topcj",
+		"title":"企明星新年抽奖活动进行中",
+		"picurl":"http://www.qimingxing.info/images/choujiang2.png"
+	},"weixinautorpl":"小主的吩咐我们已经收到了,请留下您的联系方式(手机号或qq号),企明星客服会在下一个工作日9:00-17:00给小主回复哦!",
+	"creditRpc":"127.0.0.1:8765"
+
+}