Browse Source

Merge branch 'develop' of 192.168.3.17:zhanghongbo/qfw into develop

zhangjinkun@topnet.net.cn 9 years ago
parent
commit
4ae1939343

+ 2 - 1
common/src/qfw/util/encrypt_test.go

@@ -22,9 +22,10 @@ func Test_sim(t *testing.T) {
 	//s2 := "GyUlIhEDDjcfWCAyIl4xBkgsERYiLAwZLCg9VkkbLj4zMRYDPRs5ATVZOxccPAkzFxw7CCpEFj41QlRAQFdFXlRMQVZcHRIbBgsWBxYcFQwEBwoa"
 
 	//s3 := "RFYoal5bCFdXWQoQB0JuWwlXAQFZCUVfFj4JMFtT"
-	s4 := "oJULtwzXo6EFV1Ah-XeyRBimXGM8,uid,123456,swordfishaction"
+	s4 := "oJULtwzXo6EFV1Ah-XeyRBimXGM8,uid,123456,wxpushlist"
 	se := SimpleEncrypt{Key: "topnet"}
 	log.Println("=====", se.EncodeString(s4))
+	log.Println("=====", se.EncodeString(",1349385977,ASD"))
 	log.Println("---", se.DecodeString("GyUlIhEDDjcfWCAyIl4xBkgsERYiLAwZLCg9VkkBHQtcX1FBR1hJWldCREMHFhUBBwccBxYA"))
 	now := time.Now()
 	tom := time.Date(now.Year(), now.Month(), now.Day(), 18, 0, 0, 0, time.Local)

+ 4 - 4
core/src/luckdraw.json

@@ -8,7 +8,7 @@
 	},{
 		"min":50,
 		"max":80,
-		"proportion":37.21
+		"proportion":16.71
 	},{
 		"min":95,
 		"max":120,
@@ -16,7 +16,7 @@
 	},{
 		"min":140,
 		"max":175,
-		"proportion":20
+		"proportion":50
 	},{
 		"min":190,
 		"max":220,
@@ -24,7 +24,7 @@
 	},{
 		"min":235,
 		"max":270,
-		"proportion":37.21
+		"proportion":16.71
 	},{
 		"min":280,
 		"max":310,
@@ -32,7 +32,7 @@
 	},{
 		"min":325,
 		"max":350,
-		"proportion":4
+		"proportion":15
 	}],
 	"promotioncode":"2001001501",
 	"weixin":{

+ 5 - 5
core/src/qfw/active/activemanage.go

@@ -211,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/timetask.json

@@ -1 +1 @@
-{"comment":{"c_rate":720,"commentrate":900},"market":{"demand":{"attr":["i_hits","i_bids","i_status"],"timepoint":"2016-01-27 12:14:08"},"service":{"attr":["i_hits","i_sales","i_comments","i_score","i_appcounts"],"timepoint":"2016-01-27 12:14:08"}},"marketisstart":true,"marketrate":300}
+{"comment":{"c_rate":720,"commentrate":900},"market":{"demand":{"attr":["i_hits","i_bids","i_status"],"timepoint":"2016-01-26 17:33:46"},"service":{"attr":["i_hits","i_sales","i_comments","i_score","i_appcounts"],"timepoint":"2016-01-26 17:33:46"}},"marketisstart":true,"marketrate":300}

+ 1 - 2
core/src/web/staticres/css/dev-qfw.css

@@ -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;
@@ -2373,7 +2372,7 @@ style="color:#D03102;margin-right:5px;"
 	margin-right: 5px;
 }
 .b-head .b-loginStatus{
-	padding: 0px 15px;
+	padding-left: 15px;
 	position: relative;
 	cursor: pointer;
 }

+ 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;

+ 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>

+ 4 - 1
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>
     <!-- 如果需要分页器 -->
@@ -51,6 +51,9 @@ $(function(){
         direction: 'vertical',
 		touchMoveStopPropagation: false,
 		virtualTranslate: true,
+		onInit: function(swiper){
+			$(swiper.slides[5]).children("img").attr("src","/wxswordfish/images/guide-6.png");
+		},
 		onSlideChangeStart: function(swiper){
 			var prevSlide = $(swiper.slides[swiper.previousIndex]);
 			prevSlide.addClass("slide-active");

+ 19 - 14
core/src/web/templates/swordfish/wxshareguide.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/share-cj.jpg">
 		</div>
     </div>
     <!-- 如果需要分页器 -->
@@ -65,6 +65,9 @@ $(function(){
         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;
@@ -73,26 +76,28 @@ $(function(){
 			var prevSlide = $(swiper.slides[swiper.previousIndex]);
 			prevSlide.addClass("slide-active");
 			var activeSlide = $(swiper.slides[swiper.activeIndex]);
-			if(currentIndex > swiper.activeIndex){
+			if(currentIndex == 0 && swiper.activeIndex == 0){
 				activeSlide.addClass("slide-down");
-			}else if(currentIndex < swiper.activeIndex){
-				activeSlide.addClass("slide-up");
+			}else{
+				if(currentIndex > swiper.activeIndex){
+					activeSlide.addClass("slide-down");
+				}else if(currentIndex < swiper.activeIndex){
+					activeSlide.addClass("slide-up");
+				}
 			}
 			currentIndex = swiper.activeIndex;
-			activeSlide.one("webkitAnimationEnd",function(){
-				$(this).removeClass("slide-up").removeClass("slide-down");
-				prevSlide.removeClass("slide-active");
-			});
-		},
-		onSliderMove: function(swiper, event){
-			if(swiper.isBeginning){
+			if(currentIndex == 7){
+				currentIndex = 0;
+			}
+			if(swiper.isEnd || swiper.activeIndex == 1){
 				$("#QRcode").show();
 			}else{
 				$("#QRcode").hide();
 			}
-			if(swiper.isEnd) {
-				currentIndex = 0;
-			}
+			activeSlide.one("webkitAnimationEnd",function(){
+				$(this).removeClass("slide-up").removeClass("slide-down");
+				prevSlide.removeClass("slide-active");
+			});
 		}
     });
 	/*

+ 19 - 16
push/src/qfw/push/rpcpush/rpcpush.go

@@ -5,6 +5,7 @@ import (
 	"log"
 	"qfw/push/bid"
 	"qfw/push/dopush"
+	"qfw/util"
 	qrpc "qfw/util/rpc"
 	"time"
 )
@@ -15,22 +16,24 @@ type PushInfo struct {
 var PushInfoScopeDays int
 
 func (p *PushInfo) PushMsg(data *qrpc.PushData, Reply *int) error {
-	log.Println("dddddddd", data)
-	for k, v := range data.PushType {
-		//昨天到今天的数据
-		pj := dopush.Pjob{
-			MaxPushSize: bid.MaxPushSize,
-			Stype:       k,
-			StypeName:   v,
+	log.Println("rpc_data", data)
+	util.Try(func() {
+		for k, v := range data.PushType {
+			//昨天到今天的数据
+			pj := dopush.Pjob{
+				MaxPushSize: bid.MaxPushSize,
+				Stype:       k,
+				StypeName:   v,
+			}
+			now := time.Now()
+			tom := time.Date(now.Year(), now.Month(), now.Day()-PushInfoScopeDays, 0, 0, 0, 0, time.Local)
+			b := pj.DoPush(data.Mopenid, fmt.Sprintf("%d days", PushInfoScopeDays), 2, tom.Unix())
+			if b {
+				*Reply = 1
+			} else {
+				*Reply = 0
+			}
 		}
-		now := time.Now()
-		tom := time.Date(now.Year(), now.Month(), now.Day()-PushInfoScopeDays, 0, 0, 0, 0, time.Local)
-		b := pj.DoPush(data.Mopenid, fmt.Sprintf("%d days", PushInfoScopeDays), 2, tom.Unix())
-		if b {
-			*Reply = 1
-		} else {
-			*Reply = 0
-		}
-	}
+	}, func(e interface{}) {})
 	return nil
 }