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

Merge remote-tracking branch 'origin/dev4.6.2.1' into dev4.6.2.1

wangkaiyue 3 жил өмнө
parent
commit
c5067c8286
45 өөрчлөгдсөн 801 нэмэгдсэн , 474 устгасан
  1. 2 9
      src/jfw/front/front.go
  2. 2 0
      src/jfw/front/login.go
  3. 1 0
      src/jfw/front/otherAct.go
  4. 1 0
      src/jfw/front/pchelper.go
  5. 2 9
      src/jfw/modules/app/src/app/front/front.go
  6. 7 1
      src/jfw/modules/app/src/app/front/login.go
  7. 1 1
      src/jfw/modules/app/src/app/front/wxkeyset.go
  8. 4 3
      src/jfw/modules/app/src/web/staticres/jyapp/big-member/css/analysis_result.css
  9. 58 33
      src/jfw/modules/app/src/web/staticres/jyapp/big-member/js/analysis_result.js
  10. 5 1
      src/jfw/modules/app/src/web/staticres/jyapp/big-member/js/set_area.js
  11. 6 1
      src/jfw/modules/app/src/web/staticres/jyapp/big-member/js/unit_portrayal.js
  12. 18 20
      src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/js/vip_index_new.js
  13. 190 150
      src/jfw/modules/app/src/web/templates/areaPack/page_set_area.html
  14. 5 5
      src/jfw/modules/app/src/web/templates/big-member/page_analysis_result.html
  15. 5 1
      src/jfw/modules/app/src/web/templates/commonPay/areaPack/orderDetail.html
  16. 5 5
      src/jfw/modules/app/src/web/templates/vipsubscribe/vip_index_new.html
  17. 4 3
      src/jfw/modules/bigmember/src/entity/analysis.go
  18. 6 5
      src/jfw/modules/bigmember/src/entity/analysisEntName.go
  19. 4 1
      src/jfw/modules/bigmember/src/service/analysis/forecastproject.go
  20. 5 4
      src/jfw/modules/common/src/qfw/util/jy/bigVipPower.go
  21. 17 6
      src/jfw/modules/publicapply/src/subscribe/entity/entity.go
  22. 70 22
      src/jfw/modules/publicapply/src/subscribePush/entity/setting.go
  23. 9 2
      src/jfw/modules/subscribepay/src/entity/areaPack.go
  24. 2 0
      src/jfw/modules/subscribepay/src/service/areaPack.go
  25. 2 0
      src/jfw/modules/subscribepay/src/service/dataExportPay.go
  26. 2 2
      src/jfw/modules/subscribepay/src/service/dataexportPack.go
  27. 2 0
      src/jfw/modules/subscribepay/src/service/integral.go
  28. 13 1
      src/jfw/modules/subscribepay/src/service/orderListDetails.go
  29. 5 3
      src/jfw/modules/subscribepay/src/service/userAccountInfo.go
  30. 2 0
      src/jfw/modules/subscribepay/src/service/vipSubscribeChange.go
  31. 4 0
      src/jfw/modules/subscribepay/src/service/vipSubscribePay.go
  32. 7 4
      src/jfw/modules/weixin/src/config.json
  33. 9 0
      src/jfw/modules/weixin/src/wx/wx.go
  34. 5 1
      src/web/staticres/big-member/js/set_area.js
  35. 8 2
      src/web/staticres/big-member/js/unit_portrayal.js
  36. 8 3
      src/web/staticres/common-module/big-member/js/high_set.js
  37. 13 1
      src/web/staticres/common-module/collection/js/history-project.js
  38. 49 2
      src/web/staticres/common-module/order-list/js/order-detail.js
  39. 28 15
      src/web/staticres/common-module/vipsubscribe/js/vip-subscribe-set-template.js
  40. 14 7
      src/web/staticres/vipsubscribe/js/vip_index_new.js
  41. 190 144
      src/web/templates/areaPack/wx/page_set_area.html
  42. 2 2
      src/web/templates/pc/biddetail_rec.html
  43. 4 0
      src/web/templates/weixin/commonPay/areaPack/orderDetail.html
  44. 1 1
      src/web/templates/weixin/commonPay/paySuccess.html
  45. 4 4
      src/web/templates/weixin/vipsubscribe/vip_index_new.html

+ 2 - 9
src/jfw/front/front.go

@@ -1033,7 +1033,7 @@ func (f *Front) TSGuide() error {
 		return f.Render("/weixin/wxtsguide.html")
 	} else {
 		reqType := f.GetString("reqType")
-		index, _ := f.GetInteger("index")
+		// index, _ := f.GetInteger("index")
 		result := make(bson.M)
 		if reqType == "save" {
 			var keyMaps []map[string]interface{}
@@ -1070,14 +1070,7 @@ func (f *Front) TSGuide() error {
 			}
 		} else if reqType == "over" {
 			saveData := bson.M{
-				"o_jy.o_area":       map[string]interface{}{},
-				"o_jy.l_modifydate": time.Now().Unix(),
-				"i_ts_guide":        1,
-			}
-			if index > 2 {
-				saveData = bson.M{
-					"i_ts_guide": 1,
-				}
+				"i_ts_guide": 1,
 			}
 			result["flag"] = mongodb.UpdateById("user", userid, bson.M{"$set": saveData})
 		} else if reqType == "preview" {

+ 2 - 0
src/jfw/front/login.go

@@ -115,10 +115,12 @@ func (l *Login) Login() error {
 						"s_company":     s_company,
 						"o_jy": map[string]interface{}{
 							"i_apppush":    1,
+							"i_newfree":    1, //新免费用户=>新订阅设置页面 20211122
 							"i_ratemode":   2,
 							"l_modifydate": time.Now().Unix(),
 						},
 						"s_regsource": "pc",
+						"s_platform":  "pc",
 					}
 					source := l.GetString("source") //用户手机号用户记录百度统计
 					if ck, err := l.GetCookie("source"); err == nil && ck.Value != "" {

+ 1 - 0
src/jfw/front/otherAct.go

@@ -135,6 +135,7 @@ func (f *Front) Lpsubmit() error {
 				"i_ts_guide":    2,
 				"o_jy": map[string]interface{}{
 					"i_apppush":    1,
+					"i_newfree":    1, //新免费用户=>新订阅设置页面 20211122
 					"i_ratemode":   2,
 					"l_modifydate": time.Now().Unix(),
 				},

+ 1 - 0
src/jfw/front/pchelper.go

@@ -128,6 +128,7 @@ func (l *PcHelper) Login() error {
 							"o_jy": map[string]interface{}{
 								"i_apppush":    1,
 								"i_ratemode":   2,
+								"i_newfree":    1, //新免费用户=>新订阅设置页面 20211122
 								"l_modifydate": time.Now().Unix(),
 							},
 							"s_regsource": "pchelper",

+ 2 - 9
src/jfw/modules/app/src/app/front/front.go

@@ -291,7 +291,7 @@ func (f *Front) TSGuide() error {
 		return f.Render("/weixin/wxtsguide.html")
 	} else {
 		reqType := f.GetString("reqType")
-		index, _ := f.GetInteger("index")
+		// index, _ := f.GetInteger("index")
 		result := make(bson.M)
 		if reqType == "save" {
 			var keyMaps []map[string]interface{}
@@ -328,14 +328,7 @@ func (f *Front) TSGuide() error {
 			}
 		} else if reqType == "over" {
 			saveData := bson.M{
-				"o_jy.o_area":       map[string]interface{}{},
-				"o_jy.l_modifydate": time.Now().Unix(),
-				"i_ts_guide":        1,
-			}
-			if index > 2 {
-				saveData = bson.M{
-					"i_ts_guide": 1,
-				}
+				"i_ts_guide": 1,
 			}
 			result["flag"] = mongodb.UpdateById("user", userid, bson.M{"$set": saveData})
 		} else if reqType == "preview" {

+ 7 - 1
src/jfw/modules/app/src/app/front/login.go

@@ -206,8 +206,10 @@ func (l *Login) Login() error {
 						"o_jy": map[string]interface{}{
 							"i_apppush":    1,
 							"i_ratemode":   2,
+							"i_newfree":    1, //新免费用户=>新订阅设置页面 20211122
 							"l_modifydate": time.Now().Unix(),
 						},
+						"s_platform": "app",
 					}
 					data["s_regsource"] = isAndroidOrIOS(l.Header("User-Agent"))
 					_id := mongodb.Save("user", data)
@@ -462,9 +464,11 @@ func (l *Login) Register() error {
 					data["o_jy"] = map[string]interface{}{
 						"i_apppush":    1,
 						"i_ratemode":   2,
+						"i_newfree":    1, //新免费用户=>新订阅设置页面 20211122
 						"l_modifydate": time.Now().Unix(),
 					}
 					data["s_regsource"] = isAndroidOrIOS(l.Header("User-Agent"))
+					data["s_platform"] = "app"
 					saveid = mongodb.Save("user", data)
 					saveSuccess = saveid != ""
 				}
@@ -605,10 +609,12 @@ func (l *Login) WxLogin() {
 				"o_jy": map[string]interface{}{
 					"i_apppush":    1,
 					"i_ratemode":   2,
+					"i_newfree":    1, //新免费用户=>新订阅设置页面 20211122
 					"l_modifydate": time.Now().Unix(),
 				},
+				"s_platform": "app", //用户注册平台 app 微信 pc
 			}
-			newUser["s_regsource"] = isAndroidOrIOS(l.Header("User-Agent"))
+			newUser["s_regsource"] = isAndroidOrIOS(l.Header("User-Agent")) //用户注册终端 ios 安卓 pc
 			if _id := mongodb.Save("user", newUser); _id != "" {
 				returnSign = afterLogin(newUser, l.Session(), rid, oid, phoneType, channel, deviceId, 2, true, l.ResponseWriter)
 				if disWord != "" {

+ 1 - 1
src/jfw/modules/app/src/app/front/wxkeyset.go

@@ -27,7 +27,7 @@ func (m *Front) WxKeyset(tpl string) error {
 	//到新订阅设置
 	vipMsg := jy.GetBigVipUserBaseMsg(userid, public.Mysql, public.MQFW)
 	if vipMsg.IsUpgrade {
-		return m.Redirect("/front/vipsubscribe/toSubVipSetPage")
+		return m.Redirect("/jyapp/vipsubscribe/toSubVipSetPage")
 	}
 	if tpl == "seniorset" {
 		data, ok := mongodb.FindById("user", userid, `{"o_jy":1}`)

+ 4 - 3
src/jfw/modules/app/src/web/staticres/jyapp/big-member/css/analysis_result.css

@@ -357,15 +357,16 @@
 #analysis-result .company-info{
     display: flex;
     align-items: center;
-    padding: 5px 8px 8px;
+    justify-content: space-between;
+    padding: 5px 6px 8px;
     color: #5F5E64;
     font-size: .2rem;
     line-height: .36rem;
 }
 #analysis-result .company-info span{
-    flex: 1;
+    /* flex: 1; */
     white-space: nowrap;
-    margin-right: .24rem;
+    /* margin-right: .14rem; */
 }
 #analysis-result .same-history,.other-history{
     margin-top: .16rem;

+ 58 - 33
src/jfw/modules/app/src/web/staticres/jyapp/big-member/js/analysis_result.js

@@ -1,5 +1,3 @@
-var hotChart = null;
-var pieChart = null;
 var vNode = {
     delimiters: ['${', '}'],
     el: '#analysis-result',
@@ -103,7 +101,9 @@ var vNode = {
             winnerVal: '',
             buyerVal: '',
             scrollTop: 0,
-            defaultProjectDetail: []
+            defaultProjectDetail: [],
+            hotChartRef: null,
+            pieChartRef: null
         }
     },
     computed: {
@@ -117,6 +117,34 @@ var vNode = {
             return 320 - 22*this.minusRows  + 'px'
         }
     },
+    watch: {
+      active: function(newVal) {
+        // 监听切换到类似项目明细 页面滚动到筛选条件位置
+        if (newVal == 1) {
+          this.$nextTick(function() {
+            if (this.$refs.detailFilter) {
+              this.$refs.detailFilter.scrollIntoView()
+            }
+          })
+        }
+      },
+      // 监听热力图
+      hotChartRef: function (newVal) {
+        // console.log(newVal, chartOptions.hotChart, '热力图')
+        if (newVal) {
+          newVal.setOption(chartOptions.hotChart);
+          newVal.resize()
+        }
+      },
+      // 监听饼图
+      pieChartRef: function (newVal) {
+        // console.log(newVal, chartOptions.deformPieChart, '饼图')
+        if (newVal) {
+          newVal.setOption(chartOptions.deformPieChart);
+          newVal.resize()
+        }
+      }
+    },
     created () {
         try {
             this.mobileModel = JyObj.getPhoneBrand();
@@ -144,7 +172,6 @@ var vNode = {
             this.currentVal.buyerClass = prevState.currentVal.buyerClass;
         }
         this.isFollowProject();
-        this.init();
         var restore = this.restoreData()
         if (!restore) {
             this.getChartData();
@@ -153,18 +180,19 @@ var vNode = {
     },
     beforeDestroy() {
         window.removeEventListener("resize", this.init,20);
-        if(hotChart) {
-            hotChart.dispose();
-        }
-        if(pieChart) {
-            pieChart.dispose();
-        }
+        // if(hotChart) {
+        //     hotChart.dispose();
+        // }
+        // if(pieChart) {
+        //     pieChart.dispose();
+        // }
     },
     mounted() {
         this.year = new Date().getFullYear() - 2;
         // 动态调整sticky距离顶部的高度
         this.getStickyTop()
         window.addEventListener('scroll', this.handleScroll, true);
+        this.init();
     },
     methods: {
         showLoading: function () {
@@ -190,13 +218,11 @@ var vNode = {
         // resize 屏幕尺寸
         init: function(){
             var that = this
-            setTimeout(function() {
-                window.addEventListener('resize', function() {
-                    hotChart.resize();
-                    pieChart.resize();
-                    that.screenWidth = document.body.clientWidth
-                })
-            }, 20)
+            window.addEventListener('resize', function() {
+              that.hotChartRef.resize();
+              that.pieChartRef.resize();
+              that.screenWidth = document.body.clientWidth || window.screen.width
+          })
         },
         // 跳企业画像
         goEntImg:function(name) {
@@ -253,7 +279,6 @@ var vNode = {
         },
         getStickyTop: function () {
             this.stickyTop = $('.jy-app-header').height() - 1;
-            console.log(this.stickyTop)
         },
         // 取消关注
         cancelFollow:function(){
@@ -690,30 +715,30 @@ var vNode = {
             var index;
             that.$nextTick(function(){
                 var ref = that.$refs.hotChart;
-                hotChart = echarts.init(ref,null,{renderer: "svg"});
-                hotChart.setOption(chartOptions.hotChart);
+                that.hotChartRef = echarts.init(ref,null,{renderer: "svg"});
+                that.hotChartRef.setOption(chartOptions.hotChart);
                 setTimeout(function(){
                     // 默认展示某一个
-                    hotChart.dispatchAction({
+                    that.hotChartRef.dispatchAction({
                         type: 'highlight',
                         seriesIndex: 0,  // 显示第几个series
                         dataIndex: that.getMaxProjectCount(data) // 最大值所在数组的索引
                     });
                 },20)
-                hotChart.on("mouseover", function(e) {
+                that.hotChartRef.on("mouseover", function(e) {
                     index = that.getMaxProjectCount(data)
                     if (e.dataIndex != index) {
-                        hotChart.dispatchAction({
+                      that.hotChartRef.dispatchAction({
                             type: "downplay",
                             seriesIndex: 0,
                             dataIndex: index
                         });
                     }
                 });
-                hotChart.on("mouseout", function(e) {
+                that.hotChartRef.on("mouseout", function(e) {
                     index = that.getMaxProjectCount(data)
                     if (e.dataIndex != index) {
-                        hotChart.dispatchAction({
+                      that.hotChartRef.dispatchAction({
                             type: "highlight",
                             seriesIndex: 0,
                             dataIndex: that.getMaxProjectCount(data)
@@ -762,7 +787,7 @@ var vNode = {
             }
             var maxNum = Math.max.apply(null,arr);
             var curIndex = this.getArrayIndex(arr,maxNum,'count')
-            console.log('最大值:'+ maxNum + ',索引:' + curIndex)
+            // console.log('最大值:'+ maxNum + ',索引:' + curIndex)
             setTimeout(function(){
                 $event.dispatchAction({
                     type: 'showTip',
@@ -828,12 +853,12 @@ var vNode = {
             var curIndex = that.getArrayIndex(data,true,'pie'); // 当前项目采购类型在饼图数组中的坐标
             that.$nextTick(function(){
                 var ref = that.$refs.pieChart;
-                pieChart = echarts.init(ref);
-                pieChart.setOption(chartOptions.deformPieChart);
-                pieChart.resize();
+                that.pieChartRef = echarts.init(ref);
+                that.pieChartRef.setOption(chartOptions.deformPieChart);
+                that.pieChartRef.resize();
                 if(curIndex) {
                     setTimeout(function(){
-                        pieChart.dispatchAction({
+                        that.pieChartRef.dispatchAction({
                             type: 'showTip',
                             seriesIndex:0,
                             dataIndex: curIndex
@@ -979,9 +1004,9 @@ var vNode = {
           this.buyerVal = buyer ? buyer : ''
           this.scrollTop = this.$refs.wrapper.scrollTop
           if (buyer) {
-            this.getProjectDetail(2, winner, buyer)
+            this.getProjectDetail(0, winner, buyer)
           } else {
-            this.getProjectDetail(1, winner)
+            this.getProjectDetail(0, winner)
           }
         },
         onTabClick (page) {
@@ -1029,7 +1054,7 @@ var vNode = {
             appVersion: this.appVersion,
             // 以下为新增
             winner: winner,
-            searchType: 3
+            searchType: 1
           }
           if (winner || buyer) {
             sessionStorage.setItem('analysis_other_project', JSON.stringify(data))

+ 5 - 1
src/jfw/modules/app/src/web/staticres/jyapp/big-member/js/set_area.js

@@ -188,8 +188,9 @@ var vNode = {
         // 根据城市的选择情况判断省份的选择情况
         changeCityState(province, city) {
             if (city === '#') {
+                this.setCitySelected()
                 this.onChange()
-                return this.setCitySelected()
+                return
             }
             // 全国置为空
             this.provinceListMap['#'][0].selectedState = ''
@@ -437,6 +438,7 @@ var vNode = {
             try {
                 onChange && onChange(selectedCity)
             } catch (error) {
+                console.warn(error)
                 console.warn(arguments.callee.name + '必须定义为函数')
             }
         },
@@ -445,6 +447,7 @@ var vNode = {
             try {
                 onReset && onReset(this.initCityMap)
             } catch (error) {
+                console.log(error)
                 console.error(arguments.callee.name + '必须定义为函数')
             }
         },
@@ -453,6 +456,7 @@ var vNode = {
             try {
                 onConfirm && onConfirm(selectedCity)
             } catch (error) {
+                console.log(error)
                 console.error(arguments.callee.name + '必须定义为函数')
             }
         }

+ 6 - 1
src/jfw/modules/app/src/web/staticres/jyapp/big-member/js/unit_portrayal.js

@@ -399,7 +399,12 @@ var vNode = {
                       that.chartLoading = false;
                       that.initChartData('', res.data)
                   } else {
-                    that.getSectionChartData('a')
+                    // that.getSectionChartData('a')
+                    if (that.reqCount < 5) {
+                      that.getChartData()
+                    } else {
+                      that.chartLoading = false;
+                    }
                   }
                 }
             },

+ 18 - 20
src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/js/vip_index_new.js

@@ -33,19 +33,21 @@ var subNode = new Vue({
       }
       this.switchShow()
       this.switehAjax()
-      this.getUserSubscribe()
     },
-    mounted () { 
+    mounted () {
+        this.$nextTick(function () {
+            $(".app-layout-content-b").removeAttr('v-cloak')
+        })
         // this.userAreaNum = 0
         // this.userType = true
         // this.userAreaAllNum = 1
     },
     methods: {
-        // 省份订阅包续费 
+        // 省份订阅包续费
         renewBtn: function () {
             location.href = '/jyapp/areaPack/page/buy?type=renew'
         },
-        // 省份订阅包升级 
+        // 省份订阅包升级
         updateBtn: function () {
             location.href = '/jyapp/areaPack/page/buy?type=upgrade&area=' +  encodeURIComponent(JSON.stringify(this.freeUserArea))
         },
@@ -144,7 +146,10 @@ var subNode = new Vue({
                     console.log(res)
                     if(res.data) {
                         _this.vSwitch = res.data.vt || 'f'
+                        // f 免费 m 大会员 v 超级订阅
                         if (_this.vSwitch === 'f') {
+                            // 判断是否购买省份订阅包
+                            _this.getUserSubscribe()
                             $('.update_renew').hide()
                         }
                         if(res.data.vt == 'm') {
@@ -334,7 +339,7 @@ $(function () {
               } else if (switchProduct == 'free') {
                 subNode.initData = r.data
               } else {
-                res = resObj
+                res = r
               }
           }
           if(!res.data.industry) {
@@ -357,19 +362,12 @@ $(function () {
   }
   var resObj = {}
   // 每次请求接口
-  console.log(document.referrer)
-  let subUrl
-  if (subNode.vSwitch === 'v') {
-    subUrl = '/subscribepay/vipsubscribe/getSubBuyMsg'
-  } else if (subNode.vSwitch === 'm') {
-    subUrl = '/bigmember/use/info?t=' + new Date().getTime()
-  } else {
-    subUrl = '/publicapply/free/subscribe'
-  }
+    let subUrl = '/subscribepay/vipsubscribe/getSubBuyMsg'
     $DoPost(subUrl, {}, function(sum) {
-        console.info('sum',sum)
-        resObj = sum
-        getDataWitXHR()
+        if(sum.success) {
+            resObj = sum
+            getDataWitXHR()
+        }
     })
 
   // 设置已选择的区域和行业
@@ -640,12 +638,12 @@ $(function () {
       checkmerge(state.industry, state.isread)
       // init 已选择的区域和行业
       // var selectedAreaAndInd = getBuySet(state.area, state.industry);
-      // 2021-5-21修改 初始化已选择的区域和行业 
+      // 2021-5-21修改 初始化已选择的区域和行业
       var selectedAreaAndInd = getSelectBuyset(state.area, state.industry)
       setSelectedAreaAndInd(selectedAreaAndInd);
       // 初始化,已购买的城市和行业
-        // setBuyAreaAndInd(state.buyset);
-      
+      setBuyAreaAndInd(state.buyset);
+
       //是否提示即将到期
       showTimeOut(state.endTime, state.isTrial);
       selectTime = sessionStorage.getItem("vip_change_time");

+ 190 - 150
src/jfw/modules/app/src/web/templates/areaPack/page_set_area.html

@@ -36,7 +36,6 @@
             font-weight: 500;
             color: #FA483C;
             box-sizing: border-box;
-            display: none;
         }
         .selectChange {
             font-size: 0.24rem;
@@ -119,191 +118,232 @@
     <div id="set-header-template" v-cloak>
         <div class="wrapper-header" id="thisAreaTips">
             <div class="content">
-                <div class="selectNumMax">可选择<span class="numColor" id="canSelect">1个省</span></div>
+                <div class="selectNumMax">可选择<span class="numColor" id="canSelect">${ maxSelectText }</span></div>
                 <div class="string"></div>
                 <div class="selectNumList">
-                    <span>已选择<span class="numColor" id="thisSelect">1个省</span></span>
-                    <span class="moreTips">超出可订阅省份数量,前往购买省份订阅包 ></span>
+                    <span>已选择<span class="numColor" id="thisSelect">${ selectedAreaText }</span></span>
+                    <span class="moreTips" v-show="moreThanSubCount">超出可订阅省份数量,前往${ buyType }省份订阅包 &gt;</span>
                 </div>
                 <div class="selectChange"></div>
             </div>
-            <div class="popup-wrap" v-show="popupType">
+            <div class="popup-wrap" v-show="popupTip">
                 <div class="popup-content">
-                    <div class="popup-text" id="tips-text">您当前仅可订阅1个省,如需增加请购买【省份订阅包】</div>
+                    <div class="popup-text" id="tips-text">您当前仅可订阅${ maxSelectText },如需增加请${ buyType }【省份订阅包】</div>
                     <div class="popup-btnWrap">
-                        <div class="popup-btn" id="cancel" @click="hiddenTips">取消</div>
+                        <div class="popup-btn" id="cancel" @click="hideTips">取消</div>
                         <div class="popup-line"></div>
-                        <div class="popup-btn levelUp" id="btn-text" @click="toPay">去购买</div>
+                        <div class="popup-btn levelUp" id="btn-text" @click="toPay">去${ buyType }</div>
                     </div>
                 </div>
             </div>
         </div>
     </div>
     <script>
-        var setAreaFn = {
-            conf: {
-                sKey: 'sub_free_state'
-            },
-            buyPageInfo: {},
-            init: function () {
-                // 恢复页面状态
-                var pageInfo = sessionStorage.getItem(this.conf.sKey)
-                if (pageInfo) {
-                    this.buyPageInfo = JSON.parse(pageInfo)
-                    var areaInfo = this.buyPageInfo.area
-                    if (this.buyPageInfo && areaInfo && Object.keys(areaInfo).length !== 0) {
-                        vNode.data.initCityMap = areaInfo
-                        vueComponent.setCitySelected(areaInfo)
-                    }
-                }
-            },
-            saveToSessionStorage: function (data) {
-                sessionStorage.setItem(this.conf.sKey, JSON.stringify(data))
-            }
-        }
-        setAreaFn.init()
         var vm = new Vue({
             delimiters: ['${', '}'],
             el: '#set-header',
             template: '#set-header-template',
             data: {
-                popupType: false,
-                popupText: '您当前仅可订阅1个省,如需增加请购买【省份订阅包】',
-                popupPayBtn: '去购买'
+                sessKey: 'sub_free_set_area',
+                selectedArea: '',
+                userSubInfo: {
+                    area: '',
+                    areanum: 0, // 可修改次数
+                    basenum: 1,
+                    provincenum: 0, // 购买的省份数量
+                },
+                popupTip: false
             },
-            created: function () {},
-            methods: {
-                hiddenTips: function () {
-                    this.popupType = false
+            computed: {
+                moreThanSubCount: function () {
+                    var max = this.maxSelectCount
+                    var sel = this.selectedAreaCount
+                    if (max === -1) return false
+                    if (sel === -1) return true
+                    if (sel > max) return true
                 },
-                toPay: function () {
-                    this.popupType = false
-                    if (userType) {
-                        // /jyapp/areaPack/page/buy?type=buy&area= + encodeURIComponent(JSON.stringify())
-                        location.href = '/jyapp/areaPack/page/buy?type=renew&area=' +  encodeURIComponent(JSON.stringify(thisData))
+                maxSelectCount: function () {
+                    var baseNum = this.userSubInfo.basenum || 1
+                    var provincenum = this.userSubInfo.provincenum
+                    if (provincenum === -1) {
+                        return provincenum
                     } else {
-                        location.href = '/jyapp/areaPack/page/buy?type=buy&area=' +  encodeURIComponent(JSON.stringify(thisData))
+                        return provincenum + baseNum
                     }
                 },
-                
-            }
-        })
-        var maxSelect = 1
-        var thisSelectNum = 0
-        var userType = true // 用户是否购买过省份包
-        var vSwitch = 'f' // 用户版本,''免费版,m大会员,v超级订阅
-        // 获取用户权限
-        function getUserMsg() {
-            $.ajax({
-                url: '/bigmember/use/isAdd',
-                type: 'POST',
-                success: function (res) {
-                    if (res.data.memberStatus > 0 && res.data.vipStatus <= 0) {
-                        vSwitch = 'm'
-                        $('#thisAreaTips').hide()
-                    } else if (res.data.memberStatus <= 0 && res.data.vipStatus > 0) {
-                        vSwitch = 'v'
-                        $('#thisAreaTips').hide()
-                    } else if (res.data.memberStatus <= 0 && res.data.vipStatus <= 0) {
-                        vSwitch = 'f'
-                        $('#thisAreaTips').show()
+                maxSelectText: function () {
+                    if (this.maxSelectCount === -1) {
+                        return '全国'
+                    } else {
+                        return this.maxSelectCount + '个省'
                     }
-                }
-            })
-        }
-        getUserMsg()
-        // 获取用户购买省份包信息
-        function getUserSubscribe() {
-            $.ajax({
-                url: '/publicapply/free/subscribe',
-                type: 'POST',
-                success: function (res) {
-                    let freeArea = JSON.stringify(res.data)
-                    sessionStorage.setItem('sub_free_state', freeArea)
-                    setAreaFn.init()
-                    onChange(res.data.area)
-                    userType = res.data.provincenum === 0 ? false : true
-                    maxSelect = res.data.provincenum + res.data.basenum
-                    // _this.$emit('UserSubscribe',res)
-                    if (maxSelect === -1) {
-                        $('#canSelect').text(`全国`)
-                    } else if (res.data.provincenum === 0 && res.data.areanum === 1) {
-                        vueComponent.provinceListMap['#'][0].selectedState = ''
+                },
+                selectedAreaCount: function () {
+                    var area = this.selectedArea
+                    if (area) {
+                        var keys = Object.keys(area)
+                        if (keys.length === 0) {
+                            return -1
+                        } else {
+                            return keys.length
+                        }
                     } else {
-                        $('#canSelect').text(`${maxSelect}个省`)
+                        return 0
                     }
-                }
-            })
-        }
-        getUserSubscribe()
-        function userUpdate(obj) {
-            let _this = this
-            $.ajax({
-                url: '/publicapply/subscribe/update',
-                type: 'POST',
-                data: {
-                    vSwitch: vSwitch,
-                    area:obj
                 },
-                success: function (res) {
-                    console.info(res)  
-                    window.history.back()           
+                selectedAreaText: function () {
+                    if (this.selectedAreaCount === -1) {
+                        return '全国'
+                    } else {
+                        return this.selectedAreaCount + '个省'
+                    }
+                },
+                // 是否购买了省份订阅包
+                userType: function () {
+                    if (this.userSubInfo.provincenum === -1) return true
+                    return this.userSubInfo.provincenum !== 0
+                },
+                buyType: function () {
+                    return this.userType ? '升级' : '购买'
+                },
+            },
+            mounted: function () {
+                var type = utils.getParam('type')
+                var restore = this.restoreState()
+
+                if (restore) {
+                    this.initPageInfo()
+                } else {
+                    if (type === 'new') {
+                        this.setAreaAllNotSelected()
+                    } else {
+                        this.getUserSubscribe()
+                    } 
                 }
-            })
-        }
-        $('#thisSelect').text(`${thisSelectNum}个省`)
-        $('#canSelect').text(`${maxSelect}个省`)
-        // 以下均为示例:具体使用时候请删除
-        // 定义重置方法:方法名必须为onReset/onConfirm
-        // 参数,是被初始化的数据
+            },
+            methods: {
+                initPageInfo: function () {
+                    var area = this.selectedArea
+                    this.setComponentState(area)
+                },
+                setAreaSelected: function (area) {
+                    this.$set(this, 'selectedArea', area)
+                },
+                setComponentState: function (area) {
+                    vNode.data.initCityMap = area
+                    vueComponent.setCitySelected(area)
+                },
+                setAreaAllNotSelected: function () {
+                    vueComponent.setCitySelected()
+                    vueComponent.provinceListMap['#'][0].selectedState = ''
+                    $('#set-area .j-button-confirm').prop('disabled', true)
+                },
+                // 获取用户订阅信息
+                getUserSubscribe: function () {
+                    var _this = this
+                    $.ajax({
+                        url: '/publicapply/free/subscribe',
+                        type: 'POST',
+                        success: function (res) {
+                            if (res && res.error_code === 0) {
+                                if (res.data) {
+                                    if (res.data.area === null || res.data.area === undefined) {
+                                        _this.setAreaAllNotSelected()
+                                    } else {
+                                        if (res.data.area) {
+                                            // 赋值默认已选
+                                            _this.setAreaSelected(res.data.area)
+                                        }
+                                        for (var key in res.data) {
+                                            _this.$set(_this.userSubInfo, key, res.data[key])
+                                        }
+                                        _this.initPageInfo()
+                                    }
+                                }
+                            } else {
+                                if (res.error_msg) {
+                                    _this.$toast(res.error_msg)
+                                }
+                            }
+                        }
+                    })
+                },
+                userUpdate: function (area) {
+                    var _this = this
+                    $.ajax({
+                        url: '/publicapply/subscribe/update',
+                        type: 'POST',
+                        data: {
+                            vSwitch: 'f',
+                            area: JSON.stringify(area)
+                        },
+                        success: function (res) {
+                            if (res && res.success) {
+                                history.back()           
+                            } else {
+                                if (res.errMsg) {
+                                    _this.$toast(res.errMsg)
+                                }
+                            }
+                        }
+                    })
+                },
+                confirmed: function (area) {
+                    this.setAreaSelected(area)
+                    if (this.moreThanSubCount) {
+                        this.popupTip = true
+                    } else {
+                        this.userUpdate(area)
+                    }
+                },
+                hideTips: function () {
+                    this.popupTip = false
+                },
+                toPay: function () {
+                    this.popupTip = false
+                    var area = this.selectedArea
+                    var urlBase = '/jyapp/areaPack/page/buy'
+                    var areaJSON = encodeURIComponent(JSON.stringify(area))
+                    this.savePageState()
+                    if (this.userType) {
+                        location.href = urlBase + '?type=upgrade&area=' +  areaJSON
+                    } else {
+                        location.href = urlBase +  '?type=buy&area=' +  areaJSON
+                    }
+                },
+                restoreState: function () {
+                    var $data = sessionStorage.getItem(this.sessKey)
+                    if ($data) {
+                        $data = JSON.parse($data)
+
+                        this.selectedArea = $data.selectedArea
+                        Object.assign(this.userSubInfo, $data.userSubInfo)
+
+                        sessionStorage.removeItem(this.sessKey)
+                    }
+                    return !!$data
+                },
+                savePageState: function () {
+                    var data = {
+                        selectedArea: this.selectedArea,
+                        userSubInfo: this.userSubInfo
+                    }
+                    sessionStorage.setItem(this.sessKey, JSON.stringify(data))
+                },
+            }
+        })
+
         function onReset (initData) {
-            $('.selectChange').text('')
-            $('#thisSelect').text(`${thisSelectNum}个省`)
-            $('.moreTips').hide()
+            vm.setAreaSelected(initData)
         }
         // 被选中的数据
         function onConfirm (selectedData) {
-            var selectDataList = []
-            for (const key in selectedData) {
-                selectDataList.push(key)
-            }
-            if (selectDataList.length > maxSelect && maxSelect !== -1 && vSwitch === 'f') {
-                vm.popupType = true
-                if (!userType) {
-                    $('#tips-text').text('您当前仅可订阅1个省,如需增加请购买【省份订阅包】')
-                    $('#btn-text').text('去购买')
-                } else {
-                    $('#tips-text').text('已超出您可订阅的省份数量,是否升级【省份订阅包】')
-                    $('#btn-text').text('去升级')
-                }
-            } else {
-                var areaData = {}
-                selectDataList.forEach(function (item, index) {
-                    areaData[item] = []
-                })
-                areaData = JSON.stringify(areaData)
-                userUpdate(areaData)
-                sessionStorage.setItem('sub_vip_state', areaData)
-                
-            }
+            vm.confirmed(selectedData)
         }
-        var thisData = []
         // 页面选中状态改变时触发
         function onChange (selectedData) {
-            thisData = selectedData
-            var selectDataList = []
-            for (const key in selectedData) {
-                selectDataList.push(key)
-            }
-            var arr = selectDataList.join('、')
-            $('.selectChange').text(`${arr}`)
-            thisSelectNum = selectDataList.length
-            $('#thisSelect').text(`${selectDataList.length}个省`)
-            if (thisSelectNum > maxSelect) {
-                $('.moreTips').show()
-            } else {
-                $('.moreTips').hide()
-            }
+            vm.setAreaSelected(selectedData)
+            $('#set-area .j-button-confirm').prop('disabled', false)
         }
     </script>
 </body>

+ 5 - 5
src/jfw/modules/app/src/web/templates/big-member/page_analysis_result.html

@@ -133,17 +133,17 @@
                                                 <span v-else class="index">${i + 1}</span>
                                                 <span class="title" @click="goEntImg(hs.entId)">${hs.key}</span>
                                             </div>
-                                            <div class="win-capital">注册资本${formatterMoney(hs.capital)}</div>
+                                            <div class="win-capital">注册资本:${formatterMoney(hs.capital)}</div>
                                             <div class="win-info" @click="goDetail(hs.key)">
                                               <div class="w-title">
                                                 <span class="w-title-label">类似项目明细</span>
                                                 <van-icon class="win-arrow" name="arrow"></van-icon>
                                               </div>
                                               <div class="company-info">
-                                                <span>项目数量${hs.doc_count}个</span>
-                                                <span>项目金额${formatterMoney(hs.total_project)}</span>
+                                                <span>项目数量:${hs.doc_count}个</span>
+                                                <span>项目金额:${formatterMoney(hs.total_project)}</span>
                                                 <!-- <span>注册资本:${formatterMoney(hs.capital)}</span> -->
-                                                <span class="ellipsis">最近中标:${formatterTime(hs.max_jytime)}</span>
+                                                <span>最近中标:${formatterTime(hs.max_jytime)}</span>
                                               </div>
                                             </div>
                                             
@@ -232,7 +232,7 @@
                             </div>
                         </van-tab>
                         <van-tab title="类似项目明细">
-                            <div class="detail-filter">
+                            <div class="detail-filter" ref="detailFilter">
                               <van-collapse v-model="activeNames">
                                 <van-collapse-item title="筛选条件" name="1">
                                   <van-field class="filter-input" v-model="winnerVal" label="中标企业" placeholder="输入中标企业名称" maxlength="50"></van-field>

+ 5 - 1
src/jfw/modules/app/src/web/templates/commonPay/areaPack/orderDetail.html

@@ -89,6 +89,10 @@
                         class="j-button-confirm buy-again"
                         v-if="orderStateMap[orderInfo.state].bottomButtonShow.buyAgain"
                         @click="buyAgain">再次购买</button>
+                    <button
+                            class="j-button-confirm renew"
+                            v-if="orderStateMap[orderInfo.state].bottomButtonShow.renew"
+                            @click="renew">续费</button>
                 </div>
             </div>
         </div>
@@ -110,4 +114,4 @@
     {{include "/common/baiducc.html"}}
 </body>
 
-</html>
+</html>

+ 5 - 5
src/jfw/modules/app/src/web/templates/vipsubscribe/vip_index_new.html

@@ -247,13 +247,13 @@
     <!-- <a href="/jyapp/vipsubscribe/vipsubscribe_renew" class="custom-header-right go_renew" style="display: none;">续费</a> -->
     <!-- <a href="/jyapp/vipsubscribe/vipsubscribe_new" class="custom-header-right go_buy" style="display: none;">去购买</a> -->
   </div>
-  <div class="app-layout-content-b">
+  <div class="app-layout-content-b"  v-cloak>
     {{if not .T.isLiveActive}}
     <div class="vip-upgrade">
       {{else}}
       <div class="vip-upgrade live-20200707">
         {{end}}
-        <ul class="vip-body" id="vip-body">
+        <ul class="vip-body" id="vip-body" v-cloak>
           <li class="sub-box">
             <a data-href="/jyapp/vipsubscribe/introducePage?type=renew" class="banner-ad-box update"
               style="display: none">
@@ -267,7 +267,7 @@
               </div>
             </a>
             <ul class="sub-info" :class="vSwitch !== 'm' && vSwitch !== 'v' ? 'go_to_levelup' : ''" @click="toPaySupSub" style="min-height: 1.48rem">
-              <li class="cycle" v-show="vSwitch !== 'f'">
+              <li class="cycle" v-show="vSwitch == 'm' || vSwitch == 'v'">
                 <a class="item-container" :href="vipLink">
                   <div class="item">
                     <span class="item-l">
@@ -332,7 +332,7 @@
           </li>
         </ul>
         <!-- 升级 -->
-        <div class="update_renew">
+        <div class="update_renew" style="display: none">
           <div class="update-tips" data-update-tips>因系统升级,已购买用户可选择原套餐续费,或升级到新版本享受更多权益。</div>
           <div class="footer-button-group j-button-group">
             <button class="j-button-confirm" data-bind-renew>续费</button>
@@ -391,7 +391,7 @@
       sessionStorage.removeItem('vip-cur-select-size')
     </script>
     <script src='{{Cdns .Host "seo" "cdn"|SafeUrl}}/jyapp/vipsubscribe/js/UpgradePrice.js?v={{Msg "seo" "version"}}'></script>
-    <script src='{{Cdns .Host "seo" "cdn"|SafeUrl}}/jyapp/vipsubscribe/js/vip_index_new.js?v={{Msg "seo" "version"}}'></script>
+    <script src='{{Cdns .Host "seo" "cdn"|SafeUrl}}/jyapp/vipsubscribe/js/vip_index_new.js?v=11{{Msg "seo" "version"}}'></script>
 </body>
 {{include "/common/baiducc.html"}}
 

+ 4 - 3
src/jfw/modules/bigmember/src/entity/analysis.go

@@ -43,7 +43,7 @@ func (this *AnalysisDec) DecQueryNewSimilarMsgByBW() (qstr string) {
 	bools := []string{}
 	musts := []string{}
 	shoulds := []string{}
-	var BWExists = 1
+	var BWExists = 0
 	//中标单位 类似项目合作历史||采购单位类似项目
 	if this.Winner != "" {
 		BWExists += 1
@@ -70,8 +70,9 @@ func (this *AnalysisDec) DecQueryNewSimilarMsgByBW() (qstr string) {
 		buyerterms += `]}}`
 		musts = append(musts, buyerterms)
 	}
-	if BWExists > 1 && this.SearchType == 3 {
-		this.SearchType = 1
+	//searchType ==1; buyer & winner 不能为空
+	if BWExists < 2 && this.SearchType == 1 {
+		this.SearchType = 0
 	}
 	//省份
 	areaCity := []string{}

+ 6 - 5
src/jfw/modules/bigmember/src/entity/analysisEntName.go

@@ -188,7 +188,7 @@ type AnalysisDec struct {
 	MobileModel      string                 //手机型号
 	AppVersion       string                 //app版本号
 	Winner           string                 //中标企业
-	SearchType       int                    //默认0;1:中标企业||采购单位-类似项目明细;2:中标企业和采购单位类似项目明细;3:中标企业和采购单位其他项目明细
+	SearchType       int                    //默认0:中标企业||采购单位||(中标企业&&采购单位)-类似项目明细;1:中标企业和采购单位其他项目明细
 	UserId           string                 //用户id
 	IsPower          bool                   //是否有权限
 	UserLock         sync.Mutex             //用户锁
@@ -225,17 +225,18 @@ func (this *AnalysisDec) GetProjectInfoByBW() (res []map[string]interface{}) {
 	this.BuyerContent = BuyerContentStruct(this.BuyerContent)
 	//中标企业和采购单位类似项目明细
 	decQuery := this.DecQueryNewSimilarMsgByBW()
+	// log.Println("decQuery:", decQuery)
 	similarMsg, _idMap := this.GetAllMsgByBW(decQuery)
-	// log.Println(decQuery)
+	// log.Println(len(similarMsg), _idMap, "ti--:", this.SearchType)
 	//其他项目明细
 	switch this.SearchType {
-	case 1, 2:
+	case 0:
 		res = similarMsg
-	case 3:
+	case 1:
 		//中标企业和采购单位 所有项目明细
 		allQuery := this.GetAllBWQueryByBW()
 		allMsg, _ := this.GetAllMsgByBW(allQuery)
-		// log.Println(allQuery)
+		// log.Println(allQuery, "----", len(allMsg))
 		if len(allMsg) > 0 {
 			for _, v := range allMsg {
 				id := qutil.ObjToString(v["_id"])

+ 4 - 1
src/jfw/modules/bigmember/src/service/analysis/forecastproject.go

@@ -93,7 +93,7 @@ func (this *Analysis) ForPList() {
 				if pageNum == 1 {
 					if (*o_member_jy)["a_items"] != nil {
 						a_items := qutil.ObjArrToMapArr((*o_member_jy)["a_items"].([]interface{}))
-						if len(a_items) == 0 {
+						if len(a_items) == 0 || a_items[0]["a_key"] == nil || len(a_items[0]["a_key"].([]interface{})) == 0 {
 							msg = "暂无设置订阅关键词,无法进行预测"
 							code = 1
 						} else if (list == nil || len(list) == 0) && len(flist) == 0 {
@@ -436,6 +436,9 @@ func getKeyWordArr(a_items []interface{}, item string, index int) (arr []util.Vi
 		if item != "" && index >= 0 && item != qutil.ObjToString(vm["s_item"]) {
 			continue
 		}
+		if vm["a_key"] == nil {
+			continue
+		}
 		kwsArr := vm["a_key"]
 		for i, k := range kwsArr.([]interface{}) {
 			if item != "" && index >= 0 && i != index {

+ 5 - 4
src/jfw/modules/common/src/qfw/util/jy/bigVipPower.go

@@ -53,7 +53,7 @@ const (
 	PowerCacheEntPortKey   = "free_power_entport_%s"
 	PowerCacheBuyerPortKey = "free_power_buyerport_%s"
 	PowerCacheFileKey      = "free_power_File_%s"
-	UserUpdateAreaKey      = "free_area_num_%s"
+	UserUpdateAreaKey      = "free_area_num_%s_%s"
 	BaseAreaNum            = 1
 )
 
@@ -98,7 +98,7 @@ func GetBigVipUserBaseMsg(userId string, mysql *mysql.Mysql, mg MongodbSim) *Big
 	if userId == "" {
 		return &userPower
 	}
-	userPower.IsUpgrade = true
+	userPower.IsUpgrade = false
 	userPower.Uid = userId
 	cacheKey := fmt.Sprintf(PowerCacheKey, userId)
 
@@ -141,8 +141,9 @@ func GetBigVipUserBaseMsg(userId string, mysql *mysql.Mysql, mg MongodbSim) *Big
 			userPower.FreeBuyerPort = redis.GetInt(PowerCacheDb, fmt.Sprintf(PowerCacheBuyerPortKey, userId))
 			userPower.FreeFile = redis.GetInt(PowerCacheDb, fmt.Sprintf(PowerCacheFileKey, userId))
 			o_jy := qutil.ObjToMap((*data)["o_jy"])
-			if _, ok := (*o_jy)["o_area"]; !ok {
-				userPower.IsUpgrade = false
+			//"i_newfree":    1, //新免费用户=>新订阅设置页面 20211122
+			if qutil.IntAll((*o_jy)["i_newfree"]) > 0 {
+				userPower.IsUpgrade = true
 			}
 		}
 	}

+ 17 - 6
src/jfw/modules/publicapply/src/subscribe/entity/entity.go

@@ -9,6 +9,7 @@ import (
 	"qfw/util/elastic"
 	"qfw/util/jy"
 	"qfw/util/redis"
+	"time"
 
 	// "reflect"
 	"strconv"
@@ -60,7 +61,8 @@ func (this *ParamInfo) SetAreaByOneProvince() (b bool) {
 		}
 		if len(areas) == 1 {
 			if db.Mgo.UpdateById("user", this.UserId, map[string]interface{}{"$set": map[string]interface{}{
-				"o_jy.o_area": areas, //设置地区
+				"o_jy.o_area":    areas, //设置地区
+				"o_jy.i_newfree": 1,     //老免费用户=>新订阅设置页面 20211122
 			}}) {
 				jy.ClearBigVipUserPower(this.UserId)
 			}
@@ -160,16 +162,25 @@ func (pi *ParamInfo) GetSubMsg() UserSubMsg {
 			res.Area, _ = o_jy["o_area"].(map[string]interface{})
 		}
 		res.Infotype, _ = o_jy["a_infotype"].([]interface{})
-		//地区调整可用次数
-		pnum := redis.GetInt(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, pi.UserId))
-		res.Areanum = qutil.If(pnum > 0, jy.BaseAreaNum-pnum, jy.BaseAreaNum).(int)
-		//购买省份订阅包
+
+		//免费用户未购买省份订阅包 按年算
+		year := fmt.Sprint(time.Now().Year())
+		//免费用户未购买省份订阅包 已调整地区次数(年)
+		fpnum := redis.GetInt(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, pi.UserId, year))
+		//免费用户未购买省份订阅包 地区调整可用次数(默认值)
+		res.Areanum = qutil.If(fpnum > 0, jy.BaseAreaNum-fpnum, jy.BaseAreaNum).(int)
+		//免费用户已购买省份订阅包
 		if o_jy["i_ppstatus"] != nil && qutil.IntAll(o_jy["i_ppstatus"]) > 0 {
 			o_buyset_p, _ := o_jy["o_buyset_p"].(map[string]interface{})
 			res.Provincenum = qutil.IntAll(o_buyset_p["areacount"]) //-1 全国无限制
 			res.Areanum = res.Provincenum
 			if res.Provincenum > 0 {
-				res.Areanum = res.Provincenum + jy.BaseAreaNum - pnum
+				//按月算
+				ym := fmt.Sprint(time.Now().Year()) + "-" + fmt.Sprint(time.Now().Month())
+				//已调整地区次数(月)
+				ppnum := redis.GetInt(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, pi.UserId, ym))
+				//可调整次数(月)
+				res.Areanum = res.Provincenum + jy.BaseAreaNum - fpnum - ppnum
 			}
 			res.Ppstarttime = qutil.Int64All(o_jy["l_areaStart_p"])
 			res.Ppendtime = qutil.Int64All(o_jy["l_areaEnd_p"])

+ 70 - 22
src/jfw/modules/publicapply/src/subscribePush/entity/setting.go

@@ -8,6 +8,8 @@ import (
 	qutil "qfw/util"
 	"qfw/util/jy"
 	"qfw/util/redis"
+	"sort"
+	"strings"
 	"time"
 	"util"
 )
@@ -36,28 +38,49 @@ func (this *SubscribeSet) SetAreaAndIndustry() *FuncResult {
 
 //
 func freeSet(area map[string]interface{}, industry []string, userId string) *FuncResult {
-	if len(area) == 0 {
+	//isfirst:是否第一次设置地区;ppb:是否购买省级订阅包; areacount:省份订阅包购买的省份数量-1:全国 无限制调整
+	isfirst, ppb, areacount := IsCanSet(userId, area)
+	//购买省份订阅包 已调整地区次数
+	ppnum := 0
+	//免费用户购买省份订阅包 按月算
+	ym := fmt.Sprint(time.Now().Year()) + "-" + fmt.Sprint(time.Now().Month())
+	if ppb {
+		ppnum = redis.GetInt(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, userId, ym))
+	} else if len(area) == 0 {
 		return &FuncResult{false, errors.New("地区参数异常"), nil}
 	}
-
-	//地区调整已用次数
-	pnum := redis.GetInt(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, userId))
-	log.Println(len(area), "pnum:", pnum)
-	//是否购买省级订阅包   省份订阅包购买的省份数量-1:全国 无限制调整;isfirst:是否第一次设置地区
-	isfirst, ppb, areacount := IsCanSet(userId)
-	//第一次设置地区不扣次数
-	if !isfirst {
-		//
-		if len(area) > areacount+jy.BaseAreaNum {
+	//免费用户未购买省份订阅包 按年算
+	year := fmt.Sprint(time.Now().Year())
+	//免费用户 已调整地区次数
+	fpnum := redis.GetInt(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, userId, year))
+	// log.Println(len(area), "fpnum:", fpnum, "ppnum:", ppnum)
+	//第一次设置地区 || 购买全国  不扣次数
+	var issetredis = areacount > -1 && !isfirst
+	if issetredis {
+		//地区范围判断
+		if areacount+jy.BaseAreaNum < len(area) {
 			return &FuncResult{false, errors.New("超出地区可设置范围"), nil}
 		}
-		//
-		if areacount > -1 && areacount+jy.BaseAreaNum <= pnum {
+		//地区调整次数判断
+		if areacount+jy.BaseAreaNum <= ppnum+fpnum {
 			return &FuncResult{false, errors.New(fmt.Sprintf("订阅地区调整次数(%d)已用完", areacount+jy.BaseAreaNum)), nil}
 		}
 	}
 	if !FreeSubChange(userId, &area, industry, ppb, isfirst) {
 		return &FuncResult{false, errors.New("保存修改出错"), nil}
+	} else if issetredis { //更新调整次数 非全国(第一次 不消耗次数)
+		//清楚缓存
+		jy.ClearBigVipUserPower(userId)
+		//优先使用省份订阅包次数
+		// log.Println(areacount, "---", ppnum)
+		// log.Println(jy.BaseAreaNum, "---", fpnum)
+		if ppb && areacount > ppnum {
+			redis.Put(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, userId, ym), ppnum+1, 31*24*60*60)
+		} else if jy.BaseAreaNum > fpnum {
+			redis.Put(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, userId, year), fpnum+1, 365*24*60*60)
+		} else {
+			log.Println(fmt.Sprintf("免费用户设置地区 扣除次数异常  userId:%s", userId))
+		}
 	}
 	SetLog(userId, "o_jy")
 	return &FuncResult{true, nil, map[string]interface{}{
@@ -68,39 +91,64 @@ func freeSet(area map[string]interface{}, industry []string, userId string) *Fun
 //免费用户地区调整
 func FreeSubChange(userId string, area *map[string]interface{}, industry []string, ppb, isfirst bool) bool {
 	setMap := map[string]interface{}{"$set": map[string]interface{}{
-		"o_jy.o_area": area, //设置地区
+		"o_jy.o_area":    area, //设置地区
+		"o_jy.i_newfree": 1,    //老免费用户=>新订阅设置页面 20211122
 	}}
 	if ppb {
 		setMap = map[string]interface{}{"$set": map[string]interface{}{
-			"o_jy.o_area_p": area, //设置地区
+			"o_jy.o_area_p":  area, //设置地区
+			"o_jy.i_newfree": 1,    //老免费用户=>新订阅设置页面 20211122
 		}}
 	}
 	updateOk := db.Mgo.UpdateById("user", userId, setMap)
 	if !updateOk {
 		return false
-	} else if !isfirst && redis.GetInt(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, userId)) > -1 { //更新调整次数 非全国(第一次 不消耗次数)
-		//清楚缓存
-		jy.ClearBigVipUserPower(userId)
-		redis.Incr(jy.PowerCacheDb, fmt.Sprintf(jy.UserUpdateAreaKey, userId))
 	}
 	return true
 }
 
 //是否可进行地区调整
-func IsCanSet(userId string) (bool, bool, int) {
+func IsCanSet(userId string, areamap map[string]interface{}) (bool, bool, int) {
 	areacount := 0
+	myarea := []string{}
+	setarea := []string{}
+	myareamap := map[string]interface{}{}
 	mData, ok := db.Mgo.FindById("user", userId, `{"o_jy":1}`)
 	if !ok || len(*mData) == 0 || mData == nil {
 		return false, false, areacount
 	}
 	o_jy, _ := (*mData)["o_jy"].(map[string]interface{})
+	//地区是否完全一致
+	if o_jy["o_area"] != nil {
+		myareamap = *qutil.ObjToMap(o_jy["o_area"])
+
+	}
 	//是否购买省份订阅包
 	if o_jy["i_ppstatus"] != nil && qutil.IntAll(o_jy["i_ppstatus"]) > 0 {
 		o_buyset_p, _ := o_jy["o_buyset_p"].(map[string]interface{})
 		areacount = qutil.IntAll(o_buyset_p["areacount"]) //-1 全国无限制
+		myareamap = *qutil.ObjToMap(o_jy["o_area_p"])
+	}
+	for oak, _ := range myareamap {
+		myarea = append(myarea, oak)
+	}
+	for sak, _ := range areamap {
+		setarea = append(setarea, sak)
 	}
-	log.Println(jy.BaseAreaNum, "---areacount:", areacount)
-	return o_jy["o_area"] == nil, o_jy["i_ppstatus"] != nil && qutil.IntAll(o_jy["i_ppstatus"]) > 0, areacount
+	if areaSort(setarea) == areaSort(myarea) {
+		log.Println(setarea, "-地区选择前后一致-", myarea)
+		return true, qutil.IntAll(o_jy["i_ppstatus"]) > 0, areacount
+	}
+	// log.Println(areaSort(setarea) == areaSort(myarea), "---areacount:", areacount)
+	return o_jy["o_area"] == nil, qutil.IntAll(o_jy["i_ppstatus"]) > 0, areacount
+}
+
+//
+func areaSort(area []string) string {
+	sort.Slice(area, func(i, j int) bool {
+		return area[i] < area[j]
+	})
+	return strings.Join(area, ",")
 }
 
 //

+ 9 - 2
src/jfw/modules/subscribepay/src/entity/areaPack.go

@@ -3,6 +3,7 @@ package entity
 import (
 	"encoding/json"
 	"fmt"
+	"jfw/modules/common/src/qfw/util/jy"
 	"log"
 	qutil "qfw/util"
 	"time"
@@ -195,14 +196,20 @@ func (this *AreaPackFilter) Power(userid string, startime, endtime time.Time) bo
 		"o_jy.o_buyset_p":  map[string]interface{}{"areacount": this.Num},
 		"o_jy.l_areaEnd_p": endtime.Unix(),
 		"o_jy.i_ppstatus":  1,
+		"o_jy.i_newfree":   1, //新免费用户=>新订阅设置页面 20211122
 	}
 	if this.OrderType == 1 || this.OrderType == 2 {
 		setMap["o_jy.l_areaStart_p"] = startime.Unix()
 		setMap["o_jy.o_area_p"] = this.Area
 	}
-	return util.MQFW.UpdateById("user", userid, map[string]interface{}{
+	if util.MQFW.UpdateById("user", userid, map[string]interface{}{
 		"$set": setMap,
-	})
+	}) {
+		//清除 用户权限缓存
+		jy.ClearBigVipUserPower(userid)
+		return true
+	}
+	return false
 }
 
 //获取产品id

+ 2 - 0
src/jfw/modules/subscribepay/src/service/areaPack.go

@@ -89,6 +89,8 @@ func (this *AreaPack) CreateOrder() {
 						discount_price = totalfee - totalfee*disCount_int/1000
 						totalfee = totalfee * disCount_int / 1000
 					}
+				} else {
+					userLotteryId = ""
 				}
 			}
 		}

+ 2 - 0
src/jfw/modules/subscribepay/src/service/dataExportPay.go

@@ -166,6 +166,8 @@ func (p *DataExportPay) CreateOrder() {
 					discount_price = order_money - order_money*disCount_int/1000
 					order_money = order_money * disCount_int / 1000
 				}
+			} else {
+				userLotteryId = ""
 			}
 		}
 		log.Println(userLotteryId, "--discount_price:", discount_price)

+ 2 - 2
src/jfw/modules/subscribepay/src/service/dataexportPack.go

@@ -132,10 +132,8 @@ func (this *DataExportPack) CreateOrder() {
 			fullPrice, reducePrice, discount, userLotteryId = util.GetCouponInfo(userId, lotteryId, products)
 			if fullPrice <= orderMoney {
 				if discount == 100 {
-
 					orderMoney = orderMoney - reducePrice
 					discountPrice = reducePrice
-
 				} else {
 					//折扣
 					disCount_int := int(math.Ceil(discount * 100))
@@ -143,6 +141,8 @@ func (this *DataExportPack) CreateOrder() {
 					orderMoney = orderMoney * disCount_int / 1000
 				}
 				log.Printf("用户%s 购买数据流量包 使用卡券:%s 折扣金额:%d", userId, userLotteryId, discountPrice)
+			} else {
+				userLotteryId = ""
 			}
 		}
 		//赠品相关

+ 2 - 0
src/jfw/modules/subscribepay/src/service/integral.go

@@ -94,6 +94,8 @@ func (b *Integral) CreateOrder() {
 					discount_price = order_money - order_money*disCount_int/1000
 					order_money = order_money * disCount_int / 1000
 				}
+			} else {
+				userLotteryId = ""
 			}
 		}
 		log.Println(userLotteryId, "--discount_price:", discount_price)

+ 13 - 1
src/jfw/modules/subscribepay/src/service/orderListDetails.go

@@ -90,7 +90,19 @@ func (this *OrderListDetails) GetOrderPayAllMsg() {
 				(*oData)["return_type"] = (*returnRecord)["return_type"]
 			}
 		}
-
+		//获取最后一次购买的订单
+		lastOrderMap := LastOrder(qutil.ObjToString((*oData)["product_type"]), userId)
+		//最后一次够买的vip订单
+		for _, n := range lastOrderMap {
+			if n == orderCode {
+				(*oData)["lastbuy_code"] = n
+				if data, ok := util.MQFW.FindById("user", userId, `{"i_vip_status":1,"o_jy":1}`); data != nil && ok && len(*data) > 0 {
+					(*oData)["i_vip_status"] = qutil.Int64All((*data)["i_vip_status"])
+					ojy := qutil.ObjToMap((*data)["o_jy"])
+					(*oData)["i_pp_status"] = qutil.IntAllDef((*ojy)["i_ppstatus"], 0) //i_pp_status : -1 到期  0未购买 1已购买
+				}
+			}
+		}
 		//卡卷id加密
 		if (*oData)["d_relation_id"] != "" {
 			(*oData)["userLotteryId"] = qutil.SE.Encode2Hex(qutil.ObjToString((*oData)["d_relation_id"]))

+ 5 - 3
src/jfw/modules/subscribepay/src/service/userAccountInfo.go

@@ -7,9 +7,6 @@ import (
 	"database/sql"
 	"encoding/base64"
 	"fmt"
-	"github.com/dchest/captcha"
-	"github.com/go-xweb/httpsession"
-	"github.com/go-xweb/xweb"
 	"log"
 	"mongodb"
 	qutil "qfw/util"
@@ -19,6 +16,10 @@ import (
 	"strings"
 	"time"
 	"util"
+
+	"github.com/dchest/captcha"
+	"github.com/go-xweb/httpsession"
+	"github.com/go-xweb/xweb"
 )
 
 type UserAccount struct {
@@ -648,6 +649,7 @@ func (this *UserAccount) WxUnBind() {
 			(*unsetMap)["o_jy"] = map[string]interface{}{
 				"i_wxpush":   1,
 				"i_ratemode": 2,
+				"i_newfree":  1, //新免费用户=>新订阅设置页面 20211122
 			}
 			//公众号微信关注移至另一用户中  此时微信公众号用户session问题错乱
 			if saveId := util.MQFW.Save("user", unsetMap); saveId == "" {

+ 2 - 0
src/jfw/modules/subscribepay/src/service/vipSubscribeChange.go

@@ -245,6 +245,8 @@ func (this *SubscribeChange) Upgrade() {
 					discount_price = final_price - final_price*disCount_int/1000
 					final_price = final_price * disCount_int / 1000
 				}
+			} else {
+				userLotteryId = ""
 			}
 		}
 		//测试打折

+ 4 - 0
src/jfw/modules/subscribepay/src/service/vipSubscribePay.go

@@ -188,6 +188,8 @@ func (this *SubVipPayOrder) CreateOrder() {
 					discount_price = totalfee - totalfee*disCount_int/1000
 					totalfee = totalfee * disCount_int / 1000
 				}
+			} else {
+				userLotteryId = ""
 			}
 		}
 		//赠品相关
@@ -402,6 +404,8 @@ func (this *SubVipPayOrder) Renew() {
 					discount_price = totalfee - totalfee*disCount_int/1000
 					totalfee = totalfee * disCount_int / 1000
 				}
+			} else {
+				userLotteryId = ""
 			}
 		}
 		filterStr, _ := json.Marshal(filter)

+ 7 - 4
src/jfw/modules/weixin/src/config.json

@@ -16,11 +16,11 @@
     "weixinrpcport": "8083",
     "webrpcport": "127.0.0.1:8084",
     "jyop_webrpcport": "127.0.0.1:8012",
-    "webdomain": "https://web-ws.jydev.jianyu360.com",
-    "appid":"wx5b1c6e7cc4dac0e4",
-    "appsecret":"b026103ffebd2291b3edb7a269612112",
+    "webdomain": "https://web-zxl.jydev.jianyu360.com",
+    "appid":"wxdedd73f450993685",
+    "appsecret":"d55898fde0b7887e5fe4660bd2494700",
     "apptoken": "top2022top2022",
-    "proxysess": "https://web-ws.jydev.jianyu360.com/front/sess/%s",
+    "proxysess": "https://web-zxl.jydev.jianyu360.com/front/sess/%s",
     "followCompany": 10,
     "welcomemsg": "用剑鱼标讯,所有功能完全免费,\n和传统的会员制说再见!\n\n<a href='%s'>点击这里</a>设置关键词,或直接回复“订阅 关键词”,如“订阅 教学设备”,您将随时随地接收招标信息!\n\n剑鱼标讯,让投标无限可能!",
     "tpl_subscribe_push_id": "IY_RWWzMlwDK6hcd6RAzTec6qre8n5r8PNOOUM_hgk0",
@@ -140,5 +140,8 @@
         "EntUrl": ["企业全景分析","多维度帮你分析竞争对手","/big-member/image/wxreply/entportrait.png","https://mp.weixin.qq.com/s/0HguU-yu8eTf96Y8mNsD3A?wxreply=%s"],
         "BuyerUrl": ["采购单位全景分析","快速、全面地了解采购单位","/big-member/image/wxreply/buyportrait.png","https://mp.weixin.qq.com/s/gXpB25K6I8401115pBGV1g?wxreply=%s"],
         "ReportUrl": ["市场分析周报/月报","分析市场规模、增长趋势,评估市场体量","/big-member/image/wxreply/reportmm.png","https://mp.weixin.qq.com/s/rlJenKOvmHvqd9_4811otg?wxreply=%s"]
+    },
+    "pcQrCode":{
+    		"10":true,"11":true,"12":true,"13":true,"14":true,"17":true,"18":true,"19":true
     }
 }

+ 9 - 0
src/jfw/modules/weixin/src/wx/wx.go

@@ -502,6 +502,7 @@ func saveUser(u *UserInfo, source, pre, RSource, CSource string) (bool, string,
 			newUser["i_ts_guide"] = 2
 			newUser["o_jy"] = map[string]interface{}{
 				"i_wxpush":   1,
+				"i_newfree":  1, //新免费用户=>新订阅设置页面 20211122
 				"i_ratemode": 2,
 			}
 		} else {
@@ -526,6 +527,13 @@ func saveUser(u *UserInfo, source, pre, RSource, CSource string) (bool, string,
 				redis.Del("other", fromkey)
 			}
 		}
+		if pcQrCode := *util.ObjToMap(config.Sysconfig["pcQrCode"]); len(pcQrCode) > 0 {
+			if bl, ok := pcQrCode[pre].(bool); bl && ok {
+				newUser["s_platform"] = "pc"
+			} else {
+				newUser["s_platform"] = "wx"
+			}
+		}
 		_id := tools.MQFW.Save("user", newUser)
 		if fromid != "" && fromid != _id {
 			//被邀请新用户
@@ -581,6 +589,7 @@ func saveUser(u *UserInfo, source, pre, RSource, CSource string) (bool, string,
 				"s_sourceid":      source,
 				"i_sourceid":      isourceid,
 				"o_jy.i_wxpush":   1,
+				"o_jy.i_newfree":  1, //新免费用户=>新订阅设置页面 20211122
 				"i_ispush":        1,
 				"s_headimageurl":  u.HeadImageUrl,
 				"s_nickname":      u.Nickname,

+ 5 - 1
src/web/staticres/big-member/js/set_area.js

@@ -188,8 +188,9 @@ var vNode = {
         // 根据城市的选择情况判断省份的选择情况
         changeCityState(province, city) {
             if (city === '#') {
+                this.setCitySelected()
                 this.onChange()
-                return this.setCitySelected()
+                return
             }
             // 全国置为空
             this.provinceListMap['#'][0].selectedState = ''
@@ -437,6 +438,7 @@ var vNode = {
             try {
                 onChange && onChange(selectedCity)
             } catch (error) {
+                console.log(error)
                 console.warn(arguments.callee.name + '必须定义为函数')
             }
         },
@@ -445,6 +447,7 @@ var vNode = {
             try {
                 onReset && onReset(this.initCityMap)
             } catch (error) {
+                console.log(error)
                 console.error(arguments.callee.name + '必须定义为函数')
             }
         },
@@ -453,6 +456,7 @@ var vNode = {
             try {
                 onConfirm && onConfirm(selectedCity)
             } catch (error) {
+                console.log(error)
                 console.error(arguments.callee.name + '必须定义为函数')
             }
         }

+ 8 - 2
src/web/staticres/big-member/js/unit_portrayal.js

@@ -394,11 +394,17 @@ var vNode = {
             data:storageSet ? Object.assign(data, storageSet) : data,
             success:function(res) {
                 if(res.error_code == 0) {
+                  that.reqCount++;
                   if(res.data && Object.keys(res.data).length > 0) {
                       that.chartLoading = false;
                       that.initChartData('', res.data)
                   } else {
-                    that.getSectionChartData('a')
+                    // that.getSectionChartData('a')
+                    if (that.reqCount < 5) {
+                      that.getChartData()
+                    } else {
+                      that.chartLoading = false;
+                    }
                   }
                 }
             },
@@ -415,7 +421,7 @@ var vNode = {
             url:'/bigmember/portrait/buyer/getData',
             data:{
               buyer: decodeURIComponent(utils.getParam('entName')),
-              flag: type
+              flag: type //先a再b再c
             },
             success:function(res) {
                 if(res.error_code == 0) {

+ 8 - 3
src/web/staticres/common-module/big-member/js/high_set.js

@@ -78,7 +78,7 @@ var highSet = new Vue({
   watch: {
     // 监听初始时间 如果结束时间小于初始时间 则两个调换位置
     'conf.start': function(newVal) {
-      console.log(this.conf.end, newVal)
+      // console.log(this.conf.end, newVal)
       if (this.conf.end < newVal) {
         this.conf.start = this.conf.end
         this.conf.end = newVal
@@ -232,7 +232,8 @@ var highSet = new Vue({
           success: function (res) {
             if (res.error_code == 0) {
               loading.clear()
-              _this.filterInitData = res.data
+              _this.filterInitData.areaArr = res.data.areaArr || []
+              _this.filterInitData.scopeArr = res.data.scopeArr || []
               // _this.initSelector(res.data)
             } else {
               _this.showToast(res.error_msg)
@@ -356,8 +357,9 @@ var highSet = new Vue({
         obj[s.name] = s.value
         resArr.push(obj)
       })
-      console.log(resArr, '过滤好的行业数据')
+      // console.log(resArr, '过滤好的行业数据')
       this.$refs.industryCom.formatIndustryData(resArr)
+      this.$refs.industryCom.canClick = false
       // this.$refs.industryCom.setState(this.selectIndustryList)
     },
     // 分析方式
@@ -376,11 +378,13 @@ var highSet = new Vue({
         this.$refs.projectAreaSelector.setState(this.selectAreaList)
       } else if (data.name == 'industryItem') {
         this.$refs.industryCom.setState([])
+        this.$refs.industryCom.canClick = false
       } else if (data.name == 'dateItem') {
         
       }
     },
     onConfirm: function (data) {
+      // console.log(data, 'data')
       if (data.name === 'areaItem') {
         if (data.data.length === 0) {
           this.conf.area = '全国'
@@ -401,6 +405,7 @@ var highSet = new Vue({
       } else if (data.name === 'industryItem') {
         if (data.data.length === 0) {
           this.conf.industry = '全部'
+          this.selectIndustryList = data.data
         } else {
           this.conf.industry = data.data.join(',')
           this.selectIndustryList = data.data

+ 13 - 1
src/web/staticres/common-module/collection/js/history-project.js

@@ -17,7 +17,7 @@ var historyProTemplate = `
                           <div class="contactlabel">联系人:</div>
                           <div class="contact-name">{{data[Object.keys(data)] || '--'}}</div>
                       </div>
-                      <a :href="'tel:'+Object.keys(data)[0]" class="contact-bot" v-if="Object.keys(data)[0]!==''" @click="telPhoneClick($event,Object.keys(data)[0])">
+                      <a :href="'tel:'+formatTel(Object.keys(data)[0])" class="contact-bot" v-if="Object.keys(data)[0]!==''" @click="telPhoneClick($event,Object.keys(data)[0])">
                           <div class="con-left">
                               <div class="contact-phonelabel">联系方式:</div>
                               <div class="contact-phone">{{Object.keys(data)[0]}}</div>
@@ -153,6 +153,10 @@ var hisproComponent = {
       if(!utils.isWeiXinBrowser) {
         e.preventDefault()
         try {
+          var f = /[^\s\、,,;;./。??]+(?=[\s\、,,;;./。??])/g
+          if(tel.match(f)) {
+            tel = tel.match(f)[0]
+          }
           JyObj.callPhone(tel);
         } catch (error) {
           
@@ -167,5 +171,13 @@ var hisproComponent = {
       })
       return loading
     },
+    // 联系方式取第一个
+    formatTel: function (tel) {
+      var f = /[^\s\、,,;;./。??]+(?=[\s\、,,;;./。??])/g
+      if(tel.match(f)) {
+        tel = tel.match(f)[0]
+      }
+      return tel
+    }
   }
 }

+ 49 - 2
src/web/staticres/common-module/order-list/js/order-detail.js

@@ -45,7 +45,8 @@ var vm = new Vue({
           bottomButtonShow: {
             pay: false,
             invoke: true,
-            buyAgain: false
+            buyAgain: false,
+            renew: false
           }
         },
         '-2': {
@@ -226,7 +227,7 @@ var vm = new Vue({
       }
 
       // 如果是可再次购买的产品,则显示再次购买
-      if (this.prodConf.canBuyAgain.indexOf(this.orderInfo.productType) && order.pay_money > 0) {
+      if (this.prodConf.canBuyAgain.indexOf(this.orderInfo.productType) !== -1 && order.pay_money > 0) {
         this.orderStateMap[1].bottomButtonShow.buyAgain = true
       }
 
@@ -237,6 +238,27 @@ var vm = new Vue({
 
       this.orderInfo.productInfoList = this.getProductInfoList(info)
       this.orderInfo.orderInfoList = this.getOrderInfoListList(info)
+      // this.getOrderBottomButton(info.order)
+    },
+    getOrderBottomButton (order) {
+      switch (order.product_type) {
+        case '省份订阅包': {
+          // 续费升级的判断(再次购买按钮值修改)
+          // i_pp_status : -1 到期  0未购买 1已购买
+          this.orderStateMap[1].bottomButtonShow.buyAgain = false
+          this.orderStateMap[1].bottomButtonShow.renew = false
+          var vipStatus =  order.i_pp_status
+          if (order.lastbuy_code) {
+            if (vipStatus === -1 && order.pay_money > 0) {
+              this.orderStateMap[1].bottomButtonShow.buyAgain = true
+            }
+            if (vipStatus === 1) {
+              this.orderStateMap[1].bottomButtonShow.renew = true
+            }
+          }
+          break
+        }
+      }
     },
     getHeaderImg: function (order) {
       var productType = order.product_type
@@ -406,6 +428,24 @@ var vm = new Vue({
         }
       }
     },
+    renew: function () {
+      var order = this.reqOrder
+      var orderCode = order.order_code
+      var productType = order.product_type
+      var platform = this.platform
+      switch (productType) {
+        case '省份订阅包': {
+            var href = assetsConf.areaPackLink.renew[platform]
+            if (href) {
+              this.goToLink(`${href}&orderCode=${orderCode}`)
+            }
+            break
+        }
+        default: {
+          break
+        }
+      }
+    },
     buyAgain: function () {
       var _this = this
       var order = this.reqOrder
@@ -421,6 +461,13 @@ var vm = new Vue({
           }
           break
         }
+        case '省份订阅包': {
+          var href = assetsConf.areaPackLink.buyAgain[platform]
+          if (href) {
+            this.goToLink(`${href}&orderCode=${orderCode}`)
+          }
+          break
+        }
         default: {
           break
         }

+ 28 - 15
src/web/staticres/common-module/vipsubscribe/js/vip-subscribe-set-template.js

@@ -305,7 +305,7 @@ var subComponent = {
       this.iosBackRefresh()
     },
     // 判断用户权限
-    
+
     // 设置区域
     setArea: function() {
       let _this = this
@@ -513,6 +513,11 @@ var subComponent = {
       $iosActionsheet.removeClass('weui-actionsheet_toggle');
       $('.match-keywords-actionsheet').hide()
       $iosMask.fadeOut(200);
+      // 免费用户
+      if (this.thisvSwitch === 'f') {
+        return
+      }
+      // 超级订阅升级提示
       if(update_renew) {
         if(this.accStatus == 2) {
           update_renew.hide()
@@ -552,6 +557,11 @@ var subComponent = {
         }
         location.href = href
       } else {
+
+        if (this.vSwitch === 'f') {
+          return this.hideActionSheet()
+        }
+
         if(_this.accStatus == 2) {
           vswitch = 'm'
         } else if(_this.accStatus == 1)  {
@@ -641,6 +651,7 @@ var subComponent = {
     },
     // 修改地区无次数点击事件
     userNumOver: function () {
+      var _this = this
       if (this.vSwitch === 'f' && this.userAreaNum === 0) {
         this.linkobj.area = 'javascript:;'
         if (this.userAreaAllNum > 0) {
@@ -655,9 +666,9 @@ var subComponent = {
                 label: '取消',
                 type: 'default'
             },{
-              label: this.userType ? '去升级' : '去购买',
+              label: _this.userType ? '去升级' : '去购买',
               onClick: function(){
-                if (this.userType) {
+                if (_this.userType) {
                   if (location.href.indexOf('front') !== -1) {
                     var href = '/areaPack/wx/page/buy?type=upgrade'
                   } else {
@@ -674,7 +685,7 @@ var subComponent = {
               }
             }]
         });
-      } 
+      }
       else {
         // this.linkobj.area = '/jyapp/big/page/set_area?callback=setting_save'
         if (this.vSwitch === 'f') {
@@ -711,7 +722,7 @@ var subComponent = {
         } else {
           location.href = '/jyapp/vipsubscribe/toSetInfoTypePage'
         }
-        
+
       }
     },
     // 重置信息类型
@@ -764,9 +775,9 @@ var subComponent = {
     // 跳转地区选择
     gotoArea: function () {
       if (location.href.indexOf('front') !== -1) {
-        location.href = '/areaPack/wx/page/set_area'
+        location.href = '/areaPack/wx/page/set_area?type=new'
       } else {
-        location.href = '/jyapp/areaPack/page/set_area'
+        location.href = '/jyapp/areaPack/page/set_area?type=new'
       }
     },
     // 获取用户权限
@@ -783,7 +794,7 @@ var subComponent = {
               _this.userAreaNum = res.data.areanum
               _this.userType = res.data.provincenum === 0 ? false : true
               _this.userAreaAllNum = res.data.provincenum
-              _this.initdata.infotype = res.data.infotype || [] 
+              _this.initdata.infotype = res.data.infotype || []
               _this.info.infoType = _this.initdata.infotype.join('、')
               // _this.$emit('UserSubscribe',res)
 
@@ -808,11 +819,13 @@ var subComponent = {
               // _this.info.area = '已选:' + proStr
 
               let areaArr = []
-              if (res.data.area === {} || res.data.provincenum === 0) {
-                _this.noAreaFreeType = true
-              } else {
-                for (const key in res.data.area) {
-                  areaArr.push(key)
+              if (res.data) {
+                if (!res.data.area) {
+                  _this.noAreaFreeType = true
+                } else {
+                  for (const key in res.data.area) {
+                    areaArr.push(key)
+                  }
                 }
               }
               $('#menuArea').text('已选:'+ areaArr.join('、'))
@@ -839,7 +852,7 @@ var subComponent = {
         _this.backTipShowCount++
       })
     },
-    // 
+    //
     // 最近三个月推送结果预览总数
     getResultView: function () {
       let keyArr = []
@@ -959,4 +972,4 @@ var custom = {
       })
   }
 }
-setInfoTypeFn.init()
+setInfoTypeFn.init()

+ 14 - 7
src/web/staticres/vipsubscribe/js/vip_index_new.js

@@ -20,13 +20,18 @@ var subNode = new Vue({
             userAreaAllNum: 1, // 用户可修改地区总次数
             subscribeTime: '', // 用户订阅的时间
             vSwitch:'', // 用户版本权限
-            freeUserArea: {}, // 购买省份订阅包的用户所选择的地区 
+            freeUserArea: {}, // 购买省份订阅包的用户所选择的地区
         }
     },
     created () {
         this.getUserSubscribe()
         this.getUserType()
     },
+    mounted () {
+        this.$nextTick(function () {
+            $(".app-layout-content-b").removeAttr('v-cloak')
+        })
+    },
     methods: {
         superOrderTemplateMounted () {
             $('#pushResultPreview').attr('data-cl-event', 'c_wx_preview_buttonclick')
@@ -37,7 +42,7 @@ var subNode = new Vue({
                 var href = '/front/vipsubscribe/introducePage'
                 location.href = href
             }
-            
+
         },
         // 得到用户是否购买省份包
         getUserSubscribe: function () {
@@ -56,11 +61,11 @@ var subNode = new Vue({
                 }
             })
         },
-        // 省份订阅包续费 
+        // 省份订阅包续费
         renewBtn: function () {
             location.href = '/areaPack/wx/page/buy?type=renew'
         },
-        // 省份订阅包升级 
+        // 省份订阅包升级
         updateBtn: function () {
             location.href = '/areaPack/wx/page/buy?type=upgrade&area=' +  encodeURIComponent(JSON.stringify(this.freeUserArea))
         },
@@ -73,11 +78,13 @@ var subNode = new Vue({
                 success: function(res) {
                     if (res.data.vt !== 'v' ) {
                         _this.vSwitch = 'f'
+                        document.title = '订阅管理-免费订阅'
                         $('.update_renew').hide()
                         $('.super-title').text('订阅管理-免费订阅');
                         $('.super-title').css('background', 'none')
                     } else {
                         _this.vSwitch = 'v'
+                        document.title = '订阅管理-超级订阅'
                         $('.update_renew').show()
                         $('.super-title').show();
                     }
@@ -149,7 +156,7 @@ function getNewYearMarketing () {
 
 $(function () {
     /* vue 代码 start 提交订单 */
-  // var coupon = new Vue({ 
+  // var coupon = new Vue({
   //   el: '#coupon-vue',
   //   data: function () {
   //     return {
@@ -173,7 +180,7 @@ $(function () {
   //   },
   //   mounted () {
   //     this.init()
-  //   }, 
+  //   },
   //   methods: {
   //     // 更新价格相关
   //     updatePrice: function (before) {
@@ -1009,7 +1016,7 @@ $(function () {
     //         // initBack(2);// 升级
     //     }
     // } else {
-        
+
     // }
     getDataWitXHR()
     //返回提示使用

+ 190 - 144
src/web/templates/areaPack/wx/page_set_area.html

@@ -36,7 +36,6 @@
             font-weight: 500;
             color: #FA483C;
             box-sizing: border-box;
-            display: none;
         }
         .selectChange {
             font-size: 0.24rem;
@@ -119,185 +118,232 @@
     <div id="set-header-template" v-cloak>
         <div class="wrapper-header" id="thisAreaTips">
             <div class="content">
-                <div class="selectNumMax">可选择<span class="numColor" id="canSelect">1个省</span></div>
+                <div class="selectNumMax">可选择<span class="numColor" id="canSelect">${ maxSelectText }</span></div>
                 <div class="string"></div>
                 <div class="selectNumList">
-                    <span>已选择<span class="numColor" id="thisSelect">1个省</span></span>
-                    <span class="moreTips">超出可订阅省份数量,前往购买省份订阅包 ></span>
+                    <span>已选择<span class="numColor" id="thisSelect">${ selectedAreaText }</span></span>
+                    <span class="moreTips" v-show="moreThanSubCount">超出可订阅省份数量,前往${ buyType }省份订阅包 &gt;</span>
                 </div>
                 <div class="selectChange"></div>
             </div>
-            <div class="popup-wrap" v-show="popupType">
+            <div class="popup-wrap" v-show="popupTip">
                 <div class="popup-content">
-                    <div class="popup-text" id="tips-text">您当前仅可订阅1个省,如需增加请购买【省份订阅包】</div>
+                    <div class="popup-text" id="tips-text">您当前仅可订阅${ maxSelectText },如需增加请${ buyType }【省份订阅包】</div>
                     <div class="popup-btnWrap">
-                        <div class="popup-btn" id="cancel" @click="hiddenTips">取消</div>
+                        <div class="popup-btn" id="cancel" @click="hideTips">取消</div>
                         <div class="popup-line"></div>
-                        <div class="popup-btn levelUp" id="btn-text" @click="toPay">去购买</div>
+                        <div class="popup-btn levelUp" id="btn-text" @click="toPay">去${ buyType }</div>
                     </div>
                 </div>
             </div>
         </div>
     </div>
     <script>
-        var setAreaFn = {
-            conf: {
-                sKey: 'sub_free_state'
-            },
-            buyPageInfo: {},
-            init: function () {
-                // 恢复页面状态
-                var pageInfo = sessionStorage.getItem(this.conf.sKey)
-                if (pageInfo) {
-                    this.buyPageInfo = JSON.parse(pageInfo)
-                    var areaInfo = this.buyPageInfo.area
-                    if (this.buyPageInfo && areaInfo && Object.keys(areaInfo).length !== 0) {
-                        vNode.data.initCityMap = areaInfo
-                        vueComponent.setCitySelected(areaInfo)
-                    }
-                }
-            },
-            saveToSessionStorage: function (data) {
-                sessionStorage.setItem(this.conf.sKey, JSON.stringify(data))
-            }
-        }
-       var vm = new Vue({
+        var vm = new Vue({
             delimiters: ['${', '}'],
             el: '#set-header',
             template: '#set-header-template',
             data: {
-                popupType: false,
-                popupText: '您当前仅可订阅1个省,如需增加请购买【省份订阅包】',
-                popupPayBtn: '去购买'
+                sessKey: 'sub_free_set_area',
+                selectedArea: '',
+                userSubInfo: {
+                    area: '',
+                    areanum: 0, // 可修改次数
+                    basenum: 1,
+                    provincenum: 0, // 购买的省份数量
+                },
+                popupTip: false
             },
-            created: function () {},
-            methods: {
-                hiddenTips: function () {
-                    this.popupType = false
+            computed: {
+                moreThanSubCount: function () {
+                    var max = this.maxSelectCount
+                    var sel = this.selectedAreaCount
+                    if (max === -1) return false
+                    if (sel === -1) return true
+                    if (sel > max) return true
                 },
-                toPay: function () {
-                    if (userType) {
-                        location.href = '/areaPack/wx/page/buy?type=renew&area=' +  encodeURIComponent(JSON.stringify(thisData))
+                maxSelectCount: function () {
+                    var baseNum = this.userSubInfo.basenum || 1
+                    var provincenum = this.userSubInfo.provincenum
+                    if (provincenum === -1) {
+                        return provincenum
                     } else {
-                        location.href = '/areaPack/wx/page/buy?type=buy&area=' +  encodeURIComponent(JSON.stringify(thisData))
+                        return provincenum + baseNum
                     }
                 },
-                
-            }
-        })
-        var maxSelect = 1
-        var thisSelectNum = 0
-        var userType = true // 用户是否购买过省份包
-        var vSwitch = 'f' // 用户版本,'f'免费版,m大会员,v超级订阅
-        // 获取用户权限
-        function getUserMsg() {
-            $.ajax({
-                url: '/bigmember/use/isAdd',
-                type: 'POST',
-                success: function (res) {
-                    if (res.data.vipStatus <= 0) {
-                        vSwitch = 'f'
-                        $('#thisAreaTips').show()
+                maxSelectText: function () {
+                    if (this.maxSelectCount === -1) {
+                        return '全国'
                     } else {
-                        vSwitch = 'v'
-                        $('#thisAreaTips').hide()
+                        return this.maxSelectCount + '个省'
                     }
-                }
-            })
-        }
-        getUserMsg()
-        // 获取用户购买省份包信息
-        function getUserSubscribe() {
-            $.ajax({
-                url: '/publicapply/free/subscribe',
-                type: 'POST',
-                success: function (res) {
-                    let freeArea = JSON.stringify(res.data)
-                    sessionStorage.setItem('sub_free_state', freeArea)
-                    setAreaFn.init()
-                    onChange(res.data.area)
-                    userType = res.data.provincenum === 0 ? false : true
-                    maxSelect = res.data.provincenum  + res.data.basenum
-                    // _this.$emit('UserSubscribe',res)
-                    if (maxSelect === -1) {
-                        $('#canSelect').text(`全国`)
-                    } else if (res.data.provincenum === 0 && res.data.areanum === 1) {
-                        vueComponent.provinceListMap['#'][0].selectedState = ''
+                },
+                selectedAreaCount: function () {
+                    var area = this.selectedArea
+                    if (area) {
+                        var keys = Object.keys(area)
+                        if (keys.length === 0) {
+                            return -1
+                        } else {
+                            return keys.length
+                        }
                     } else {
-                        $('#canSelect').text(`${maxSelect}个省`)
+                        return 0
+                    }
+                },
+                selectedAreaText: function () {
+                    if (this.selectedAreaCount === -1) {
+                        return '全国'
+                    } else {
+                        return this.selectedAreaCount + '个省'
                     }
-                    
-                }
-            })
-        }
-        getUserSubscribe()
-        function userUpdate(obj) {
-            let _this = this
-            console.info(obj)
-            $.ajax({
-                url: '/publicapply/subscribe/update',
-                type: 'POST',
-                data: {
-                    vSwitch: vSwitch,
-                    area:obj
                 },
-                success: function (res) {
-                    console.info(res)  
-                    window.history.back()           
+                // 是否购买了省份订阅包
+                userType: function () {
+                    if (this.userSubInfo.provincenum === -1) return true
+                    return this.userSubInfo.provincenum !== 0
+                },
+                buyType: function () {
+                    return this.userType ? '升级' : '购买'
+                },
+            },
+            mounted: function () {
+                var type = utils.getParam('type')
+                var restore = this.restoreState()
+
+                if (restore) {
+                    this.initPageInfo()
+                } else {
+                    if (type === 'new') {
+                        this.setAreaAllNotSelected()
+                    } else {
+                        this.getUserSubscribe()
+                    } 
                 }
-            })
-        }
-        $('#thisSelect').text(`${thisSelectNum}个省`)
-        $('#canSelect').text(`${maxSelect}个省`)
-        // 以下均为示例:具体使用时候请删除
-        // 定义重置方法:方法名必须为onReset/onConfirm
-        // 参数,是被初始化的数据
+            },
+            methods: {
+                initPageInfo: function () {
+                    var area = this.selectedArea
+                    this.setComponentState(area)
+                },
+                setAreaSelected: function (area) {
+                    this.$set(this, 'selectedArea', area)
+                },
+                setComponentState: function (area) {
+                    vNode.data.initCityMap = area
+                    vueComponent.setCitySelected(area)
+                },
+                setAreaAllNotSelected: function () {
+                    vueComponent.setCitySelected()
+                    vueComponent.provinceListMap['#'][0].selectedState = ''
+                    $('#set-area .j-button-confirm').prop('disabled', true)
+                },
+                // 获取用户订阅信息
+                getUserSubscribe: function () {
+                    var _this = this
+                    $.ajax({
+                        url: '/publicapply/free/subscribe',
+                        type: 'POST',
+                        success: function (res) {
+                            if (res && res.error_code === 0) {
+                                if (res.data) {
+                                    if (res.data.area === null || res.data.area === undefined) {
+                                        _this.setAreaAllNotSelected()
+                                    } else {
+                                        if (res.data.area) {
+                                            // 赋值默认已选
+                                            _this.setAreaSelected(res.data.area)
+                                        }
+                                        for (var key in res.data) {
+                                            _this.$set(_this.userSubInfo, key, res.data[key])
+                                        }
+                                        _this.initPageInfo()
+                                    }
+                                }
+                            } else {
+                                if (res.error_msg) {
+                                    _this.$toast(res.error_msg)
+                                }
+                            }
+                        }
+                    })
+                },
+                userUpdate: function (area) {
+                    var _this = this
+                    $.ajax({
+                        url: '/publicapply/subscribe/update',
+                        type: 'POST',
+                        data: {
+                            vSwitch: 'f',
+                            area: JSON.stringify(area)
+                        },
+                        success: function (res) {
+                            if (res && res.success) {
+                                history.back()           
+                            } else {
+                                if (res.errMsg) {
+                                    _this.$toast(res.errMsg)
+                                }
+                            }
+                        }
+                    })
+                },
+                confirmed: function (area) {
+                    this.setAreaSelected(area)
+                    if (this.moreThanSubCount) {
+                        this.popupTip = true
+                    } else {
+                        this.userUpdate(area)
+                    }
+                },
+                hideTips: function () {
+                    this.popupTip = false
+                },
+                toPay: function () {
+                    this.popupTip = false
+                    var area = this.selectedArea
+                    var urlBase = '/jyapp/areaPack/page/buy'
+                    var areaJSON = encodeURIComponent(JSON.stringify(area))
+                    this.savePageState()
+                    if (this.userType) {
+                        location.href = urlBase + '?type=upgrade&area=' +  areaJSON
+                    } else {
+                        location.href = urlBase +  '?type=buy&area=' +  areaJSON
+                    }
+                },
+                restoreState: function () {
+                    var $data = sessionStorage.getItem(this.sessKey)
+                    if ($data) {
+                        $data = JSON.parse($data)
+
+                        this.selectedArea = $data.selectedArea
+                        Object.assign(this.userSubInfo, $data.userSubInfo)
+
+                        sessionStorage.removeItem(this.sessKey)
+                    }
+                    return !!$data
+                },
+                savePageState: function () {
+                    var data = {
+                        selectedArea: this.selectedArea,
+                        userSubInfo: this.userSubInfo
+                    }
+                    sessionStorage.setItem(this.sessKey, JSON.stringify(data))
+                },
+            }
+        })
+
         function onReset (initData) {
-            $('.selectChange').text('')
-            $('#thisSelect').text(`${thisSelectNum}个省`)
-            $('.moreTips').hide()
+            vm.setAreaSelected(initData)
         }
         // 被选中的数据
         function onConfirm (selectedData) {
-            var selectDataList = []
-            for (const key in selectedData) {
-                selectDataList.push(key)
-            }
-            if (selectDataList.length > maxSelect && maxSelect !== -1 && vSwitch === 'f') {
-                vm.popupType = true
-                if (!userType) {
-                    $('#tips-text').text('您当前仅可订阅1个省,如需增加请购买【省份订阅包】')
-                    $('#btn-text').text('去购买')
-                } else {
-                    $('#tips-text').text('已超出您可订阅的省份数量,是否升级【省份订阅包】')
-                    $('#btn-text').text('去升级')
-                }
-            } else {
-                var areaData = {}
-                selectDataList.forEach(function (item, index) {
-                    areaData[item] = []
-                })
-                areaData = JSON.stringify(areaData)
-                userUpdate(areaData)
-            }
+            vm.confirmed(selectedData)
         }
-        var thisData = []
         // 页面选中状态改变时触发
         function onChange (selectedData) {
-            thisData = selectedData
-            var selectDataList = []
-            for (const key in selectedData) {
-                selectDataList.push(key)
-            }
-            var arr = selectDataList.join('、')
-            $('.selectChange').text(`${arr}`)
-            thisSelectNum = selectDataList.length
-            $('#thisSelect').text(`${selectDataList.length}个省`)
-            if (thisSelectNum > maxSelect) {
-                $('.moreTips').show()
-            } else {
-                $('.moreTips').hide()
-            }
+            vm.setAreaSelected(selectedData)
+            $('#set-area .j-button-confirm').prop('disabled', false)
         }
     </script>
 </body>

+ 2 - 2
src/web/templates/pc/biddetail_rec.html

@@ -616,7 +616,7 @@ function isWechat() {
                               <span class="bid_phonetext">咨询 400-108-6670 了解更多</span>
                             </div>
                             <div class="contacts" v-if="buyerInfo && buyerInfo.contactList">
-                              <p class="contacts-title">历史项目联系方式</p>
+                              <p class="contacts-title">采购单位通讯录</p>
                               <p class="contacts-list" v-for="item in buyerInfo.contactList">
                                 <span class="c-l-time" v-if="item.date">成交时间:<span v-html="item.date"></span></span>
                                 <span class="c-l-way" v-if="item.contact">联系方式:<span v-html="item.contact"></span></span>
@@ -750,7 +750,7 @@ function isWechat() {
                             <span class="bid_phonetext">咨询 400-108-6670 了解更多</span>
                           </div>
                           <div class="contacts" v-if="winnerInfo && winnerInfo.contactList">
-                            <p class="contacts-title">历史项目联系方式</p>
+                            <p class="contacts-title">企业通讯录</p>
                             <p class="contacts-list" v-for="item in winnerInfo.contactList">
                               <span class="c-l-time" v-if="item.date">成交时间:<span v-html="item.date"></span></span>
                               <span class="c-l-way" v-if="item.contact">联系方式:<span v-html="item.contact"></span></span>

+ 4 - 0
src/web/templates/weixin/commonPay/areaPack/orderDetail.html

@@ -92,6 +92,10 @@
                         class="j-button-confirm buy-again"
                         v-if="orderStateMap[orderInfo.state].bottomButtonShow.buyAgain"
                         @click="buyAgain">再次购买</button>
+                    <button
+                            class="j-button-confirm renew"
+                            v-if="orderStateMap[orderInfo.state].bottomButtonShow.renew"
+                            @click="renew">续费</button>
                 </div>
             </div>
         </div>

+ 1 - 1
src/web/templates/weixin/commonPay/paySuccess.html

@@ -79,7 +79,7 @@
             继续浏览
         </button>
     </div>
-    {{else if or .T.doType "dataPack" .T.doType "areaPack"}}
+    {{else if or (eq .T.doType "dataPack") (eq .T.doType "areaPack")}}
         <div class="bottom_button j-button-group">
             <button id ="order" class="j-button-confirm" onclick="window.location.href = '/weixin/common/{{.T.doType}}/orderDetail?order_code={{.T.orderCode}}'">
                 查看订单

+ 4 - 4
src/web/templates/weixin/vipsubscribe/vip_index_new.html

@@ -6,7 +6,7 @@
     <meta name="viewport"
           content="width=device-width, initial-scale=1.0,minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
     <meta http-equiv="X-UA-Compatible" content="ie=edge">
-    <title>超级订阅</title>
+    <title>订阅管理</title>
     <meta name="apple-mobile-web-app-capable" content="yes">
     <meta name="apple-mobile-web-app-status-bar-style" content="black">
     <script src="/vipsubscribe/js/rem.js?v={{Msg "seo" "version"}}"></script>
@@ -80,7 +80,7 @@
     .j-button-confirm:nth-child(1){
       margin-right: .16rem;
     }
-    
+
     </style>
 </head>
 
@@ -105,7 +105,7 @@
         </div> -->
       </div>
     </div>
-    <ul class="vip-body" id="vip-body">
+    <ul class="vip-body" id="vip-body" v-cloak>
         <li class="sub-box">
             <a data-href="/front/vipsubscribe/introducePage?type=renew" class="banner-ad-box update" style="display: none">
                 <span>限时续费,3个月起,续多久送多久!</span>
@@ -360,7 +360,7 @@
     </div>
     <!-- 升级 -->
     <!-- 升级 -->
-    <div class="update_renew" v-show="vSwitch === 'v'">
+    <div class="update_renew" style="display: none">
       <div class="update-tips" data-update-tips>因系统升级,已购买用户可选择原套餐续费,或升级到新版本享受更多权益。</div>
       <div class="footer-button-group j-button-group">
         <button class="j-button-confirm" data-bind-renew data-cl-event="c_wx_buy_buttonclick">续费</button>