Prechádzať zdrojové kódy

Merge branch 'dev4.6.2.1' of http://192.168.3.207:8080/qmx/jy into dev4.6.2.1

wangshan 3 rokov pred
rodič
commit
362d9c4779

+ 8 - 11
src/jfw/modules/app/src/web/staticres/jyapp/big-member/js/ent_portrait.js

@@ -331,7 +331,6 @@ var vNode = {
     // 获取画像信息
     getEntPortrait: function (callback) {
       var storageSet = JSON.parse(sessionStorage.getItem('winner_high_set'))
-      // if (!storageSet) return
       var _this = this
       var data = {
         entId: _this.entInfo.id
@@ -354,11 +353,6 @@ var vNode = {
       } else {
         urls = '/bigmember/portrait/subVipPortrait/winner'
       }
-      // if (_this.powerInfo.memberStatus <= 0 || _this.svip || _this.isVip) {
-      //   urls = '/bigmember/portrait/subVipPortrait/winner'
-      // } else {
-      //   urls = '/bigmember/portrait/winner/getData'
-      // }
       _this.getEntPortraitInfoTimes++
       $.ajax({
         type: 'POST',
@@ -388,7 +382,7 @@ var vNode = {
               }
             }
           } else {
-            _this.loading.clear()
+            _this.$toast(res.error_msg)
             _this.show.yearData = false
             _this.show.monthData = false
             _this.show.areaData = false
@@ -399,6 +393,7 @@ var vNode = {
         },
         error: function (error) {
           // _this.$toast('请求失败')
+          _this.loading.clear()
         }
       })
     },
@@ -448,7 +443,6 @@ var vNode = {
     // 获取项目动态
     getProjectNews: function () {
       var storageSet = JSON.parse(sessionStorage.getItem('winner_high_set'))
-      // if (!storageSet) return
       var _this = this
       var data = {
         entId: _this.entInfo.id,
@@ -477,13 +471,13 @@ var vNode = {
               _this.topProject.list = res.data.list
             }
           } else {
-            // _this.$toast(res.error_msg)
-            _this.loading.clear()
+            _this.$toast(res.error_msg)
             _this.show.dt = false
           }
         },
         error: function (error) {
           // _this.$toast('请求失败')
+          _this.loading.clear()
         }
       })
     },
@@ -513,11 +507,12 @@ var vNode = {
             }
           } else {
             // 不显示提示信息
-            // _this.$toast(res.error_msg)
+            _this.$toast(res.error_msg)
           }
         },
         error: function (error) {
           console.log(error)
+          _this.loading.clear()
         }
       })
     },
@@ -633,6 +628,7 @@ var vNode = {
         },
         error: function (error) {
           console.log(error)
+          _this.loading.clear()
         }
       })
     },
@@ -669,6 +665,7 @@ var vNode = {
         },
         error: function (error) {
           console.log(error)
+          loading.clear()
         }
       })
     },

+ 8 - 3
src/jfw/modules/app/src/web/staticres/jyapp/js/searchindex.js

@@ -445,8 +445,9 @@ var SuperSearch = {
       // --> 已设置10组关键词,订阅失败提示
       // --> 小于10组
       //    --> 历史老用户-未选择区域-提示更新
-      //           --> -选择区域-关键词列表
-      //    --> 新用户-未选择区域-关键词列表
+      //           --> 选择区域-关键词列表
+      //    --> 新用户-未选择区域-订阅页面
+      //           --> 选择区域-关键词列表
 
       var isOldUser = false
       var nowKeyLength = 8
@@ -536,8 +537,12 @@ var SuperSearch = {
           });
           if(rFlag){
             SuperSearch.setSessionStorage();
+            var goHref = "/jyapp/vipsubscribe/toSetKeyWordPage";
+            if (!isSelectArea) {
+              goHref = "/jyapp/vipsubscribe/toSubVipSetPage";
+            }
             setTimeout(function(){
-              window.location.href = "/jyapp/vipsubscribe/toSetKeyWordPage";
+              window.location.href = goHref
             },100);
           }
         }

+ 0 - 1
src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/js/vip_index_new.js

@@ -85,7 +85,6 @@ var subNode = new Vue({
                         }
                         this.linkObj = {
                             area: '/jyapp/big/page/set_area?callback=setting_save',
-                            // area: '/jyapp/areaPack/set_area',
                             industry: '/jyapp/big/page/set_cate?header=采购单位类型&callback=setting_save',
                             keyword: '/jyapp/vipsubscribe/toSetKeyWordPage',
                             infotype: '/jyapp/big/page/set_infotype?callback=setting_save',

+ 34 - 29
src/jfw/modules/app/src/web/templates/commonPay/paySuccess.html

@@ -138,35 +138,7 @@
                 }
                 $('.info-box .info-item').text('数据流量包:+' + allTotal)
             } else if (productType === 'areaPack') {
-                // https://showdoc.jydev.jianyu360.com/web/#/67?page_id=891
-                // {
-                //     num: 0, // 购买的数量 -1全国
-                //     ordertype: 1, // 1正常购买 2升级 3续费
-                //     cycleunit: 0, // 日期单位 1月 2季 3年
-                //     OldNum: 0, // 升级前购买的省份数量
-                // }
-                var titleMap = {
-                    1: '购买',
-                    2: '升级',
-                    3: '续费'
-                }
-                setHeaderTitle(titleMap[orderFilter.ordertype] + $('.header-title').text())
-                var cycleType = ' 个月'
-                if (orderFilter.cycleunit == 2) {
-                    cycleType = ' 季'
-                } else if (orderFilter.cycleunit == 3) {
-                    cycleType = ' 年'
-                }
-
-                var html = `${titleMap[orderFilter.ordertype]}省份数量:<span class="highlight-text">${orderFilter.num === -1 ? '全国' : orderFilter.num}</span>${orderFilter.num === -1 ? '' : ' 个省'}`
-                html += `&nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;`
-                html += `订阅周期:`
-                if (orderFilter.ordertype == 2) {
-                    html += `不延期`
-                } else {
-                    html += `<span class="highlight-text">1</span>${ cycleType }`
-                }
-                $('.info-box .info-item').html(html)
+                setAreaPackInfo(orderFilter)
             }
         }
 
@@ -198,6 +170,39 @@
         }
     })
 
+    function setAreaPackInfo (orderFilter) {
+        // https://showdoc.jydev.jianyu360.com/web/#/67?page_id=891
+        // {
+        //     num: 0, // 购买的数量 -1全国
+        //     ordertype: 1, // 1正常购买 2升级 3续费
+        //     cycleunit: 0, // 日期单位 1月 2季 3年
+        //     OldNum: 0, // 升级前购买的省份数量
+        // }
+        var titleMap = {
+            1: '购买',
+            2: '升级',
+            3: '续费'
+        }
+        setHeaderTitle(titleMap[orderFilter.ordertype] + $('.header-title').text())
+        var cycleType = ' 个月'
+        if (orderFilter.cycleunit == 2) {
+            cycleType = ' 季'
+        } else if (orderFilter.cycleunit == 3) {
+            cycleType = ' 年'
+        }
+
+        var upgradeText = orderFilter.num === -1 ? '全国' : (orderFilter.num - orderFilter.OldNum)
+        var html = `${titleMap[orderFilter.ordertype]}省份数量:<span class="highlight-text">${upgradeText}</span>${orderFilter.num === -1 ? '' : ' 个省'}`
+        html += `&nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;`
+        html += `订阅周期:`
+        if (orderFilter.ordertype == 2) {
+            html += `不延期`
+        } else {
+            html += `<span class="highlight-text">1</span>${ cycleType }`
+        }
+        $('.info-box .info-item').html(html)
+    }
+
     function setHeaderTitle (title) {
         if (!title) return
         document.title = title

+ 7 - 9
src/web/staticres/common-module/collection/js/ent_portrait.js

@@ -393,7 +393,7 @@ var vNode = {
               }
             }
           } else {
-            _this.loading.clear()
+            _this.$toast(res.error_msg)
             _this.show.yearData = false
             _this.show.monthData = false
             _this.show.areaData = false
@@ -403,7 +403,7 @@ var vNode = {
           }
         },
         error: function (error) {
-          // _this.$toast('请求失败')
+          _this.loading.clear()
         }
       })
     },
@@ -450,7 +450,6 @@ var vNode = {
     // 获取项目动态
     getProjectNews: function () {
       var storageSet = JSON.parse(sessionStorage.getItem('winner_high_set'))
-      // if (!storageSet) return
       var _this = this
       var data = {
         entId: _this.entInfo.id,
@@ -479,13 +478,12 @@ var vNode = {
               _this.topProject.list = res.data.list
             }
           } else {
-            // _this.$toast(res.error_msg)
-            _this.loading.clear()
+            _this.$toast(res.error_msg)
             _this.show.dt = false
           }
         },
         error: function (error) {
-          // _this.$toast('请求失败')
+          _this.loading.clear()
         }
       })
     },
@@ -522,11 +520,11 @@ var vNode = {
             }
           } else {
             // 不显示提示信息
-            // _this.$toast(res.error_msg)
+            _this.$toast(res.error_msg)
           }
         },
         error: function (error) {
-          console.log(error)
+          _this.loading.clear()
         }
       })
     },
@@ -641,7 +639,7 @@ var vNode = {
           }
         },
         error: function (error) {
-          console.log(error)
+          _this.loading.clear()
         }
       })
     },

+ 8 - 17
src/web/staticres/common-module/vipsubscribe/js/vip-subscribe-set-template.js

@@ -20,7 +20,7 @@ var subScribeTemplate = `
     </div>
     </li>
     <li class="body-item industry">
-    <a class="item-container" :href="linkobj.industry" @click="userNoIndustry">
+    <a class="item-container" :href="linkobj.industry" @click="userNoIndustry($event)">
       <div class="item">
         <span class="item-l">
           <span class="leading jy-icon-industry"></span>
@@ -63,7 +63,7 @@ var subScribeTemplate = `
     </a>
     </li>
     <li class="body-item info-type">
-    <a class="item-container" href="javascript:;" :thisHref="linkobj.infotype" @click="openInfoType">
+    <a class="item-container" :href="linkobj.infotype" @click="openInfoType($event)">
       <div class="item">
         <span class="item-l">
           <span class="leading jy-icon-info-type"></span>
@@ -637,23 +637,21 @@ var subComponent = {
           }]
       });
     },
-    // 用户未购买修改采购单位类型功能
     userNoIndustry: function () {
-      if (this.vSwitch !== 'f') {
-        var href = '/jyapp/vipsubscribe/toChangeIndustry?header=save'
-      } else {
+      if (this.vSwitch === 'f') {
         if (location.href.indexOf('front') !== -1) {
           var href = '/front/vipsubscribe/introducePage'
         } else {
           var href = '/jyapp/vipsubscribe/introducePage'
         }
+        this.linkobj.industry = href
       }
-      this.linkobj.industry = href
     },
     // 修改地区无次数点击事件
     userNumOver: function () {
       var _this = this
       if (this.vSwitch === 'f' && this.userAreaNum === 0) {
+        // 免费用户修改href跳转
         this.linkobj.area = 'javascript:;'
         if (this.userAreaAllNum > 0) {
           var str = `对不起,您当月修改区域的机会(${this.userAreaAllNum}次)已消耗完毕,无法再次修改~可前往升级省份订阅包增加订阅省份和修改次数`
@@ -686,8 +684,7 @@ var subComponent = {
               }
             }]
         });
-      }
-      else {
+      } else {
         // this.linkobj.area = '/jyapp/big/page/set_area?callback=setting_save'
         if (this.vSwitch === 'f') {
           if (location.href.indexOf('front') !== -1) {
@@ -714,16 +711,10 @@ var subComponent = {
       });
     },
     // 打开信息类型
-    openInfoType: function () {
+    openInfoType: function (e) {
       if (this.vSwitch === 'f') {
+        e.preventDefault()
         this.infoTypeMenu = true
-      } else {
-        if (location.href.indexOf('front') !== -1) {
-          location.href = '/front/vipsubscribe/toSetInfoTypePage'
-        } else {
-          location.href = '/jyapp/vipsubscribe/toSetInfoTypePage'
-        }
-
       }
     },
     // 重置信息类型

+ 9 - 4
src/web/staticres/js/wxSupersearch.js

@@ -429,8 +429,9 @@ var SuperSearch = {
       // --> 已设置10组关键词,订阅失败提示
       // --> 小于10组
       //    --> 历史老用户-未选择区域-提示更新
-      //           --> -选择区域-关键词列表
-      //    --> 新用户-未选择区域-关键词列表
+      //           --> 选择区域-关键词列表
+      //    --> 新用户-未选择区域-订阅页面
+      //           --> 选择区域-关键词列表
 
       var isOldUser = false
       var nowKeyLength = 8
@@ -488,7 +489,7 @@ var SuperSearch = {
           window.location.href = "/front/vipsubscribe/toSetKeyWordPage";
         }
       }else{
-      // 免费用户
+          // 免费用户
           isOldUser = !jyAddInfo.isUpgrade
           if (nowKeyLength >= 10) {
             return EasyAlert.show("您已经超过订阅<br>关键字上限");
@@ -517,7 +518,11 @@ var SuperSearch = {
         });
         if(rFlag){
             SuperSearch.setSessionStorage();
-            window.location.href = "/front/vipsubscribe/toSetKeyWordPage";
+            var goHref = "/front/vipsubscribe/toSetKeyWordPage";
+            if (!isSelectArea) {
+              goHref = "/front/vipsubscribe/toSubVipSetPage";
+            }
+            window.location.href = goHref
         }
       }
     });

+ 33 - 29
src/web/templates/weixin/commonPay/paySuccess.html

@@ -111,35 +111,7 @@
                 }
                 $('.info-box .info-item').text('数据流量包:+' + allTotal)
             } else if (productType === 'areaPack') {
-                // https://showdoc.jydev.jianyu360.com/web/#/67?page_id=891
-                // {
-                //     num: 0, // 购买的数量 -1全国
-                //     ordertype: 1, // 1正常购买 2升级 3续费
-                //     cycleunit: 0, // 日期单位 1月 2季 3年
-                //     OldNum: 0, // 升级前购买的省份数量
-                // }
-                var titleMap = {
-                    1: '购买',
-                    2: '升级',
-                    3: '续费'
-                }
-                setHeaderTitle(titleMap[orderFilter.ordertype] + $('.header-title').text())
-                var cycleType = ' 个月'
-                if (orderFilter.cycleunit == 2) {
-                    cycleType = ' 季'
-                } else if (orderFilter.cycleunit == 3) {
-                    cycleType = ' 年'
-                }
-
-                var html = `${titleMap[orderFilter.ordertype]}省份数量:<span class="highlight-text">${orderFilter.num === -1 ? '全国' : orderFilter.num}</span>${orderFilter.num === -1 ? '' : ' 个省'}`
-                html += `&nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;`
-                html += `订阅周期:`
-                if (orderFilter.ordertype == 2) {
-                    html += `不延期`
-                } else {
-                    html += `<span class="highlight-text">1</span>${ cycleType }`
-                }
-                $('.info-box .info-item').html(html)
+                setAreaPackInfo(orderFilter)
             }
         }
 
@@ -165,6 +137,38 @@
         }
     })
 
+    function setAreaPackInfo (orderFilter) {
+        // https://showdoc.jydev.jianyu360.com/web/#/67?page_id=891
+        // {
+        //     num: 0, // 购买的数量 -1全国
+        //     ordertype: 1, // 1正常购买 2升级 3续费
+        //     cycleunit: 0, // 日期单位 1月 2季 3年
+        //     OldNum: 0, // 升级前购买的省份数量
+        // }
+        var titleMap = {
+            1: '购买',
+            2: '升级',
+            3: '续费'
+        }
+        setHeaderTitle(titleMap[orderFilter.ordertype] + $('.header-title').text())
+        var cycleType = ' 个月'
+        if (orderFilter.cycleunit == 2) {
+            cycleType = ' 季'
+        } else if (orderFilter.cycleunit == 3) {
+            cycleType = ' 年'
+        }
+
+        var html = `${titleMap[orderFilter.ordertype]}省份数量:<span class="highlight-text">${orderFilter.num === -1 ? '全国' : orderFilter.num}</span>${orderFilter.num === -1 ? '' : ' 个省'}`
+        html += `&nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;`
+        html += `订阅周期:`
+        if (orderFilter.ordertype == 2) {
+            html += `不延期`
+        } else {
+            html += `<span class="highlight-text">1</span>${ cycleType }`
+        }
+        $('.info-box .info-item').html(html)
+    }
+
     function setHeaderTitle (title) {
         if (!title) return
         document.title = title