Procházet zdrojové kódy

Merge branch 'dev2.8.5' of http://192.168.3.207:10080/qmx/jy into dev2.8.5

xuzhiheng před 5 roky
rodič
revize
de21655e4c

+ 10 - 9
src/jfw/front/swordfish.go

@@ -2379,8 +2379,10 @@ func (f *Front) HasPushHistory() {
 		var oneRemind = int64(1 * 24 * 60 * 60)
 		var o_vipjy map[string]interface{}
 		o_vipjy, _ = (*user)["o_vipjy"].(map[string]interface{})
-		a_itmes := util.ObjArrToMapArr(o_vipjy["a_items"].([]interface{}))
-		hasKeyFlag = len(a_itmes) > 0
+		if o_vipjy["a_items"] != nil {
+			a_itmes := util.ObjArrToMapArr(o_vipjy["a_items"].([]interface{}))
+			hasKeyFlag = len(a_itmes) > 0
+		}
 		isVipFlag = true
 		isPassCount = redis.GetInt("pushcache_2_a", "oncecount_"+tedayNum+"_"+userId) > 2000
 		isOnTail = util.IntAll((*user)["i_vip_status"])
@@ -2405,19 +2407,18 @@ func (f *Front) HasPushHistory() {
 		}
 		isPassCount = redis.GetInt("pushcache_2_a", "oncecount_"+tedayNum+"_"+userId) > 50
 	}
-	//	hasNextPage, list, err := public.HistoryPush.Datas(userId, 1, firstPushTime, formatTime)
-	//	if err == nil && hasKeyFlag && len(list) == 0 && formatTime == "" && !isVipFlag {
-	//		flag, data := public.HistoryPush.MakeHistoryDatas(userId, bidSearch_field_1)
-	//		if flag && data != nil {
-	//			list = data
-	//		}
-	//	}
 	pageNum, _ := f.GetInteger("pageNum")
 	if pageNum == 0 {
 		pageNum = 1
 	}
 	area := f.GetString("area")
 	hasNextPage, list := public.HistoryPush.Datas_Mysql(userId, pageNum, formatTime, area)
+	if hasKeyFlag && len(list) == 0 && formatTime == "" && !isVipFlag {
+		flag, data := public.HistoryPush.MakeHistoryDatas(userId, bidSearch_field_1)
+		if flag && data != nil {
+			list = data
+		}
+	}
 	//
 	f.ServeJson(map[string]interface{}{
 		"haskey":      hasKeyFlag,

+ 58 - 2
src/jfw/modules/subscribepay/src/service/orderListDetails.go

@@ -245,8 +245,8 @@ func (o *OrderListDetails) SetEmail() {
 		var email_used = true
 		if email != o.GetSession("EmailBindingVerifyEmail") {
 			//user表里校验邮箱是否被使用  字段待定
-			res, _ := util.MQFW.FindOne("user", bson.M{"email": email})
-			if res != nil && qutil.ObjToString((*res)["email"]) != "" {
+			res, _ := util.MQFW.FindOne("user", bson.M{"s_myemail": email})
+			if res != nil && qutil.ObjToString((*res)["s_myemail"]) != "" {
 				email_used = false
 				o.T["success"] = false
 				o.T["errCode"] = 4
@@ -354,6 +354,25 @@ func (o *OrderListDetails) SetRes(res []map[string]interface{}, queryM map[strin
 	}
 	delete(queryM, "product_type")
 	for _, v := range res {
+		//获取单号 如果是vip 48小时取消
+		//order_code := qutil.ObjToString(v["order_code"])
+		//go FortyEightHoursCancel(order_code)
+
+		create_time_str := qutil.ObjToString(v["create_time"])
+		//创建时间戳
+		create_time, _ := time.ParseInLocation(qutil.Date_Full_Layout, create_time_str, time.Local)
+		//48小时后的时间戳
+		create_time_stamp := create_time.AddDate(0, 0, 2).Unix()
+		//当前时间时间戳
+		now_time_stamp := time.Now().Unix()
+		if create_time_stamp < now_time_stamp && qutil.ObjToString(v["product_type"]) == "VIP订阅" {
+			if v["order_status"] != nil {
+				order_status := qutil.Int64All(v["order_status"])
+				if order_status == 0 {
+					v["order_status"] = orderStatus_cancel
+				}
+			}
+		}
 		if v["filter_publishtime"] != nil {
 			filter_publishtime := v["filter_publishtime"]
 			if filter_publishtime != nil {
@@ -436,3 +455,40 @@ func getPayTransactionId(payWay, tradeNo string) (transaction_id string) {
 	}
 	return
 }
+
+//检查vip订单是否到期,如果到期 订单取消48h
+func FortyEightHoursCancel(order string) {
+	//查询vip订单条件
+	queryM := map[string]interface{}{
+		"order_code":   order,
+		"product_type": "VIP订阅",
+	}
+	flag := false
+	//order := util.Mysql.FindOne(tableName_order, queryMap, "pay_way,out_trade_no,prepay_time,order_status", "")
+	res := util.Mysql.FindOne(tableName_order, queryM, "id,order_code,create_time,pay_way,out_trade_no,prepay_time,order_status,user_id", "")
+	if res != nil {
+		id := qutil.Int64All((*res)["id"])
+		queryMap := map[string]interface{}{
+			"id":      id,
+			"user_id": qutil.ObjToString((*res)["user_id"]),
+		}
+		create_time_str := qutil.ObjToString((*res)["create_time"])
+		//创建时间戳
+		create_time, _ := time.ParseInLocation(qutil.Date_Full_Layout, create_time_str, time.Local)
+		//48小时后的时间戳
+		create_time_stamp := create_time.AddDate(0, 0, 2).Unix()
+		//当前时间时间戳
+		now_time_stamp := time.Now().Unix()
+		//如果超过48小时 取消订单
+		if create_time_stamp < now_time_stamp {
+			if qutil.IntAll((*res)["order_status"]) == 0 { //未支付状态下 删除订单需要先关闭订单
+				flag = pay.CloseDataExportOrder(qutil.ObjToString((*res)["pay_way"]), qutil.ObjToString((*res)["out_trade_no"]), qutil.ObjToString((*res)["prepay_time"]))
+			} else {
+				flag = true
+			}
+			if flag {
+				flag = util.Mysql.Update(tableName_order, queryMap, map[string]interface{}{"order_status": -2})
+			}
+		}
+	}
+}

+ 23 - 13
src/jfw/public/historypush.go

@@ -426,15 +426,25 @@ func (h *historyPush) getInfoByIds(pushCas []*jy.PushCa) []map[string]interface{
 func (h *historyPush) MakeHistoryDatas(userId, field string) (bool, []map[string]interface{}) {
 	allquery := `{"range":{"publishtime":{"gt":%s}}}`
 	allquery = fmt.Sprintf(allquery, fmt.Sprint(time.Now().AddDate(0, 0, -7).Unix()))
-	//allquery := ``
-	_, list := PushView(userId, allquery, field, 1, 50)
+	allquery = ``
+	keys, list := PushView(userId, allquery, field, 1, 50)
 	if list == nil || len(*list) == 0 {
 		return true, nil
 	}
+	matchkeys := []string{}
+	if len(keys) > 0 {
+		for _, v := range keys {
+			for _, k := range util.ObjArrToStringArr(v.([]interface{})) {
+				matchkeys = append(matchkeys, k)
+			}
+		}
+	}
 	result := []map[string]interface{}{}
-	pushinfo := []string{}
+	fields := []string{"userid", "infoid", "date", "matchkeys", "area", "city", "type", "subscopeclass"}
+	values := []interface{}{}
 	publishTitle := map[string]bool{}
 	now := time.Now()
+	keystr := strings.Join(matchkeys, " ")
 	for k, v := range *list {
 		title := strings.Replace(v["title"].(string), "\n", "", -1)
 		area_check := util.ObjToString(v["area"])
@@ -443,8 +453,7 @@ func (h *historyPush) MakeHistoryDatas(userId, field string) (bool, []map[string
 		} else {
 			publishTitle[area_check+title] = true
 		}
-		pushinfo = append(pushinfo, util.ObjToString(v["_id"]))
-
+		values = append(values, userId, util.ObjToString(v["_id"]), now.Unix(), keystr, area_check, "", 0, v["s_subscopeclass"])
 		info := map[string]interface{}{
 			"area":             area_check,
 			"_id":              util.EncodeArticleId2ByCheck(util.ObjToString(v["_id"])),
@@ -462,6 +471,8 @@ func (h *historyPush) MakeHistoryDatas(userId, field string) (bool, []map[string
 			"title":            title,
 			"ca_isvisit_index": k + 1,
 			"ca_date":          now.Unix(),
+			"ca_isvisit":       0,
+			"matchkeys":        matchkeys,
 		}
 		area := util.ObjToString(info["area"])
 		if area == "A" {
@@ -505,14 +516,13 @@ func (h *historyPush) MakeHistoryDatas(userId, field string) (bool, []map[string
 
 		result = append(result, info)
 	}
-	wxpush := map[string]interface{}{
-		"dateymd":  now.Format(util.Date_yyyyMMdd),
-		"date":     now.Unix(),
-		"uid":      userId,
-		"pushinfo": strings.Join(pushinfo, ","),
-	}
-	flag := Ca_Push.SaveCacheByTimeOut("jy_pushhistory", wxpush, 10)
-	return flag, result
+	go func(fields []string, values []interface{}) {
+		count := Mysql.InsertBatch("pushsubscribe", fields, values)
+		if int(count) == len(values) {
+			log.Println("mysql insert  true")
+		}
+	}(fields, values)
+	return true, result
 }
 
 //获取用户信息

+ 4 - 4
src/web/staticres/vipsubscribe/js/keyWord.js

@@ -1,4 +1,5 @@
-$(function () {
+
+var reloadFunc = function(){
     
     //去空格方法
     // String.prototype.trim = function () {
@@ -41,7 +42,7 @@ $(function () {
     // 添加 确认按钮的点击事件
     $('.content .addkeyWord .btn button').on('click', function () {
         var keyWord = $('.addkeyWord input.enterOne').val();
-		if($.inArray(keyWord, kws_arr)>-1){
+		if(kws_arr[keyWord]!=undefined){
             weui.toast('您设置的关键词已存在,请调整后再添加。', {
                 duration: 2000,
                 className: 'custom-toast',
@@ -285,5 +286,4 @@ $(function () {
         $('.classify-edit-pop').hide()
         $('input.classify-keyword').val('')
     })
-
-})
+}

+ 2 - 1
src/web/templates/weixin/dataExport/dataExport_toMyOrder.html

@@ -440,7 +440,7 @@
 			function beforeJump(eid,isVipOrder){
 				setSessionStorage();
 				if (isVipOrder=="true"){
-					window.location.href="/front/vipsubscribe/toOrderDetailPage?orderCode="+eid;
+					window.location.href="/weixin/pay/toOrderDetailPage?orderCode="+eid;
 				}else{
 					window.location.href="/weixin/pay/wxToOrderDetail?orderCode="+eid;
 				}
@@ -633,6 +633,7 @@
 					var result = true;
 					$.post("/subscribepay/orderListDetails/myOrder",{"type":typ},function(data){
 							$(".loading_").hide();
+							console.log(data.res)
 							var list=data.res;
 							dataCache =data.res;
 							pageIndex=2;

+ 4 - 4
src/web/templates/weixin/email/bind_email.html

@@ -114,13 +114,13 @@
 								if(data.success){
 									if ($("#bindBtn").text()=="确定"){	//更改绑定
 										sessionStorage.removeItem("send_myemail_"+{{.T.userId}});
-										window.location.replace("/front/wxMyOrder/setSuccess?name=changeEmail"); 
+										window.location.replace("/jyapp/front/myorder/setSuccess?name=changeEmail"); 
 									}else{
 										sessionStorage.removeItem("send_myemail_"+{{.T.userId}});
-										if((param="invoice")&&(orderCode!="")){
-											window.location.replace("/front/wxMyOrder/setSuccess?name=invoice&orderCode="+orderCode); 
+										if((param="invoice")&&(orderCode!=null)){
+											window.location.replace("/jyapp/front/myorder/setSuccess?name=invoice&orderCode="+orderCode); 
 										}else{
-											window.location.replace("/front/wxMyOrder/setSuccess?name=bindEmail"); 
+											window.location.replace("/jyapp/front/myorder/setSuccess?name=bindEmail"); 
 										}
 									}
 								}

+ 57 - 11
src/web/templates/weixin/email/bind_success.html

@@ -1,33 +1,79 @@
 <!DOCTYPE html>
 <html>
 	<head>
-		<meta charset="utf-8">
		<title>绑定成功</title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
+		<meta charset="utf-8">
+		<title>绑定成功</title>
+		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
 		<link rel="stylesheet" href="{{Msg "seo" "cdn"}}/wxmyemail/css/reset.css?v={{Msg "seo" "version"}}">
 		<link rel="stylesheet" href="{{Msg "seo" "cdn"}}/wxmyemail/css/common.css?v={{Msg "seo" "version"}}">
 		<link rel="stylesheet" href="{{Msg "seo" "cdn"}}/wxmyemail/css/mine.css?v={{Msg "seo" "version"}}"/>   
 		{{include "/common/weixin.html"}}
-		<script src="{{Msg "seo" "cdn"}}/wxswordfish/share.js?v={{Msg "seo" "version"}}"></script>    
+		<script src="{{Msg "seo" "cdn"}}/wxswordfish/share.js?v={{Msg "seo" "version"}}"></script>    
 	</head>
 	<body>
-		<div class="bind_success">
			<div class="success">
				<img src="{{Msg "seo" "cdn"}}/wxmyemail/img/successed.png" >
				<p></p>
			</div>
			<button class="common_btn back">返回 <time class="time">()</time> </button>
		</div>
		<script src="{{Msg "seo" "cdn"}}/wxmyemail/js/zepto.js"></script>
		<script src="{{Msg "seo" "cdn"}}/wxmyemail/js/public.js"></script>
		<script>
			$(function(){
+		<div class="bind_success">
+			<div class="success">
+				<img src="{{Msg "seo" "cdn"}}/wxmyemail/img/successed.png" >
+				<p></p>
+			</div>
+			<button class="common_btn back">返回 <time class="time">()</time> </button>
+		</div>
+		<script src="{{Msg "seo" "cdn"}}/wxmyemail/js/zepto.js"></script>
+		<script src="{{Msg "seo" "cdn"}}/wxmyemail/js/public.js"></script>
+		<script>
+			$(function(){
 				//分享
-				initShare({{.T.signature}},{{.T.openid}},2,"jy_wxmyorder",{{.T.nickname}},{{.T.avatar}});
				
+				initShare({{.T.signature}},{{.T.openid}},2,"jy_wxmyorder",{{.T.nickname}},{{.T.avatar}});
+				
 				let param = getParam('name');//获取url传来的参数 判断显示成功的字幕
-				var orderCode=getParam("orderCode"); //开发票的订单
				console.log(param)
				var time = 6;
				function countDown(){
					if(time == 0){
						$('.time').html('');
+				var orderCode=getParam("orderCode"); //开发票的订单
+				console.log(param)
+				var time = 6;
+				function countDown(){
+					if(time == 0){
+						$('.time').html('');
 						if((param="invoice")&&(orderCode!="")){
-							window.location.replace('/front/vipsubscribe/toOrderDetailPage?orderCode='+orderCode);
+							window.location.replace('/weixin/pay/toOrderDetailPage?orderCode='+orderCode);
 						}else{
 							window.location.replace('/front/wxMyOrder/myEmail');
-						}
					}else{
						$('.time').html('(' + time + ')');
						time--;
						setTimeout(()=>{
							countDown()
						},1000)
					}
				}
				if(param == 'bindEmail'){
					$('.success>p').html('邮箱绑定成功');
					countDown();
				}else if(param == 'bindPhoe'){
					$('.success>p').html('手机号绑定成功');
					countDown();
				}else if(param == 'changeEmail'){
					$('.success>p').html('邮箱更换成功');
					countDown();
				}else if(param == 'choosePhone'){
					$('.success>p').html('手机号更换成功');
					countDown();
				}else if(param =="unbind"){
+						}
+					}else{
+						$('.time').html('(' + time + ')');
+						time--;
+						setTimeout(()=>{
+							countDown()
+						},1000)
+					}
+				}
+				if(param == 'bindEmail'){
+					$('.success>p').html('邮箱绑定成功');
+					countDown();
+				}else if(param == 'bindPhoe'){
+					$('.success>p').html('手机号绑定成功');
+					countDown();
+				}else if(param == 'changeEmail'){
+					$('.success>p').html('邮箱更换成功');
+					countDown();
+				}else if(param == 'choosePhone'){
+					$('.success>p').html('手机号更换成功');
+					countDown();
+				}else if(param =="unbind"){
 					$('.success>p').html('邮箱解绑成功');
 					countDown();
 				}else if(param=="invoice"){
 					$('.success>p').html('邮箱绑定成功');
 					countDown();
-				}
				/* 返回 */
				$('.back').on('click',() =>{
					if((param="invoice")&&(orderCode!="")){
-							window.location.replace('/front/vipsubscribe/toOrderDetailPage?orderCode='+orderCode);
+				}
+				/* 返回 */
+				$('.back').on('click',() =>{
+					if((param="invoice")&&(orderCode!="")){
+							window.location.replace('/weixin/pay/toOrderDetailPage?orderCode='+orderCode);
 						}else{
 							window.location.replace('/front/wxMyOrder/myEmail');
-						}
				})
			})
		</script>
-	{{include "/common/baiducc.html"}}
	</body>
+						}
+				})
+			})
+		</script>
+	{{include "/common/baiducc.html"}}
+	</body>
 </html>

+ 2 - 2
src/web/templates/weixin/historypush.html

@@ -149,8 +149,8 @@
 				setSessionStorage();
 				window.location.href='/wxkeyset/keyset/index';
 			});
-			console.log(firstPage.length)
-			if(firstPage.length==0){
+			//console.log(firstPage.length)
+			if(firstPage==null||firstPage.length==0){
 				//最开始没有数据 
 				hasNoData();
 				$(".findnull_").show();

+ 67 - 44
src/web/templates/weixin/vipsubscribe/keyWord.html

@@ -232,15 +232,7 @@
 	<script src="{{Msg "seo" "cdn"}}/wxswordfish/share.js?v={{Msg "seo" "version"}}"></script>
     <script>
 		initShare({{.T.signature}},{{.T.openid}},2,"jy_extend",{{.T.nickname}},{{.T.avatar}});
-        weui.loading();
-        setTimeout(function(){
-            weui.loading().hide();
-            if(window.location.search.indexOf("page=1")>-1){
-				history.replaceState("{id:1}","","/front/vipsubscribe/toSetKeyWordPage")
-            }else if(history.state){
-                window.history.go(-1)
-			}
-        },500)
+        
         var a_items = [];//全部数据
         var classify_name = "";//分类名称
         var classify_index = 0;//分类索引
@@ -251,15 +243,69 @@
         var addition_kws = []; //附加词
         var not_kws = []; //排除词
         var classify_arr = [];//分类对象
-        var kws_arr = [];//所有关键词对象
+        var kws_arr = {};//所有关键词对象
         var kws_tips = 0;
         // 页面状态
         var pageState = {
             //是否第一次设置关键词
             isFirstSetKeyword: true
         }
+		//
+		function initSess(){
+			weui.loading();
+	        setTimeout(function(){
+	            weui.loading().hide();
+	            if(window.location.search.indexOf("page=2")>-1){
+					history.replaceState("{id:1}","","/front/vipsubscribe/toSetKeyWordPage")
+	            }else if(history.state){
+	                window.history.go(-1)
+				}
+	        },500)
+		}
+		//
         $(function(){
-            init();
+			var isinitpage = false;
+			$(window).bind("pageshow", function(event){
+				if(event.originalEvent.persisted){
+					initpage();
+					isinitpage = true;
+					initSess();
+					reloadFunc();
+				}
+			});
+			if(!isinitpage) {
+				initpage();
+				initSess();
+				reloadFunc();
+			}
+			window.addEventListener('popstate', function(event){
+				if(!isinitpage){
+					if(a_items.length==0){
+		                window.history.go(-1)
+		            }
+		            var loading = weui.loading('loading...', {
+		                className: 'custom-classname'
+		            })
+		            $('.classify-show-pop').hide();
+		            $('.classify-edit-pop').hide();
+		            //重新加载数据
+		            initpage();
+		            // 用定时器模拟请求耗时
+		            setTimeout(function () {
+		                loading.hide(function() {
+		                    console.log('`loading` has been hidden');
+		                })
+		                // 判断是否是第一次(没有关键词进入)
+		                // 隐藏关键词列表section,显示分类列表section
+		                var isClassifyColumnShow = $('.add-keyword-container').is(':hidden')
+		                if (!isClassifyColumnShow) {
+		                    $('.add-keyword-container').hide()
+		                    $('.all-classify-column').show()
+		                }
+		            }, 500)
+				}
+				isinitpage = false
+			})
             // 关键词分类 - 去设置按钮点击事件
             $('.classify-show-pop .dialog__btn_confirm').on('click', function() {
                 $('.classify-show-pop').hide();
@@ -275,7 +321,6 @@
                     $('.classify-edit-pop').show();
                 },200)
             })
-
             // 关键词分类 - 取消按钮点击事件
             $('.classify-show-pop .dialog__btn_cancel').on('click', function() {
 				$('.enterOne').focus();
@@ -283,7 +328,7 @@
             })
         })
         //获取数据
-        function init(){
+        function initpage(){
             if(sessionStorage&&sessionStorage.kwspage){
                 if(sessionStorage.addition_kws!=undefined){
                     addition_kws = JSON.parse(sessionStorage.addition_kws);
@@ -293,6 +338,7 @@
                 }
                 showKorshowC(sessionStorage.kwspage);
                 a_items = JSON.parse(sessionStorage.a_items)
+                kws_arr = JSON.parse(sessionStorage.kws_arr)
                 classify_name = sessionStorage.classify_name;
                 classify_index = sessionStorage.classify_index;
                 kws_name = sessionStorage.kws_name;
@@ -352,6 +398,7 @@
             kws_count = 0;
             var classifyHtml = '';
             classify_arr = [];//每次初始化分类对象
+			kws_arr = {};//每次初始化关键词对象
             for (var i = 0;  i < kwsdata.length; i++) {
                 var s_item = kwsdata[i]["s_item"]
                 if(s_item==""){
@@ -366,7 +413,7 @@
                         keystr += "、"
                     }
                     keystr += a_key[j]["key"].join('、');
-					kws_arr = kws_arr.concat(a_key[j]["key"])
+					kws_arr[a_key[j]["key"].join(' ')]=j+"-"+i
                 } 
                 classifyHtml +='<li class="classify-item">'
                             +'<div><span class="classify-item-l">'+s_item+'</span>'
@@ -501,7 +548,7 @@
         }
         //跳转附加词
         function toappendkey(th){
-			history.replaceState("","","/front/vipsubscribe/toSetKeyWordPage?page=1")
+			history.replaceState("","","/front/vipsubscribe/toSetKeyWordPage?page=211")
             if(!$('.enter.addkeyWord').is(':hidden')){
                 if($('.addkeyWord input.enterOne').val()==""){
                     return
@@ -519,7 +566,7 @@
         }
         //
         function tonotkey(th){
-			history.replaceState("","","/front/vipsubscribe/toSetKeyWordPage?page=1")
+			history.replaceState("","","/front/vipsubscribe/toSetKeyWordPage?page=211")
             if(!$('.enter.addkeyWord').is(':hidden')){
                 if($('.addkeyWord input.enterOne').val()==""){
                     return
@@ -545,6 +592,7 @@
             sessionStorage.a_items = JSON.stringify(a_items);//当前数据
             sessionStorage.addition_kws =  JSON.stringify(addition_kws);//当前编辑关键词附加词
             sessionStorage.not_kws =  JSON.stringify(not_kws);//当前编辑关键词排除词
+            sessionStorage.kws_arr =  JSON.stringify(kws_arr);//当前所有关键词排
 
             sessionStorage.kws_count=kws_count;//关键词个数
         }
@@ -562,12 +610,13 @@
             sessionStorage.removeItem("addition_kws");
             sessionStorage.removeItem("not_kws");
             sessionStorage.removeItem("kws_count");
+            sessionStorage.removeItem("kws_arr");
         }
         //保存关键词
         function saveK(th,i){
             var $this = $(th);
             kws_name = $(th).siblings('textarea').val();
-			if($.inArray(kws_name, kws_arr)>-1){
+			if(kws_arr[kws_name]!=undefined&&kws_arr[kws_name]!=(kws_index+"-"+classify_index)){
                 weui.toast('您设置的关键词已存在,请调整后再添加。', {
                     duration: 2000,
                     className: 'custom-toast',
@@ -661,7 +710,7 @@
             not_kws = [];
         }
     </script>
-    <script src="{{Msg "seo" "cdn"}}/vipsubscribe/js/keyWord.js?v={{Msg "seo" "version"}}1"></script>
+    <script src="{{Msg "seo" "cdn"}}/vipsubscribe/js/keyWord.js?v={{Msg "seo" "version"}}124"></script>
     <script>
         // 设置一条空记录,用户第一次进入添加关键词点击确定时候调用
         function setEmptyHistory() {
@@ -672,7 +721,6 @@
         }
         //
         $(function(){
-
             $(".addNewKeyword div").on('click', function () {
                 history.pushState({id:1}, "","");
                 classify_index = $(".classify-list li").length;
@@ -741,31 +789,6 @@
                 toSetKws();
             })
         })
-        window.addEventListener('popstate', function(event){
-            if(a_items.length==0){
-                window.history.go(-1)
-            }
-            var loading = weui.loading('loading...', {
-                className: 'custom-classname'
-            })
-            $('.classify-show-pop').hide();
-            $('.classify-edit-pop').hide();
-            //重新加载数据
-            init();
-            // 用定时器模拟请求耗时
-            setTimeout(function () {
-                loading.hide(function() {
-                    console.log('`loading` has been hidden');
-                })
-                // 判断是否是第一次(没有关键词进入)
-                // 隐藏关键词列表section,显示分类列表section
-                var isClassifyColumnShow = $('.add-keyword-container').is(':hidden')
-                if (!isClassifyColumnShow) {
-                    $('.add-keyword-container').hide()
-                    $('.all-classify-column').show()
-                }
-            }, 500)
-        })
     </script>
 	{{include "/common/baiducc.html"}}
 </body>

+ 1 - 1
src/web/templates/weixin/vipsubscribe/vip_pay_success.html

@@ -46,7 +46,7 @@
     $(function(){
       //查看订单
       $(".left_btn").on("click",function(){
-        window.location.href ='/front/vipsubscribe/toOrderDetailPage?orderCode='+orderCode
+        window.location.href ='/weixin/pay/toOrderDetailPage?orderCode='+orderCode
       })
       //设置关键词
       $(".right_btn").on("click",function(){