瀏覽代碼

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

wangshan 5 年之前
父節點
當前提交
a371e876d0
共有 26 個文件被更改,包括 1013 次插入674 次删除
  1. 8 2
      src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/css/choose_area.css
  2. 0 1
      src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/css/choose_area_new.css
  3. 124 86
      src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/js/editArea.js
  4. 18 5
      src/jfw/modules/app/src/web/templates/vipsubscribe/choose_area.html
  5. 0 2
      src/jfw/modules/app/src/web/templates/vipsubscribe/choose_industry.html
  6. 3 5
      src/jfw/modules/app/src/web/templates/vipsubscribe/edit_city_new.html
  7. 1 1
      src/jfw/modules/app/src/web/templates/vipsubscribe/edit_subscribe.html
  8. 6 5
      src/jfw/modules/app/src/web/templates/vipsubscribe/edit_subscribe_industry.html
  9. 15 7
      src/jfw/modules/app/src/web/templates/vipsubscribe/vip_purchase.html
  10. 5 0
      src/jfw/modules/app/src/web/templates/weixin/search/mainSearch.html
  11. 37 8
      src/jfw/modules/subscribepay/src/service/commonAction.go
  12. 5 2
      src/jfw/modules/subscribepay/src/service/vipRenewUpgrade.go
  13. 8 2
      src/web/staticres/vipsubscribe/css/choose_area.css
  14. 0 1
      src/web/staticres/vipsubscribe/css/choose_area_new.css
  15. 123 85
      src/web/staticres/vipsubscribe/js/editArea.js
  16. 147 2
      src/web/templates/weixin/dataExport/dataExport_toMyOrder.html
  17. 1 1
      src/web/templates/weixin/dataExport/dataExport_toOrderDetail.html
  18. 24 9
      src/web/templates/weixin/vipsubscribe/choose_area.html
  19. 11 5
      src/web/templates/weixin/vipsubscribe/choose_area_upgrade.html
  20. 34 17
      src/web/templates/weixin/vipsubscribe/choose_industry_upgrade.html
  21. 3 5
      src/web/templates/weixin/vipsubscribe/edit_city_new.html
  22. 1 1
      src/web/templates/weixin/vipsubscribe/edit_subscribe.html
  23. 392 389
      src/web/templates/weixin/vipsubscribe/edit_subscribe_industry.html
  24. 3 4
      src/web/templates/weixin/vipsubscribe/renew_pay.html
  25. 15 8
      src/web/templates/weixin/vipsubscribe/vip_purchase.html
  26. 29 21
      src/web/templates/weixin/vipsubscribe/vip_upgrade.html

+ 8 - 2
src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/css/choose_area.css

@@ -494,16 +494,22 @@
 
 #choose_area .select-area-box .tab .province .checkbox:checked {
   border: 0;
-  background: url(../image/xuanzhong.png) no-repeat center center;
+  background: url(/jyapp/vipsubscribe/image/xuanzhong.png) no-repeat center center;
   background-size: 100% 100%;
 }
 
 #choose_area .select-area-box .tab .province .checkbox[disabled] {
   border: 0;
-  background: url(../image/active_disabled.png) no-repeat center center;
+  background: url(/jyapp/vipsubscribe/image/active_disabled.png) no-repeat center center;
   background-size: 100% 100%;
 }
 
+#choose_area .select-area-box .tab .province .checkbox.half:checked {
+  border: 0 !important;
+  background: url(/jyapp/vipsubscribe/image/banxuan.png) no-repeat center center !important;
+  background-size: cover !important;
+}
+
 #choose_area .select-area-box label::after {
   font-size: 14px;
   float: right;

+ 0 - 1
src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/css/choose_area_new.css

@@ -425,7 +425,6 @@
 }
 
 #choose_area .optional_count, #choose_area .all_area {
-  background: #fff;
   height: .88rem;
   line-height: .88rem;
   padding: 0 .3rem;

+ 124 - 86
src/jfw/modules/app/src/web/staticres/jyapp/vipsubscribe/js/editArea.js

@@ -2,21 +2,21 @@
 var areaData = {
     "data": {
         "area": {
-            "北京": [],
-            "河南": [
-                "商丘市",
-                "安阳市",
-                "新乡市",
-                "郑州市"
-            ],
-            "澳门": [],
-            "甘肃": []
+            // "北京": [],
+            // "河南": [
+            //     "洛阳市",
+            //     "驻马店市",
+            //     "周口市",
+            //     // "郑州市"
+            // ],
+            // "澳门": [],
+            // "甘肃": []
         },
         "buyset": {
-            "areacount": 4,
+            "areacount": -1,
             "buyerclasscount": 11,
             "citys": {
-                "河南": 4
+                //   "河南": 4
             }
         },
         "industry": [
@@ -37,7 +37,6 @@ var areaData = {
     "success": true
 }
 
-
 //加载数据
 function getData() {
     $DoPost("/subscribepay/editSub/getSubBuyMsg", {}, function (r) {
@@ -76,16 +75,14 @@ var obj
 
 // 改变选择结果方法
 function getResult() {
-    var data = '';
     obj = {};
-    $('.result_name').empty();
+    //$('.result_name').empty();
     $('.province').each(function () {
         let provinceText = $(this).text().trim();//省份名称
         let isChecked = $(this).children('.checkbox').is(':checked');
         let isHalf = $(this).children('.checkbox').hasClass('half');
         let arr = [];
         if (isChecked) {
-            data += provinceText + '、';
             obj[provinceText] = [];
         } else if (isHalf && !isChecked) {
             let $that = $(this);
@@ -97,13 +94,12 @@ function getResult() {
                 }
             })
             obj[$that.text().trim()] = arr
-            data += `${$that.text().trim()}(${arr.join('、')})、`
         }
     })
     $('count').html($('.checkbox:not(.other):checked').length);
-    $('.result_name').append(data.substring(0, data.length - 1));
-    //校验是否修改
-    if (theSameAs(obj)) {
+    //$('.result_name').append(getAreaClassArr_index(obj).join("、"));
+//校验是否修改
+    if (theSameAs(obj) || $.isEmptyObject(obj)) {
         $('#enter').attr("disabled", "disabled");
     } else {
         $('#enter').removeAttr("disabled");
@@ -114,7 +110,6 @@ function getResult() {
 function init() {
     let p = areaData.data.area;
     let count = areaData.data.buyset.citys;
-    var ht = '';
     // 1.渲染城市列表
     $(".select-area-box ul li:not('.index')").each(function () {
         var text = $(this).find(".province").text().trim()
@@ -128,88 +123,130 @@ function init() {
         box.html(html)
     })
     // 2.当areacount == -1时,全国为选中状态,为正数时为选中的省份数目,全国选项不显示
-    if (areaData.data.buyset.areacount == -1) {
-        // 选中全国
+    let pLength = Object.keys(areaData.data.area).length;
+    let cLength = Object.keys(areaData.data.buyset.citys).length
+    console.log(pLength, cLength)
+    if (areaData.data.buyset.areacount == -1 && pLength == 0 && cLength == 0) {
+        // 当购买的全国切选中的是全国时
         // $('.optional_count').html("可选择全部区域")
-        $('.all_area').show()
+        //$('.all_area').show()
         $('.optional_count').hide()
         $('.total').html('34')
         $('.count').html('34')
         $('.tab.whole').parent('li').show();
         $('.checkbox.other').prop('checked', true);
-        $('.checkbox:not(.other)').attr('disabled', true)
-        ht += `<span>全国</span>`
+        // $('.checkbox:not(.other)').attr('disabled',true)
+        //$('.result_name').append(`<span>全国</span>`);
+    } else if (areaData.data.buyset.areacount == -1 && pLength != 0) {
+        // 当购买的全国而没有选择全国,选择部分省市时
+        //$('.all_area').show();
+        $('.province').removeAttr('data-count');
+        $('.optional_count').hide();
+        $('.total').html('34');
+        initResult()
     } else {
-        $('.all_area').hide()
+        //$('.all_area').hide()
         $('.optional_count').show()
         $('.total').html(areaData.data.buyset.areacount)
         $('.tab.whole').parent('li').hide();
-        $('.checkbox.other').attr('disabled', true);
-        // 渲染已选择结果
-        for (const k in p) {
-            console.log(p[k], k)
-            if (p[k].length == 0) {
-                ht += k + '、';
-                $('.province').each(function () {
-                    let t = $(this).text().trim();
-                    if (k == t && p[k].length == 0) {
-                        // 如果购买的是全省,则不可点击下拉事件(不可修改城市)
-                        // $(this).parent('.tab').unbind("click").parent('li').siblings().find('.tab').unbind("click");
+        // $('.checkbox.other').attr('disabled',true);
+        initResult()
+    }
+
+}
+
+function initResult() {
+    let isAll = areaData.data.buyset.areacount;
+    let p = areaData.data.area;
+    let count = areaData.data.buyset.citys;
+    // 渲染已选择结果
+    for (const k in p) {
+        console.log(p[k], k)
+        if (p[k].length == 0) {
+            $('.province').each(function () {
+                let t = $(this).text().trim();
+                if (k == t && p[k].length == 0) {
+                    // 如果购买的是全省,则不可点击下拉事件(不可修改城市)
+                    if (isAll != -1) {
                         $(this).parent().siblings().children('.city').addClass('active').attr('disabled', true);
-                        $(this).children('.checkbox').prop('checked', true)
+                        $(this).parent('.tab').parent('li').siblings().find('.checkbox:not(.half)').parents('.tab').unbind('click')
+                    } else {
+                        $(this).parent().siblings().children('.city').addClass('active').removeAttr('disabled')
+                    }
+                    $(this).children('.checkbox').prop('checked', true)
+                }
+            })
+        } else {
+            console.log(k, p[k].length)
+            $('.city').each(function () {
+                let t = $(this).text().trim();
+                p[k].forEach(v => {
+                    // console.log(v,t)
+                    if (v == t) {
+                        let that = $(this).parents('li').find('.tab:not(.municipality)');
+                        console.log("v==t")
+                        // 如果是可修改城市的省份,则可以进行下拉展示
+                        that.bind('click', function () {
+                            slideFun($(this));
+                        })
+                        $(this).addClass('active').parent().siblings('.tab').find('input').addClass('half');
+                        return;
                     }
                 })
-            } else {
-                console.log(k, p[k])
-                ht += `${k}( ${p[k].join('、')} )、`;
-                $('.city').each(function () {
-                    let t = $(this).text().trim();
-                    p[k].forEach(v => {
-                        // console.log(v,t)
-                        if (v == t) {
-                            let that = $(this).parents('li').find('.tab:not(.municipality)');
-                            console.log("v==t")
-                            // 如果是可修改城市的省份,则可以进行下拉展示
-                            that.bind('click', function () {
-                                slideFun($(this));
-                            });
-                            $(this).addClass('active').parent().siblings('.tab').find('input').addClass('half');
-                            return;
-                        }
-                    })
-                })
-                for (const c in count) {
-                    if (p[k].length >= count[c]) {
+            })
+            for (const c in count) {
+                if (p[k].length >= count[c]) {
+                    if (isAll != -1) {
                         $('.city:not(.active)').attr('disabled', true)
+                    } else {
+                        $('.city:not(.active)').removeAttr('disabled')
                     }
                 }
             }
         }
-        // 添加可选择城市文字 和自定义属性值
+    }
+    // 添加可选择城市文字 和自定义属性值
+    if (areaData.data.buyset.areacount != -1) {
         for (const c in count) {
             $('.province').each(function () {
                 let t = $(this).text().trim();
                 if (c == t) {
                     $(this).attr("data-count", count[c]);
                     $(this).after(`<em class="optional">可选择 ${count[c]} 个市</em>`)
-                    $(this).parent().bind('click', function () {
+                    let that = $(this).parent('.tab:not(.municipality)');
+                    that.bind('click', function () {
                         slideFun($(this));
                     })
                 }
             })
         }
-        $('.result_name').append(ht.substring(0, ht.length - 1));
-        $('.count').html($('.checkbox:not(.other):checked').length)
-        //$('.city:not(.active)').attr('disabled', true)
-        // 如果选中的省份数量等于购买的省份数量,则将其他未选中的省份禁用
-        if ($('.checkbox:not(.other):checked').length == $('.total').html()) {
-            $('.checkbox:not(:checked)').attr('disabled', true)
-        }
+    }
+    //$('.result_name').append(getAreaClassArr_index(areaData.data.area).join("、"));
+    $('.count').html($('.checkbox:not(.other):checked').length)
+    // 如果选中的省份数量等于购买的省份数量,则将其他未选中的省份禁用
+    if ($('.checkbox:not(.other):checked').length == $('.total').html()) {
+        $('.checkbox:not(:checked)').attr('disabled', true);
     }
     $('#enter').attr("disabled", "disabled");
 }
 
 $(function () {
+    // 省下拉事件
+    $('.tab:not(.municipality)').on('click', function () {
+        if ($(this).next('.tab_content:not(:animated)').css("display") == "block") {
+            $(this).children().children('i').css({
+                "display": "inline-block",
+                "transform": "rotate(0)"
+            })
+        } else {
+            $(this).children().children('i').css({
+                "display": "inline-block",
+                "transform": "rotate(-180deg)"
+            })
+        }
+        $(this).toggleClass('selected').next('.tab_content:not(:animated)').slideToggle(500)
+        $(this).parent().siblings().children('.tab').removeClass('selected');
+    });
     getData();
     // 初始化
     init();
@@ -219,25 +256,21 @@ $(function () {
         let isChecked = $(this).is(':checked');
         if (isChecked) {
             $('.count').html('34')
-            $('.checkbox:not(.other)').prop('checked', false).attr('disabled', true).removeClass('half')
-            $('.city').removeClass('active').attr('disabled', true)
-            $('.tab').unbind("click").siblings().slideUp()
+            $('.checkbox:not(.other)').prop('checked', false).removeClass('half')
+            $('.city').removeClass('active');
+            $('.tab_content').slideUp()
             getResult()
         } else {
-            // $('.count').html($('.checkbox:not(.other):checked').length)
             $('.checkbox:not(.other)').removeAttr('disabled')
             $('.city').removeAttr('disabled')
-            $('.tab:not(.municipality)').on('click', function () {
-                slideFun($(this));
-            });
             getResult()
         }
     })
     // 2.点击非全国按钮onchange事件;
     $('.checkbox:not(.other)').on('change', function () {
+        $('.checkbox.other').prop('checked', false);
         let checkedLength = $('.checkbox:checked').length;
         let totalLength = $('.total').text();
-        // console.log(checkedLength,totalLength)
         $('.count').html(checkedLength)
         if (checkedLength < totalLength) {
             $('.checkbox:not(.other)').removeAttr('disabled')
@@ -247,10 +280,14 @@ $(function () {
             getResult()
         }
         if ($(this).is(':checked')) {
-            $(this).prop('checked', true).removeClass('half').parent().parent().siblings().find('.city').addClass('active').attr('disabled', true)
+            if (areaData.data.buyset.areacount != -1) {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active').attr('disabled', true);
+            } else {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active');
+            }
             getResult()
         } else {
-            $(this).prop('checked', false).removeClass('half').parent().parent().siblings().find('.city').removeClass('active').removeAttr('disabled')
+            $(this).prop('checked', false).removeClass('half').parent().parent().siblings().find('.city').removeClass('active').removeAttr('disabled');
             getResult()
         }
 
@@ -259,10 +296,11 @@ $(function () {
     $('.checkbox.half').on('change', function () {
         console.log($(this).is(':checked'))
         if ($(this).is(':checked')) {
-            $(this).prop('checked', true).removeClass('half');
-            $(this).removeClass('half').parent().parent().siblings().find('.city').addClass('active').attr('disabled', true);
-            $(this).parent().parent().siblings().children('.city').addClass('active');
-            //$(this).parent().siblings('.optional').hide();
+            if (areaData.data.buyset.areacount != -1) {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active').attr('disabled', true);
+            } else {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active');
+            }
             getResult()
         } else {
             $(this).prop('checked', false);
@@ -274,10 +312,10 @@ $(function () {
     // 4.点击城市按钮触发的事件
     $('.tab_content').on('click', '.city', function () {
         let count = $(this).parent().siblings().find('.province').attr('data-count');
-        $(this).toggleClass('active')
+        $(this).toggleClass('active');
+        $('.checkbox.other').prop('checked', false);
         var isActive = $(this).parent().find('.city.active').length
         let cityLength = $(this).parent().find('.city').length
-
         if (isActive === cityLength) {//当选中的城市数量等于该省下所有城市总数时,即为全选
             var oInput = $(this).parents('li').find('input.checkbox')
             oInput.removeClass('half').prop('checked', true)
@@ -316,7 +354,7 @@ $(function () {
     // 取消按钮事件 返回上一页
     $('#cancel').click(function () {
         // window.history.go(-1)
-        $('.result_name').empty()
+        //$('.result_name').empty()
         $('.checkbox').prop('checked', false).removeAttr('disabled');
         $('.city').removeClass('active');
         $('.tab_content').slideUp();
@@ -331,7 +369,7 @@ $(function () {
             "value": JSON.stringify(obj)
         }, function (r) {
             if (r.success) {
-                window.location.replace('/jyapp/vipsubscribe/submitEditSubFinish');
+                window.location.replace('/front/vipsubscribe/submitEditSubFinish');
             }
             $('#enter').removeAttr("disabled");
         }, false);

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

@@ -466,7 +466,7 @@
                         $(dom).addClass('active').attr('disabled', !canClick).parents().siblings('.tab')
                             .addClass('selected').children('.province').children('.checkbox').attr({
                             "checked": true
-                        })
+                        }).addClass('half');
                     }
                 })
             })
@@ -475,6 +475,7 @@
             //如果选中所有,则转为全国
             if ($(".city").length == $(".city.active").length) {
                 $(".checkbox.other").trigger("click");
+                $(".checkbox").removeClass("half");
                 return
             }
             var tmpSelect = {};
@@ -680,12 +681,19 @@
                     $(".province input").prop('checked', false);
                     $(".city").removeClass('active');
                     $(this).prop('checked', true);
+                    $(".checkbox").removeClass("half");
                 } else {
                     $(".checkbox.other").prop('checked', false);
-                    if ($(this).is(':checked') == false) {
-                        $(this).parent().parent().siblings('.tab_content').children('.city').removeClass('active');
-                        if ($(".province .checkbox:checked").length == 0) {//若没有省份被选中 则选中全国
-                            $(".checkbox.other").prop('checked', true);
+                    if (!$(this).is(':checked')) {
+                        if ($(this).hasClass("half")) {//判断当前是否是半选
+                            $(this).prop("checked", true).removeClass("half");
+                            $(this).parent().parent().siblings('.tab_content').children('.city').addClass('active');
+                        } else {
+                            $(this).parent().parent().siblings('.tab_content').children('.city').removeClass('active');
+                            if ($(".province .checkbox:checked").length == 0) {//若没有省份被选中 则选中全国
+                                $(".checkbox.other").prop('checked', true);
+                                $(".checkbox").removeClass("half");
+                            }
                         }
                     } else {
                         $(this).parent().parent().siblings('.tab_content').children('.city').addClass('active');
@@ -703,6 +711,11 @@
                     var input = $(this).parents('li').find('input.checkbox')
                     window.input = input
                     input.prop('checked', true)
+                    if (isActive != $(this).parent().find('.city').length) {//是否全选
+                        $(this).parent('div').siblings('.tab').find('.province .checkbox').addClass('half');
+                    } else {
+                        $(this).parent('div').siblings('.tab').find('.province .checkbox').removeClass('half');
+                    }
                 } else {
                     $(this).parent('div').siblings('.tab').children().children('.checkbox').prop(
                         'checked', false)

+ 0 - 2
src/jfw/modules/app/src/web/templates/vipsubscribe/choose_industry.html

@@ -318,8 +318,6 @@
             // 除全部行业外所有按钮都被选中了
             $('#all button').trigger('click');
         }
-        //调整高度
-        $(".select-area-box .list").css("margin-top", $(".result").height() + 20);
     }
 
     function showSelect(arr, canclick) {

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

@@ -35,13 +35,11 @@
 </div>
 <div class="app-layout-content-b">
     <div id="choose_area">
-        <p class="all_area" style="display: none;"> 可选择全部区域</p>
+        <!--<p class="all_area" style="display: none;"> 可选择全部区域</p>-->
         <p class="optional_count"> 可选择省数量:<em class="count"></em> / <span class="total"></span></p>
-        <div class="result">
-            <!-- 首次购买 显示"已选择" -----  升级订阅显示"已新增" -->
-
+        <!--<div class="result">
             <p>已选择:<span class="result_name"></span></p>
-        </div>
+        </div>-->
         <div class="form">
             <div class="select-area-box" style="padding-bottom: 0;">
                 <ul class="area-list">

+ 1 - 1
src/jfw/modules/app/src/web/templates/vipsubscribe/edit_subscribe.html

@@ -103,7 +103,7 @@
 
             //行业展示                 
             if (this.reqData.buyset.buyerclasscount === -1) {
-                $(".edit_item.industry .item_bottom").text("已购买全");
+                $(".edit_item.industry .item_bottom").text("已购买全行业");
             } else {
                 $(".edit_item.industry .item_bottom").text("已购买" + this.reqData.buyset.buyerclasscount + "个行业");
             }

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

@@ -22,11 +22,12 @@
 </div>
 <div class="app-layout-content-b">
     <main class="choose_industry main">
-        <p class="optional_count"> 可选择行业数量: <em class="count"></em> / <span class="total"></span></p>
-        <div class="result" style="display: block;">
+        <p class="optional_count" style="background: rgba(245,244,249,1);"> 可选择行业数量: <em class="count"></em> / <span
+                    class="total"></span></p>
+        <!--<div class="result" style="display: block;">
             <span class="label">已选择:</span>
             <span class="result_name">全部行业</span>
-        </div>
+        </div>-->
         <div class="form">
             <div class="select-area-box">
                 <ul class="list">
@@ -278,7 +279,7 @@
         showData: function () {
             this.selectlast = this.reqData.industry;
 
-            $('.result .result_name').html(this.reqData.industry.join('、'));
+            //$('.result .result_name').html(this.reqData.industry.join('、'));
 
             $('.industry_item').each(function () {
                 let text = $(this).text();
@@ -394,7 +395,7 @@
             }
             this.reqData.industry = selectedArr;
             var selectedStr = selectedArr.join('、')
-            $('.result .result_name').text(selectedStr)
+            //$('.result .result_name').text(selectedStr)
             if (this.noChange(this.reqData.industry, EditIndustry.selectlast) || this.reqData.industry.length == 0) {
                 $('#enter').attr('disabled', 'disabled');
             } else {

+ 15 - 7
src/jfw/modules/app/src/web/templates/vipsubscribe/vip_purchase.html

@@ -350,9 +350,9 @@
                 }
             }
 
-            if (!$.isEmptyObject(data) && !this.areaSelect["一个省"]) {
+            /*if (!$.isEmptyObject(data) && !this.areaSelect["一个省"]) {
                 $(".choose_area").val(provinceArr.join(" ") + " " + cityArr.join(" "));
-            }
+            }*/
 
             if (!$.isEmptyObject(this.areaSelect) && !this.areaSelect["全国"] && !this.areaSelect["一个省"]) { //选择有行业信息 且不是全国
                 var tipTxt = "已选择 ";
@@ -361,7 +361,12 @@
                     if (provinceArr.length > 0) tipTxt += "、";
                     tipTxt += cityArr.length + " 个地市";
                 }
-                $(".add_tips.area").text(tipTxt).css("display", "");
+                $(".choose_area").val(tipTxt);
+                //$(".add_tips.area").text(tipTxt).css("display", "");
+            }else if(!$.isEmptyObject(this.areaSelect) && this.areaSelect["全国"] ){
+                $(".choose_area").val("全国");
+            }else {
+                $(".choose_area").val("");
             }
         },
         showPrice: function () {
@@ -386,12 +391,15 @@
         },
         showIndustry: function () {
             let data = this.industrySelect;
-            if (data.length > 0 && data[0] != "一个行业") {
+            /*if (data.length > 0 && data[0] != "一个行业") {
                 $(".choose_industry").val(data.join(" "));
-            }
+            }*/
             if (this.industrySelect.length > 0 && this.industrySelect[0] != "全部行业" && this.industrySelect[0] != "一个行业") { //选择有行业信息
-                var tipTxt = "已选择 ";
-                $(".add_tips.industry").text(tipTxt + this.industrySelect.length + " 个行业").css("display", "");
+                $(".choose_industry").val("已选择 " + this.industrySelect.length + " 个行业");
+            }else if(this.industrySelect.length > 0 && this.industrySelect[0] == "全部行业"){
+                $(".choose_industry").val("全部行业");
+            }else{
+                $(".choose_industry").val("");
             }
         },
         showTime: function () {

+ 5 - 0
src/jfw/modules/app/src/web/templates/weixin/search/mainSearch.html

@@ -780,7 +780,12 @@
 </script>
 </div>
 {{end}}
+<script src="/jyapp/js/fastclick.js?v={{Msg "seo" "version"}}"></script>
 <script type="text/javascript">
+	$(function() {
+	    // 解决ios系统click 事件300毫秒的延迟
+	    FastClick.attach(document.body);
+	});
  	sessionStorage.removeItem("readClause");
 	if(sessionStorage.onceTipUpdate != "1"){
 		localStorage.removeItem("onceTipUpdate");

+ 37 - 8
src/jfw/modules/subscribepay/src/service/commonAction.go

@@ -10,6 +10,8 @@ import (
 	"time"
 	"util"
 
+	"gopkg.in/mgo.v2/bson"
+
 	"github.com/go-xweb/xweb"
 )
 
@@ -35,20 +37,47 @@ func (d *CommonAction) ApplyInvoice() error {
 	queryMap := map[string]interface{}{
 		"order_code": order_code,
 	}
+	my_email, product := "", ""
+	product_type := util.Mysql.FindOne("dataexport_order", queryMap, "product_type", "")
+	if product_type != nil {
+		product = qutil.ObjToString((*product_type)["product_type"])
+	}
+	if product == "VIP订阅" {
+		//获取开发票时 用户所绑定的邮箱 user--s_myemail
+		email, _ := util.MQFW.FindOneByField("user", bson.M{"_id": bson.ObjectIdHex(qutil.ObjToString(d.GetSession("userId")))}, `{"s_myemail":1}`)
+		if len(*email) > 0 {
+			my_email = qutil.ObjToString((*email)["s_myemail"])
+		}
+	}
+	log.Println("my_email:", my_email)
+	log.Println("product:", product)
 	if applyBill_type == "个人" {
 		applyBill_status = 1
-		updateBl = util.Mysql.Update("dataexport_order", queryMap, map[string]interface{}{"applyBill_status": applyBill_status})
-
+		if product == "VIP订阅" && my_email != "" {
+			updateBl = util.Mysql.Update("dataexport_order", queryMap, map[string]interface{}{"applyBill_status": applyBill_status, "user_mail": my_email})
+		} else {
+			updateBl = util.Mysql.Update("dataexport_order", queryMap, map[string]interface{}{"applyBill_status": applyBill_status})
+		}
 	} else if applyBill_type == "单位" {
 		applyBill_status = 1                                 //状态
 		applyBill_company = d.GetString("applyBill_company") //公司名
 		applyBill_taxnum = d.GetString("applyBill_taxnum")   //纳税人识别号
-		updateBl = util.Mysql.Update("dataexport_order", queryMap, map[string]interface{}{
-			"applyBill_company": applyBill_company,
-			"applyBill_taxnum":  applyBill_taxnum,
-			"applyBill_status":  applyBill_status,
-			"applyBill_type":    1,
-		}) //修改操作
+		if product == "VIP订阅" && my_email != "" {
+			updateBl = util.Mysql.Update("dataexport_order", queryMap, map[string]interface{}{
+				"applyBill_company": applyBill_company,
+				"applyBill_taxnum":  applyBill_taxnum,
+				"applyBill_status":  applyBill_status,
+				"applyBill_type":    1,
+				"user_mail":         my_email,
+			}) //修改操作
+		} else {
+			updateBl = util.Mysql.Update("dataexport_order", queryMap, map[string]interface{}{
+				"applyBill_company": applyBill_company,
+				"applyBill_taxnum":  applyBill_taxnum,
+				"applyBill_status":  applyBill_status,
+				"applyBill_type":    1,
+			}) //修改操作
+		}
 	}
 	//判断条件
 	if updateBl {

+ 5 - 2
src/jfw/modules/subscribepay/src/service/vipRenewUpgrade.go

@@ -187,9 +187,10 @@ func (this *RenewUpgrade) RenewUpgradeCreateOrder() {
 		//		}
 		filter := entity.VipSimpleMsg{}
 		if pay_source == "Renew" {
+			vipjy := (*res)["o_vipjy"].(map[string]interface{})
 			filter = entity.VipSimpleMsg{
-				area,
-				industry,
+				qutil.ObjToMap(vipjy["o_area"]),
+				qutil.ObjArrToStringArr(vipjy["a_buyerclass"].([]interface{})),
 				nil,
 				nil,
 				date_count,
@@ -233,7 +234,9 @@ func (this *RenewUpgrade) RenewUpgradeCreateOrder() {
 					Leng := len(industry) - reduce
 					if len(industry) > 0 {
 						if industry[0] != "no" {
+							log.Println("industry", industry)
 							industry = industry[0:Leng]
+							log.Println("industry", industry)
 						}
 					}
 				}

+ 8 - 2
src/web/staticres/vipsubscribe/css/choose_area.css

@@ -494,16 +494,22 @@
 
 #choose_area .select-area-box .tab .province .checkbox:checked {
   border: 0;
-  background: url(../image/xuanzhong.png) no-repeat center center;
+  background: url(/vipsubscribe/image/xuanzhong.png) no-repeat center center;
   background-size: 100% 100%;
 }
 
 #choose_area .select-area-box .tab .province .checkbox[disabled] {
   border: 0;
-  background: url(../image/active_disabled.png) no-repeat center center;
+  background: url(/vipsubscribe/image/active_disabled.png) no-repeat center center;
   background-size: 100% 100%;
 }
 
+#choose_area .select-area-box .tab .province .checkbox.half:checked {
+  border: 0 !important;
+  background: url(/vipsubscribe/image/banxuan.png) no-repeat center center !important;
+  background-size: cover !important;
+}
+
 #choose_area .select-area-box label::after {
   font-size: 14px;
   float: right;

+ 0 - 1
src/web/staticres/vipsubscribe/css/choose_area_new.css

@@ -425,7 +425,6 @@
 }
 
 #choose_area .optional_count, #choose_area .all_area {
-  background: #fff;
   height: .88rem;
   line-height: .88rem;
   padding: 0 .3rem;

+ 123 - 85
src/web/staticres/vipsubscribe/js/editArea.js

@@ -2,21 +2,21 @@
 var areaData = {
     "data": {
         "area": {
-            "北京": [],
-            "河南": [
-                "商丘市",
-                "安阳市",
-                "新乡市",
-                "郑州市"
-            ],
-            "澳门": [],
-            "甘肃": []
+            // "北京": [],
+            // "河南": [
+            //     "洛阳市",
+            //     "驻马店市",
+            //     "周口市",
+            //     // "郑州市"
+            // ],
+            // "澳门": [],
+            // "甘肃": []
         },
         "buyset": {
-            "areacount": 4,
+            "areacount": -1,
             "buyerclasscount": 11,
             "citys": {
-                "河南": 4
+                //   "河南": 4
             }
         },
         "industry": [
@@ -37,7 +37,6 @@ var areaData = {
     "success": true
 }
 
-
 //加载数据
 function getData() {
     $DoPost("/subscribepay/editSub/getSubBuyMsg", {}, function (r) {
@@ -76,16 +75,14 @@ var obj
 
 // 改变选择结果方法
 function getResult() {
-    var data = '';
     obj = {};
-    $('.result_name').empty();
+    //$('.result_name').empty();
     $('.province').each(function () {
         let provinceText = $(this).text().trim();//省份名称
         let isChecked = $(this).children('.checkbox').is(':checked');
         let isHalf = $(this).children('.checkbox').hasClass('half');
         let arr = [];
         if (isChecked) {
-            data += provinceText + '、';
             obj[provinceText] = [];
         } else if (isHalf && !isChecked) {
             let $that = $(this);
@@ -97,13 +94,12 @@ function getResult() {
                 }
             })
             obj[$that.text().trim()] = arr
-            data += `${$that.text().trim()}(${arr.join('、')})、`
         }
     })
     $('count').html($('.checkbox:not(.other):checked').length);
-    $('.result_name').append(data.substring(0, data.length - 1));
-    //校验是否修改
-    if (theSameAs(obj)) {
+    //$('.result_name').append(getAreaClassArr_index(obj).join("、"));
+//校验是否修改
+    if (theSameAs(obj) || $.isEmptyObject(obj)) {
         $('#enter').attr("disabled", "disabled");
     } else {
         $('#enter').removeAttr("disabled");
@@ -114,7 +110,6 @@ function getResult() {
 function init() {
     let p = areaData.data.area;
     let count = areaData.data.buyset.citys;
-    var ht = '';
     // 1.渲染城市列表
     $(".select-area-box ul li:not('.index')").each(function () {
         var text = $(this).find(".province").text().trim()
@@ -128,88 +123,130 @@ function init() {
         box.html(html)
     })
     // 2.当areacount == -1时,全国为选中状态,为正数时为选中的省份数目,全国选项不显示
-    if (areaData.data.buyset.areacount == -1) {
-        // 选中全国
+    let pLength = Object.keys(areaData.data.area).length;
+    let cLength = Object.keys(areaData.data.buyset.citys).length
+    console.log(pLength, cLength)
+    if (areaData.data.buyset.areacount == -1 && pLength == 0 && cLength == 0) {
+        // 当购买的全国切选中的是全国时
         // $('.optional_count').html("可选择全部区域")
-        $('.all_area').show()
+        //$('.all_area').show()
         $('.optional_count').hide()
         $('.total').html('34')
         $('.count').html('34')
         $('.tab.whole').parent('li').show();
         $('.checkbox.other').prop('checked', true);
-        $('.checkbox:not(.other)').attr('disabled', true)
-        ht += `<span>全国</span>`
+        // $('.checkbox:not(.other)').attr('disabled',true)
+        //$('.result_name').append(`<span>全国</span>`);
+    } else if (areaData.data.buyset.areacount == -1 && pLength != 0) {
+        // 当购买的全国而没有选择全国,选择部分省市时
+        //$('.all_area').show();
+        $('.province').removeAttr('data-count');
+        $('.optional_count').hide();
+        $('.total').html('34');
+        initResult()
     } else {
-        $('.all_area').hide()
+        //$('.all_area').hide()
         $('.optional_count').show()
         $('.total').html(areaData.data.buyset.areacount)
         $('.tab.whole').parent('li').hide();
-        $('.checkbox.other').attr('disabled', true);
-        // 渲染已选择结果
-        for (const k in p) {
-            console.log(p[k], k)
-            if (p[k].length == 0) {
-                ht += k + '、';
-                $('.province').each(function () {
-                    let t = $(this).text().trim();
-                    if (k == t && p[k].length == 0) {
-                        // 如果购买的是全省,则不可点击下拉事件(不可修改城市)
-                        // $(this).parent('.tab').unbind("click").parent('li').siblings().find('.tab').unbind("click");
+        // $('.checkbox.other').attr('disabled',true);
+        initResult()
+    }
+
+}
+
+function initResult() {
+    let isAll = areaData.data.buyset.areacount;
+    let p = areaData.data.area;
+    let count = areaData.data.buyset.citys;
+    // 渲染已选择结果
+    for (const k in p) {
+        console.log(p[k], k)
+        if (p[k].length == 0) {
+            $('.province').each(function () {
+                let t = $(this).text().trim();
+                if (k == t && p[k].length == 0) {
+                    // 如果购买的是全省,则不可点击下拉事件(不可修改城市)
+                    if (isAll != -1) {
                         $(this).parent().siblings().children('.city').addClass('active').attr('disabled', true);
-                        $(this).children('.checkbox').prop('checked', true)
+                        $(this).parent('.tab').parent('li').siblings().find('.checkbox:not(.half)').parents('.tab').unbind('click')
+                    } else {
+                        $(this).parent().siblings().children('.city').addClass('active').removeAttr('disabled')
+                    }
+                    $(this).children('.checkbox').prop('checked', true)
+                }
+            })
+        } else {
+            console.log(k, p[k].length)
+            $('.city').each(function () {
+                let t = $(this).text().trim();
+                p[k].forEach(v => {
+                    // console.log(v,t)
+                    if (v == t) {
+                        let that = $(this).parents('li').find('.tab:not(.municipality)');
+                        console.log("v==t")
+                        // 如果是可修改城市的省份,则可以进行下拉展示
+                        that.bind('click', function () {
+                            slideFun($(this));
+                        })
+                        $(this).addClass('active').parent().siblings('.tab').find('input').addClass('half');
+                        return;
                     }
                 })
-            } else {
-                console.log(k, p[k])
-                ht += `${k}( ${p[k].join('、')} )、`;
-                $('.city').each(function () {
-                    let t = $(this).text().trim();
-                    p[k].forEach(v => {
-                        // console.log(v,t)
-                        if (v == t) {
-                            let that = $(this).parents('li').find('.tab:not(.municipality)');
-                            console.log("v==t")
-                            // 如果是可修改城市的省份,则可以进行下拉展示
-                            that.bind('click', function () {
-                                slideFun($(this));
-                            });
-                            $(this).addClass('active').parent().siblings('.tab').find('input').addClass('half');
-                            return;
-                        }
-                    })
-                })
-                for (const c in count) {
-                    if (p[k].length >= count[c]) {
+            })
+            for (const c in count) {
+                if (p[k].length >= count[c]) {
+                    if (isAll != -1) {
                         $('.city:not(.active)').attr('disabled', true)
+                    } else {
+                        $('.city:not(.active)').removeAttr('disabled')
                     }
                 }
             }
         }
-        // 添加可选择城市文字 和自定义属性值
+    }
+    // 添加可选择城市文字 和自定义属性值
+    if (areaData.data.buyset.areacount != -1) {
         for (const c in count) {
             $('.province').each(function () {
                 let t = $(this).text().trim();
                 if (c == t) {
                     $(this).attr("data-count", count[c]);
                     $(this).after(`<em class="optional">可选择 ${count[c]} 个市</em>`)
-                    $(this).parent().bind('click', function () {
+                    let that = $(this).parent('.tab:not(.municipality)');
+                    that.bind('click', function () {
                         slideFun($(this));
                     })
                 }
             })
         }
-        $('.result_name').append(ht.substring(0, ht.length - 1));
-        $('.count').html($('.checkbox:not(.other):checked').length)
-        //$('.city:not(.active)').attr('disabled', true)
-        // 如果选中的省份数量等于购买的省份数量,则将其他未选中的省份禁用
-        if ($('.checkbox:not(.other):checked').length == $('.total').html()) {
-            $('.checkbox:not(:checked)').attr('disabled', true)
-        }
+    }
+    //$('.result_name').append(getAreaClassArr_index(areaData.data.area).join("、"));
+    $('.count').html($('.checkbox:not(.other):checked').length)
+    // 如果选中的省份数量等于购买的省份数量,则将其他未选中的省份禁用
+    if ($('.checkbox:not(.other):checked').length == $('.total').html()) {
+        $('.checkbox:not(:checked)').attr('disabled', true);
     }
     $('#enter').attr("disabled", "disabled");
 }
 
 $(function () {
+    // 省下拉事件
+    $('.tab:not(.municipality)').on('click', function () {
+        if ($(this).next('.tab_content:not(:animated)').css("display") == "block") {
+            $(this).children().children('i').css({
+                "display": "inline-block",
+                "transform": "rotate(0)"
+            })
+        } else {
+            $(this).children().children('i').css({
+                "display": "inline-block",
+                "transform": "rotate(-180deg)"
+            })
+        }
+        $(this).toggleClass('selected').next('.tab_content:not(:animated)').slideToggle(500)
+        $(this).parent().siblings().children('.tab').removeClass('selected');
+    });
     getData();
     // 初始化
     init();
@@ -219,25 +256,21 @@ $(function () {
         let isChecked = $(this).is(':checked');
         if (isChecked) {
             $('.count').html('34')
-            $('.checkbox:not(.other)').prop('checked', false).attr('disabled', true).removeClass('half')
-            $('.city').removeClass('active').attr('disabled', true)
-            $('.tab').unbind("click").siblings().slideUp()
+            $('.checkbox:not(.other)').prop('checked', false).removeClass('half')
+            $('.city').removeClass('active');
+            $('.tab_content').slideUp()
             getResult()
         } else {
-            // $('.count').html($('.checkbox:not(.other):checked').length)
             $('.checkbox:not(.other)').removeAttr('disabled')
             $('.city').removeAttr('disabled')
-            $('.tab:not(.municipality)').on('click', function () {
-                slideFun($(this));
-            });
             getResult()
         }
     })
     // 2.点击非全国按钮onchange事件;
     $('.checkbox:not(.other)').on('change', function () {
+        $('.checkbox.other').prop('checked', false);
         let checkedLength = $('.checkbox:checked').length;
         let totalLength = $('.total').text();
-        // console.log(checkedLength,totalLength)
         $('.count').html(checkedLength)
         if (checkedLength < totalLength) {
             $('.checkbox:not(.other)').removeAttr('disabled')
@@ -247,10 +280,14 @@ $(function () {
             getResult()
         }
         if ($(this).is(':checked')) {
-            $(this).prop('checked', true).removeClass('half').parent().parent().siblings().find('.city').addClass('active').attr('disabled', true)
+            if (areaData.data.buyset.areacount != -1) {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active').attr('disabled', true);
+            } else {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active');
+            }
             getResult()
         } else {
-            $(this).prop('checked', false).removeClass('half').parent().parent().siblings().find('.city').removeClass('active').removeAttr('disabled')
+            $(this).prop('checked', false).removeClass('half').parent().parent().siblings().find('.city').removeClass('active').removeAttr('disabled');
             getResult()
         }
 
@@ -259,10 +296,11 @@ $(function () {
     $('.checkbox.half').on('change', function () {
         console.log($(this).is(':checked'))
         if ($(this).is(':checked')) {
-            $(this).prop('checked', true).removeClass('half');
-            $(this).removeClass('half').parent().parent().siblings().find('.city').addClass('active').attr('disabled', true);
-            $(this).parent().parent().siblings().children('.city').addClass('active');
-            //$(this).parent().siblings('.optional').hide();
+            if (areaData.data.buyset.areacount != -1) {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active').attr('disabled', true);
+            } else {
+                $(this).prop('checked', true).removeClass('half').parents('li').find('.city').addClass('active');
+            }
             getResult()
         } else {
             $(this).prop('checked', false);
@@ -274,10 +312,10 @@ $(function () {
     // 4.点击城市按钮触发的事件
     $('.tab_content').on('click', '.city', function () {
         let count = $(this).parent().siblings().find('.province').attr('data-count');
-        $(this).toggleClass('active')
+        $(this).toggleClass('active');
+        $('.checkbox.other').prop('checked', false);
         var isActive = $(this).parent().find('.city.active').length
         let cityLength = $(this).parent().find('.city').length
-
         if (isActive === cityLength) {//当选中的城市数量等于该省下所有城市总数时,即为全选
             var oInput = $(this).parents('li').find('input.checkbox')
             oInput.removeClass('half').prop('checked', true)
@@ -316,7 +354,7 @@ $(function () {
     // 取消按钮事件 返回上一页
     $('#cancel').click(function () {
         // window.history.go(-1)
-        $('.result_name').empty()
+        //$('.result_name').empty()
         $('.checkbox').prop('checked', false).removeAttr('disabled');
         $('.city').removeClass('active');
         $('.tab_content').slideUp();

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

@@ -11,6 +11,9 @@
    	    <script src="//cdn.bootcss.com/jquery-confirm/3.1.0/jquery-confirm.min.js"></script>
 		<script src="{{Msg "seo" "cdn"}}/wxswordfish/share.js?v={{Msg "seo" "version"}}"></script>
 		{{include "/common/weixin.html"}}
+		<script src="{{Msg "seo" "cdn"}}/vipsubscribe/js/common.js"></script>
+		<script src="{{Msg "seo" "cdn"}}/vipsubscribe/js/weui.min.js?v={{Msg "seo" "version"}}"></script>
+		<link rel="stylesheet" href="{{Msg "seo" "cdn"}}/vipsubscribe/css/weui.min.css?v={{Msg "seo" "version"}}">
 		<link rel="stylesheet" type="text/css" href="{{Msg "seo" "cdn"}}/wx_dataExport/css/base_myorder.css?v={{Msg "seo" "version"}}" />
 		<link rel="stylesheet" type="text/css" href="{{Msg "seo" "cdn"}}/wx_dataExport/iconfont/iconfont.css?v={{Msg "seo" "version"}}" />
 		<link rel="stylesheet" href="{{Msg "seo" "cdn"}}/wx_dataExport/css/order_list.css?v={{Msg "seo" "version"}}">
@@ -227,6 +230,146 @@
 			    border-radius: 0.05rem;
 			    font-size: .28rem;
 			}
+			
+			.custom-dialog .weui-animate-fade-out {
+			  -webkit-animation: d ease 0s forwards;
+			  animation: d ease 0s forwards;
+			}
+			
+			.custom-dialog .weui-dialog__hd {
+			  background: #F5F4F9;
+			  padding: .17rem 0;
+			  color: #000;
+			  font-size: .34rem;
+			  text-align: center;
+			}
+			
+			.custom-dialog .weui-dialog__bd {
+			  padding: .37rem 0;
+			  color: #1D1D1D;
+			  font-size: .32rem;
+			  text-align: center;
+			}
+			
+			.custom-dialog .weui-dialog__ft:after {
+			  border: 0;
+			}
+			
+			.custom-dialog .weui-dialog__btn:after {
+			  border: 0;
+			}
+			
+			.custom-dialog .weui-dialog__ft {
+			  display: flex;
+			  align-items: center;
+			  justify-content: center;
+			  padding-bottom: .38rem;
+			  box-sizing: border-box;
+			  text-align: center;
+			}
+			
+			.custom-dialog .weui-dialog__btn {
+			  display: block;
+			  width: 1.72rem;
+			  height: .72rem;
+			  line-height: .72rem;
+			  color: #fff;
+			  padding: 0;
+			  flex: none;
+			  text-align: center;
+			  border-radius: 3px;
+			}
+			
+			.custom-dialog .weui-dialog__btn_primary {
+			  background-color: #2CB7CA;
+			  margin-right: 1rem;
+			}
+			
+			.custom-dialog .weui-dialog__btn_default {
+			  background-color: #BFBFC3;
+			}
+			
+			/* 自定义switch按钮 */
+			.custom-switch {
+			  position: relative;
+			  width: 52px;
+			  height: 32px;
+			  border: 1px solid #dfdfdf;
+			  outline: 0;
+			  border-radius: 16px;
+			  box-sizing: border-box;
+			  background-color: #dfdfdf;
+			  -webkit-transition: background-color .1s,border .1s;
+			  transition: background-color .1s,border .1s;
+			  -webkit-appearance: none;
+			}
+			
+			.custom-switch:before {
+			  content: " ";
+			  position: absolute;
+			  top: 0;
+			  left: 0;
+			  width: 50px;
+			  height: 30px;
+			  border-radius: 15px;
+			  background-color: #fdfdfd;
+			  -webkit-transition: -webkit-transform 0.35s cubic-bezier(0.45, 1, 0.4, 1);
+			  transition: -webkit-transform 0.35s cubic-bezier(0.45, 1, 0.4, 1);
+			  transition: transform 0.35s cubic-bezier(0.45, 1, 0.4, 1);
+			  transition: transform 0.35s cubic-bezier(0.45, 1, 0.4, 1), -webkit-transform 0.35s cubic-bezier(0.45, 1, 0.4, 1);
+			}
+			
+			.custom-switch:after {
+			  content: " ";
+			  position: absolute;
+			  top: 0;
+			  left: 0;
+			  width: 30px;
+			  height: 30px;
+			  border-radius: 15px;
+			  background-color: #fff;
+			  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
+			  -webkit-transition: -webkit-transform 0.35s cubic-bezier(0.4, 0.4, 0.25, 1.35);
+			  transition: -webkit-transform 0.35s cubic-bezier(0.4, 0.4, 0.25, 1.35);
+			  transition: transform 0.35s cubic-bezier(0.4, 0.4, 0.25, 1.35);
+			  transition: transform 0.35s cubic-bezier(0.4, 0.4, 0.25, 1.35), -webkit-transform 0.35s cubic-bezier(0.4, 0.4, 0.25, 1.35);
+			}
+			
+			.custom-switch.checked {
+			  border-color: #04be02;
+			  background-color: #04be02;
+			}
+			
+			.custom-switch.checked:before {
+			  transform: scale(0);
+			}
+			
+			.custom-switch.checked:after {
+			  transform: translateX(20px);
+			}
+			
+			.custom-toast .weui-toast {
+			  font-size: .3rem;
+			  padding: 0.2rem;
+			  width: auto;
+			  max-width: 6rem;
+			  min-height: 0;
+			  height: auto;
+			  top: 50%;
+			  left: 50%;
+			  margin-left: 0;
+			  margin-top: -0.47rem;
+			  transform: translateX(-50%) translateY(-50%);
+			  z-index: 99999;
+			}
+			
+			.custom-toast .weui-icon_toast {
+			  display: none;
+			}
+			
+			.custom-toast .weui-toast__content {
+			  margin: 0;
+			}
 		</style>
 		<script>
 			var signature = {{.T.signature}};
@@ -469,6 +612,10 @@
 				sessionStorage.orderTabActive=$("ul .active").index();
 				var orderCode = $(e).parent(".card-footer").prev(".card-content").find("a").attr("eid");
 				if (pattern==1){
+					var checkOrder_bl=checkOrder()
+					if (checkOrder_bl){
+						return;
+					}
 					window.location.href="/weixin/pay/renewPayPage?orderCode="+orderCode;   
 				}else if (pattern==2){
 					window.location.href="/weixin/pay/vipsubscribe_new?orderCode="+orderCode;
@@ -652,7 +799,6 @@
 					var result = true;
 					$.post("/subscribepay/orderListDetails/myOrder",{"type":typ},function(data){
 							$(".loading_").hide();
-							console.log(data.res)
 							var list=data.res;
 							dataCache =data.res;
 							pageIndex=2;
@@ -982,7 +1128,6 @@
 	                    		orderHtml+="<a class=\"shanchu iconfont  icon-shanchu\" title=\"删除订单\" onclick=\"deleteOrder(" + id_vip +",this)\"></a>";
 	                        	iconHtml=""
 	                        	//最后一次购买完 1:试用 2:正式 -1:试用到期 -2:正式到期
-	                        	console.log(obj.lastbuy_code)
 	                        	if((vip_status=="-2")&&(obj.lastbuy_code!=undefined)){
 	                        		iconHtml+='<div class="card-footer">'
 											+'<a  onclick="renewalOrBuyAgain(2,this)" class="btn cancle">再次购买</a>'

+ 1 - 1
src/web/templates/weixin/dataExport/dataExport_toOrderDetail.html

@@ -446,7 +446,7 @@
 						</div>
 						<div class="card-content">
 							<div class="item-list">
-								<p class="ellipsis tax" id="p_publishTime">筛选日期:<span class="publishTime"></span></p>
+								<p class="ellipsis" id="p_publishTime">筛选日期:<span class="publishTime"></span></p>
 							</div>
 							<div class="item-list">
 								<label>区域:</label>

+ 24 - 9
src/web/templates/weixin/vipsubscribe/choose_area.html

@@ -443,7 +443,9 @@
         selectProvince: function (province, canClick) { //设置选中省份 province 省份
             $($('.tab .province')).each(function (index, dom) {
                 if (province == $.trim($(dom).text())) {
-                    if (province != "全国") $(".checkbox.other").attr("checked", false); //取消全国选中
+                    if (province != "全国") {
+                        $(".checkbox.other").attr("checked", false); //取消全国选中
+                    }
                     $(dom).children('.checkbox').attr({"checked": true, "disabled": !canClick});//选中此省份
                     $(dom).parents().siblings('.tab_content').find(".city").addClass("active").attr({"disabled": !canClick});
                 }
@@ -457,15 +459,16 @@
                         $(dom).addClass('active').attr('disabled', !canClick).parents().siblings('.tab')
                             .addClass('selected').children('.province').children('.checkbox').attr({
                             "checked": true
-                        })
+                        }).addClass('half');
                     }
                 })
             })
         },
-        getResult: function (changeCity,isFirst) {   /* 选中结果 */
+        getResult: function (changeCity, isFirst) {   /* 选中结果 */
             //如果选中所有,则转为全国
             if ($(".city").length == $(".city.active").length) {
                 $(".checkbox.other").trigger("click");
+                $(".checkbox").removeClass("half");
                 return
             }
             var tmpSelect = {};
@@ -566,7 +569,7 @@
                 if (selectCityMax > 2) {
                     $('.tips_btn .tips_d_text').text("已选择" + selectCityMax + "个市,建议购买“全省”").slideDown();
                 } else {
-                    if (selectProvince > 9&&!isFirst) {
+                    if (selectProvince > 9 && !isFirst) {
                         $('.tips_btn .tips_d_text').text("已选择" + selectProvince + "个省,建议购买“全国”").slideDown()
                     } else {
                         $(".tips_d_text").slideUp();
@@ -673,12 +676,19 @@
                     $(".province input").prop('checked', false);
                     $(".city").removeClass('active');
                     $(this).prop('checked', true);
+                    $(".checkbox").removeClass("half");
                 } else {
                     $(".checkbox.other").prop('checked', false);
-                    if ($(this).is(':checked') == false) {
-                        $(this).parent().parent().siblings('.tab_content').children('.city').removeClass('active');
-                        if ($(".province .checkbox:checked").length == 0) {//若没有省份被选中 则选中全国
-                            $(".checkbox.other").prop('checked', true);
+                    if (!$(this).is(':checked')) {
+                        if ($(this).hasClass("half")) {//判断当前是否是半选
+                            $(this).prop("checked", true).removeClass("half");
+                            $(this).parent().parent().siblings('.tab_content').children('.city').addClass('active');
+                        } else {
+                            $(this).parent().parent().siblings('.tab_content').children('.city').removeClass('active');
+                            if ($(".province .checkbox:checked").length == 0) {//若没有省份被选中 则选中全国
+                                $(".checkbox.other").prop('checked', true);
+                                $(".checkbox").removeClass("half");
+                            }
                         }
                     } else {
                         $(this).parent().parent().siblings('.tab_content').children('.city').addClass('active');
@@ -696,6 +706,11 @@
                     var input = $(this).parents('li').find('input.checkbox')
                     window.input = input
                     input.prop('checked', true)
+                    if (isActive != $(this).parent().find('.city').length) {//是否全选
+                        $(this).parent('div').siblings('.tab').find('.province .checkbox').addClass('half');
+                    } else {
+                        $(this).parent('div').siblings('.tab').find('.province .checkbox').removeClass('half');
+                    }
                 } else {
                     $(this).parent('div').siblings('.tab').children().children('.checkbox').prop(
                         'checked', false)
@@ -758,7 +773,7 @@
         AreaChoose.showSelected(true);//回显已选择
         /* 判断已购买的城市 在不在 全部城市里面,在,将按钮置灰,不可点击 */
 
-        AreaChoose.getResult("",true);
+        AreaChoose.getResult("", true);
         AreaChoose.inintClick();
     })
 </script>

+ 11 - 5
src/web/templates/weixin/vipsubscribe/choose_area_upgrade.html

@@ -399,9 +399,15 @@
     <script>
     	//已购买
     	var buystr = "";
+    	var areaData = {};
         $DoPost("/subscribepay/renewUpgrade/getBuyMsg", {}, function (data) {
         	if(data){
             	buystr = data.area;
+            	areaData["data"] = {
+            		"area" : data.area,
+            		"buyset" : data.buyset, 
+            	}
+            	console.log(areaData)
         	}
         }, false);
 //      console.log(buystr)
@@ -539,7 +545,7 @@
               let arr =[];
               // 判断省份下的城市是否等于选中的城市长度,相等就是全部选中
               if (length == activeLeng) {
-                  $('.tips_btn .tips_d_text.citys').slideUp()
+                  $('.tips_btn .tips_d_text.citys').hide();
                   // data.push($(this).parent('.tab_content').siblings('.tab:not(.whole)').children('.province').text().trim())
                   let province = $(this).parent('.tab_content').siblings('.tab:not(.whole)').children('.province').text().trim();
                   data.push({
@@ -591,10 +597,10 @@
                   // 判断每个省份下选中的城市长度,当大于等于4的时候 弹出"选择全省更划算的弹窗"
                   let childrenArr=[];
                   if (children.length >= 3 && !this.vipSubisTrial) {
-                      $('.tips_btn .tips_d_text.citys').text("已选择"+children.length+"个市,建议购买“全省”");
-                      $('.tips_btn .tips_d_text.citys').slideDown();
+                      $('.tips_btn .tips_d_text.citys').text("已选择"+children.length+"个市,建议购买“全省”");
+                      $('.tips_btn .tips_d_text.citys').show();
                   }else{
-                  		$('.tips_btn .tips_d_text.citys').slideUp();
+                  		$('.tips_btn .tips_d_text.citys').hide();
                   }
                   html += `${result[i].name}(`
                   for(var j = 0;j < children.length;j++){
@@ -629,7 +635,7 @@
 	            }
 	        }
           	if(provincesArr.length > 9){
-          		$('.tips_d_text.all').text("已选择"+provincesArr.length+"个省,建议购买“全国”");
+          		$('.tips_d_text.all').text("已选择"+provincesArr.length+"个省,建议购买“全国”");
           		$('.tips_d_text.all').show();
           		$('.tips_d_text.citys').hide();
           	}else{

+ 34 - 17
src/web/templates/weixin/vipsubscribe/choose_industry_upgrade.html

@@ -286,7 +286,10 @@
                 buttons.each(function(){
                     if ($(this).hasClass('active')) {
                         if($(this).attr("disabled")!="disabled"){
-                          selectedArr.push($(this).text())
+                        	if($(this).text() === "全部行业"){
+                        		
+                        	}
+                          	selectedArr.push($(this).text())
                         }
                     }
                 })
@@ -307,23 +310,29 @@
 							$(".tips_btn .btns .reset-btn").removeAttr("disabled");
 		            	}
                 	}else{
-                		let adds = buyIndustry.length + selectedArr.length
-                		$(".buyset").text("已购买:"+adds+"/"+buyset);
+                		if(selectedArr[0] === "全部行业"){
+                			$(".buyset").text("已购买:全部行业");
+                		}else{
+                			let adds = buyIndustry.length + selectedArr.length
+                			$(".buyset").text("已购买:"+buyset);
+                		}
                 	}
                 }else{
                 	if(buyset !== "全部行业"){
                 		$(".buyset").text("已购买:"+buyIndustryLen+"/"+buyset+"个行业")
                 	}else{
-                		$(".buyset").text("已购买:"+buyIndustryLen+"/"+buyset)
+                		$(".buyset").text("已购买:"+buyset)
                 	}
                 }
                 for(var i in selectedArr){
                 	if(selectedArr[i] === "全部行业"){
-                		$(".buyset").text("已购买:"+buyIndustry.length+"/"+buyset+"个行业");
-                		$(".addUpgrade").text("已新增:全部行业");
-                		$(".addUpgrade").show();
-                		$(".tips_btn .btns .save-btn").removeAttr("disabled");
-						$(".tips_btn .btns .reset-btn").removeAttr("disabled");
+                		if(buyset !== "全部行业"){
+                			$(".buyset").text("已购买:"+buyIndustry.length+"/"+buyset+"个行业");
+	                		$(".addUpgrade").text("已新增:全部行业");
+	                		$(".addUpgrade").show();
+	                		$(".tips_btn .btns .save-btn").removeAttr("disabled");
+							$(".tips_btn .btns .reset-btn").removeAttr("disabled");
+                		}
                 	}
                 }
                 // 显示隐藏优惠tips
@@ -406,7 +415,6 @@
                 findSelectedIndustry()
                 flushPrice()
             })
-
             // 重置按钮事件
             $('.reset-btn').on('click', function () {
 //            $("#all .industry_item").trigger("click");
@@ -431,6 +439,8 @@
         				selectedIndustrysArr = selectedIndustryArr;
         			}
         		}
+        		sessionStorage.buyIndustry = $(".buyset").html();
+        		sessionStorage.addIndustry = $(".addUpgrade").html();
         		sessionStorage.setItem("vipSubSelectIndustryAdd",JSON.stringify(selectedIndustrysArr));
                 sessionStorage.setItem("vipSubSelectIndustryUpgrade",JSON.stringify(selectedIndustryArr));
                 history.go(-1);
@@ -464,13 +474,19 @@
 		            	buyLen = buyIndustry.length
 		            	buyIndustryLen = buyIndustry.length;
 		            	buyset = Number(data.buyset.buyerclasscount);
-		            	console.log(buyset)
-		            	if(buyset === -1){
-		            		buyset = "全部行业";
-		            		$(".buyset").text("已购买:"+buyLen+"/"+buyset);
-		            	}else{
-		            		$(".buyset").text("已购买:"+buyLen+"/"+buyset+"个行业");
-		            	}
+		            	if(sessionStorage.buyIndustry !== undefined){
+							$(".buyset").text(sessionStorage.buyIndustry);
+						}else{
+							if(buyset === -1){
+			            		buyset = "全部行业";
+			            		$(".buyset").text("已购买:/"+buyset);
+			            	}else{
+			            		$(".buyset").text("已购买:"+buyLen+"/"+buyset+"个行业");
+			            	}
+						}
+						if(sessionStorage.addIndustry !== undefined){
+							$(".addUpgrade").text(sessionStorage.addIndustry);
+						}
                 	}
                 },false);
                 if(checkObj(buyIndustry)){
@@ -500,6 +516,7 @@
 			    }
 			    return false;
 			}
+		
         </script>
     </body>
 </html>

+ 3 - 5
src/web/templates/weixin/vipsubscribe/edit_city_new.html

@@ -27,13 +27,11 @@
 
 <body>
 <div id="choose_area">
-    <p class="all_area" style="display: none;"> 可选择全部区域</p>
+    <!--<p class="all_area" style="display: none;"> 可选择全部区域</p>-->
     <p class="optional_count"> 可选择省数量:<em class="count"></em> / <span class="total"></span></p>
-    <div class="result">
-        <!-- 首次购买 显示"已选择" -----  升级订阅显示"已新增" -->
-
+    <!--<div class="result">
         <p>已选择:<span class="result_name"></span></p>
-    </div>
+    </div>-->
     <div class="form">
         <div class="select-area-box" style="padding-bottom: 0;">
             <ul class="area-list">

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

@@ -94,7 +94,7 @@
 
             //行业展示                 
             if (this.reqData.buyset.buyerclasscount === -1) {
-                $(".edit_item.industry .item_bottom").text("已购买全");
+                $(".edit_item.industry .item_bottom").text("已购买全部行业");
             } else {
                 $(".edit_item.industry .item_bottom").text("已购买" + this.reqData.buyset.buyerclasscount + "个行业");
             }

+ 392 - 389
src/web/templates/weixin/vipsubscribe/edit_subscribe_industry.html

@@ -1,405 +1,408 @@
 <!DOCTYPE html>
 <html>
-    <head>
-        <meta charset="utf-8">
-        <title>行业选择</title>
-        <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
-        <meta 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>
-        <link rel="stylesheet" href="/vipsubscribe/css/weui.min.css?v={{Msg "seo" "version"}}">
-        <link rel="stylesheet" type="text/css" href="/vipsubscribe/css/base.css?v={{Msg "seo" "version"}}" />
-        <link rel="stylesheet" type="text/css" href="/vipsubscribe/iconfont/iconfont.css?v={{Msg "seo" "version"}}" />
-        <link rel="stylesheet" href="/vipsubscribe/css/choose_industry.css?v={{Msg "seo" "version"}}">
-    </head>
-    <body>
-        <main class="choose_industry main">
-            <p class="optional_count"> 可选择行业数量: <em class="count"></em> / <span class="total"></span></p>
-            <div class="result"  style="display: block;">
-                <span class="label">已选择:</span>
-                <span class="result_name">全部行业</span>
-            </div>
-            <div class="form">
-                <div class="select-area-box">
-                    <ul class="list">
-                        <li class="list_item" id="all" style="display:none">
-                            <div class="item_label"></div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">全部行业</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="A">
-                            <div class="item_label">A</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">安监</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="B">
-                            <div class="item_label">B</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">保监</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="C">
-                            <div class="item_label">C</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">财政</button>
-                                <button class="industry_item">传媒</button>
-                                <button class="industry_item">城管</button>
-                                <button class="industry_item">采矿业</button>
-                                <button class="industry_item">出版广电</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="D">
-                            <div class="item_label">D</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">档案</button>
-                                <button class="industry_item">地震</button>
-                                <button class="industry_item">党委办</button>
-                                <button class="industry_item">电信行业</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="F">
-                            <div class="item_label">F</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">法院</button>
-                                <button class="industry_item">发改</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="G">
-                            <div class="item_label">G</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">工商</button>
-                                <button class="industry_item">工信</button>
-                                <button class="industry_item">国土</button>
-                                <button class="industry_item">公安</button>
-                                <button class="industry_item">国资委</button>
-                                <button class="industry_item">公共资源交易</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="H">
-                            <div class="item_label">H</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">环保</button>
-                                <button class="industry_item">海关</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="J">
-                            <div class="item_label">J</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">教育</button>
-                                <button class="industry_item">军队</button>
-                                <button class="industry_item">交通</button>
-                                <button class="industry_item">纪委</button>
-                                <button class="industry_item">金融业</button>
-                                <button class="industry_item">建筑业</button>
-                                <button class="industry_item">检察院</button>
-                                <button class="industry_item">机关事务</button>
-                            </div>
-                        </li>
-                        <li class="list_item"  id="K">
-                            <div class="item_label">K</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">科技</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="L">
-                            <div class="item_label">L</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">林业</button>
-                                <button class="industry_item">旅游</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="M">
-                            <div class="item_label">M</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">民政</button>
-                                <button class="industry_item">民宗</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="N">
-                            <div class="item_label">N</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">农业</button>
-                                <button class="industry_item">能源化工</button>
-                                <button class="industry_item">农林牧渔</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="P">
-                            <div class="item_label">P</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">批发零售</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="Q">
-                            <div class="item_label">Q</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">气象</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="R">
-                            <div class="item_label">R</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">人行</button>
-                                <button class="industry_item">人社</button>
-                                <button class="industry_item">人大</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="S">
-                            <div class="item_label">S</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">食药</button>
-                                <button class="industry_item">税务</button>
-                                <button class="industry_item">水利</button>
-                                <button class="industry_item">市政</button>
-                                <button class="industry_item">审计</button>
-                                <button class="industry_item">商务</button>
-                                <button class="industry_item">司法</button>
-                                <button class="industry_item">社会团体</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="T">
-                            <div class="item_label">T</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">统计</button>
-                                <button class="industry_item">统战</button>
-                                <button class="industry_item">体育</button>
-                            </div>
-                        </li>                    
-                        <li class="list_item" id="W">
-                            <div class="item_label">W</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">文化</button>
-                                <button class="industry_item">卫生</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="X">
-                            <div class="item_label">X</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">学校</button>
-                                <button class="industry_item">宣传</button>
-                                <button class="industry_item">信息技术</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="Y">
-                            <div class="item_label">Y</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">医疗</button>
-                                <button class="industry_item">银监</button>
-                                <button class="industry_item">运输物流</button>
-                            </div>
-                        </li>
-                        <li class="list_item" id="Z">
-                            <div class="item_label">Z</div>
-                            <div class="item_industry_list">
-                                <button class="industry_item">质监</button>
-                                <button class="industry_item">组织</button>
-                                <button class="industry_item">政协</button>
-                                <button class="industry_item">住建</button>
-                                <button class="industry_item">证监</button>
-                                <button class="industry_item">政府办</button>
-                                <button class="industry_item">制造业</button>
-                                <button class="industry_item">政务中心</button>
-                                <button class="industry_item">住宿餐饮</button>
-                            </div>
-                        </li>
-                    </ul>
-                </div>
-            </div>
-            <div class="slide">
-                <a href="javascript:;">#</a>
-                <a href="javascript:;">A</a>
-                <a href="javascript:;">B</a>
-                <a href="javascript:;">C</a>
-                <a href="javascript:;">D</a>
-                <a href="javascript:;">F</a>
-                <a href="javascript:;">G</a>
-                <a href="javascript:;">H</a>
-                <a href="javascript:;">J</a>
-                <a href="javascript:;">K</a>
-                <a href="javascript:;">L</a>
-                <a href="javascript:;">M</a>
-                <a href="javascript:;">N</a>
-                <a href="javascript:;">P</a>
-                <a href="javascript:;">Q</a>
-                <a href="javascript:;">R</a>
-                <a href="javascript:;">S</a>
-                <a href="javascript:;">T</a>
-                <a href="javascript:;">W</a>
-                <a href="javascript:;">X</a>
-                <a href="javascript:;">Y</a>
-                <a href="javascript:;">Z</a>
-            </div>
-            <!-- <div class="bottom_button">
-                <button class="reset-btn left_btn" disabled>重置</button>
-                <button class="save-btn right_btn" disabled>确认</button>
-            </div> -->
-            <div class="tips_btn">
-                <div class="btns">
-                    <button class="reset-btn" id="cancel">取消</button>
-                    <button disabled class="save-btn" id="enter">确认修改</button>
-                </div>
-            </div>
-        </main>
-        <script src="/vipsubscribe/js/jquery-2.1.4.js?v={{Msg "seo" "version"}}"></script>
-        <script src="/vipsubscribe/js/weui.min.js?v={{Msg "seo" "version"}}"></script>
-        <script src="/vipsubscribe/js/common.js?v={{Msg "seo" "version"}}"></script>
-        <script>
+<head>
+    <meta charset="utf-8">
+    <title>行业选择</title>
+    <meta name="viewport"
+          content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
+    <meta 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>
+    <link rel="stylesheet" href="/vipsubscribe/css/weui.min.css?v={{Msg "seo" "version"}}">
+    <link rel="stylesheet" type="text/css" href="/vipsubscribe/css/base.css?v={{Msg "seo" "version"}}"/>
+    <link rel="stylesheet" type="text/css" href="/vipsubscribe/iconfont/iconfont.css?v={{Msg "seo" "version"}}"/>
+    <link rel="stylesheet" href="/vipsubscribe/css/choose_industry.css?v={{Msg "seo" "version"}}">
+</head>
+<body>
+<main class="choose_industry main">
+    <p class="optional_count" style="background: rgba(245,244,249,1);"> 可选择行业数量: <em class="count"></em> / <span class="total"></span></p>
+    <!--<div class="result" style="display: block;">
+        <span class="label">已选择:</span>
+        <span class="result_name">全部行业</span>
+    </div>-->
+    <div class="form">
+        <div class="select-area-box">
+            <ul class="list">
+                <li class="list_item" id="all" style="display:none">
+                    <div class="item_label"></div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">全部行业</button>
+                    </div>
+                </li>
+                <li class="list_item" id="A">
+                    <div class="item_label">A</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">安监</button>
+                    </div>
+                </li>
+                <li class="list_item" id="B">
+                    <div class="item_label">B</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">保监</button>
+                    </div>
+                </li>
+                <li class="list_item" id="C">
+                    <div class="item_label">C</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">财政</button>
+                        <button class="industry_item">传媒</button>
+                        <button class="industry_item">城管</button>
+                        <button class="industry_item">采矿业</button>
+                        <button class="industry_item">出版广电</button>
+                    </div>
+                </li>
+                <li class="list_item" id="D">
+                    <div class="item_label">D</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">档案</button>
+                        <button class="industry_item">地震</button>
+                        <button class="industry_item">党委办</button>
+                        <button class="industry_item">电信行业</button>
+                    </div>
+                </li>
+                <li class="list_item" id="F">
+                    <div class="item_label">F</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">法院</button>
+                        <button class="industry_item">发改</button>
+                    </div>
+                </li>
+                <li class="list_item" id="G">
+                    <div class="item_label">G</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">工商</button>
+                        <button class="industry_item">工信</button>
+                        <button class="industry_item">国土</button>
+                        <button class="industry_item">公安</button>
+                        <button class="industry_item">国资委</button>
+                        <button class="industry_item">公共资源交易</button>
+                    </div>
+                </li>
+                <li class="list_item" id="H">
+                    <div class="item_label">H</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">环保</button>
+                        <button class="industry_item">海关</button>
+                    </div>
+                </li>
+                <li class="list_item" id="J">
+                    <div class="item_label">J</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">教育</button>
+                        <button class="industry_item">军队</button>
+                        <button class="industry_item">交通</button>
+                        <button class="industry_item">纪委</button>
+                        <button class="industry_item">金融业</button>
+                        <button class="industry_item">建筑业</button>
+                        <button class="industry_item">检察院</button>
+                        <button class="industry_item">机关事务</button>
+                    </div>
+                </li>
+                <li class="list_item" id="K">
+                    <div class="item_label">K</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">科技</button>
+                    </div>
+                </li>
+                <li class="list_item" id="L">
+                    <div class="item_label">L</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">林业</button>
+                        <button class="industry_item">旅游</button>
+                    </div>
+                </li>
+                <li class="list_item" id="M">
+                    <div class="item_label">M</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">民政</button>
+                        <button class="industry_item">民宗</button>
+                    </div>
+                </li>
+                <li class="list_item" id="N">
+                    <div class="item_label">N</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">农业</button>
+                        <button class="industry_item">能源化工</button>
+                        <button class="industry_item">农林牧渔</button>
+                    </div>
+                </li>
+                <li class="list_item" id="P">
+                    <div class="item_label">P</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">批发零售</button>
+                    </div>
+                </li>
+                <li class="list_item" id="Q">
+                    <div class="item_label">Q</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">气象</button>
+                    </div>
+                </li>
+                <li class="list_item" id="R">
+                    <div class="item_label">R</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">人行</button>
+                        <button class="industry_item">人社</button>
+                        <button class="industry_item">人大</button>
+                    </div>
+                </li>
+                <li class="list_item" id="S">
+                    <div class="item_label">S</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">食药</button>
+                        <button class="industry_item">税务</button>
+                        <button class="industry_item">水利</button>
+                        <button class="industry_item">市政</button>
+                        <button class="industry_item">审计</button>
+                        <button class="industry_item">商务</button>
+                        <button class="industry_item">司法</button>
+                        <button class="industry_item">社会团体</button>
+                    </div>
+                </li>
+                <li class="list_item" id="T">
+                    <div class="item_label">T</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">统计</button>
+                        <button class="industry_item">统战</button>
+                        <button class="industry_item">体育</button>
+                    </div>
+                </li>
+                <li class="list_item" id="W">
+                    <div class="item_label">W</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">文化</button>
+                        <button class="industry_item">卫生</button>
+                    </div>
+                </li>
+                <li class="list_item" id="X">
+                    <div class="item_label">X</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">学校</button>
+                        <button class="industry_item">宣传</button>
+                        <button class="industry_item">信息技术</button>
+                    </div>
+                </li>
+                <li class="list_item" id="Y">
+                    <div class="item_label">Y</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">医疗</button>
+                        <button class="industry_item">银监</button>
+                        <button class="industry_item">运输物流</button>
+                    </div>
+                </li>
+                <li class="list_item" id="Z">
+                    <div class="item_label">Z</div>
+                    <div class="item_industry_list">
+                        <button class="industry_item">质监</button>
+                        <button class="industry_item">组织</button>
+                        <button class="industry_item">政协</button>
+                        <button class="industry_item">住建</button>
+                        <button class="industry_item">证监</button>
+                        <button class="industry_item">政府办</button>
+                        <button class="industry_item">制造业</button>
+                        <button class="industry_item">政务中心</button>
+                        <button class="industry_item">住宿餐饮</button>
+                    </div>
+                </li>
+            </ul>
+        </div>
+    </div>
+    <div class="slide">
+        <a href="javascript:;">#</a>
+        <a href="javascript:;">A</a>
+        <a href="javascript:;">B</a>
+        <a href="javascript:;">C</a>
+        <a href="javascript:;">D</a>
+        <a href="javascript:;">F</a>
+        <a href="javascript:;">G</a>
+        <a href="javascript:;">H</a>
+        <a href="javascript:;">J</a>
+        <a href="javascript:;">K</a>
+        <a href="javascript:;">L</a>
+        <a href="javascript:;">M</a>
+        <a href="javascript:;">N</a>
+        <a href="javascript:;">P</a>
+        <a href="javascript:;">Q</a>
+        <a href="javascript:;">R</a>
+        <a href="javascript:;">S</a>
+        <a href="javascript:;">T</a>
+        <a href="javascript:;">W</a>
+        <a href="javascript:;">X</a>
+        <a href="javascript:;">Y</a>
+        <a href="javascript:;">Z</a>
+    </div>
+    <!-- <div class="bottom_button">
+        <button class="reset-btn left_btn" disabled>重置</button>
+        <button class="save-btn right_btn" disabled>确认</button>
+    </div> -->
+    <div class="tips_btn">
+        <div class="btns">
+            <button class="reset-btn" id="cancel">取消</button>
+            <button disabled class="save-btn" id="enter">确认修改</button>
+        </div>
+    </div>
+</main>
+<script src="/vipsubscribe/js/jquery-2.1.4.js?v={{Msg "seo" "version"}}"></script>
+<script src="/vipsubscribe/js/weui.min.js?v={{Msg "seo" "version"}}"></script>
+<script src="/vipsubscribe/js/common.js?v={{Msg "seo" "version"}}"></script>
+<script>
+    //加载数据
+    var EditIndustry = {
+        reqData: {},
+        selectlast: [],
+        init: function () {
+            this.getData();
+            this.showData();//初始化页面展示
+            this.initClick();//初始化点击事件
+        },
+        getData: function () {
             //加载数据
-            var EditIndustry={
-              reqData:{},
-              selectlast:[],
-              init:function(){
-                this.getData();
-                this.showData();//初始化页面展示
-                this.initClick();//初始化点击事件
-              },
-              getData:function(){
-                //加载数据
-                  $DoPost("/subscribepay/editSub/getSubBuyMsg",{},function(r){
-                    if(r.success){
-                      EditIndustry.reqData=r.data;
-                    }
-                  },false)
-                  if(this.reqData.industry.length==0&&this.reqData.buyset.buyerclasscount==-1){
-                    this.reqData.industry=["全部行业"]
-                  }
-              },
-              showData:function(){
-                this.selectlast=this.reqData.industry;
-                
-                $('.result .result_name').html(this.reqData.industry.join('、'));
-                
-                $('.industry_item').each(function () {  
-                  let text = $(this).text();
-                  EditIndustry.reqData.industry.forEach(v =>{
-                      if(v.trim() == text.trim()){
-                        $(this).addClass('active')
-                      }
-                    })
-                });
-                
-                if(this.reqData.buyset.buyerclasscount!=-1){ //非全部行业 展示数量
-                  $('.total').html(this.reqData.buyset.buyerclasscount);
-                  $('.count').html(this.reqData.industry.length);
-                  $('.optional_count').css({"width":"100%","position":"fixed","top":0,"z-index":9999});
-                  $('.result').css({"top":$('.optional_count').height()});
-                  $('.select-area-box').css({"padding-top":$('.optional_count').height()});
-                  if(this.reqData.industry.length>=this.reqData.buyset[2]){
-                    $('.industry_item:not(.active)').attr('disabled',true);
-                  }
-                }else{
-                  $("#all").css("display","");
-                  $(".optional_count").css("display","none");
+            $DoPost("/subscribepay/editSub/getSubBuyMsg", {}, function (r) {
+                if (r.success) {
+                    EditIndustry.reqData = r.data;
                 }
-                EditIndustry.findSelectedIndustry(true);
-              },
-              initClick:function(){
-                // 点击导航跳转
-                $("body").on('click','.slide a',function(){
-                    var s = $(this).html()
-                    if(s == '#'){
-                        return;
+            }, false)
+            if (this.reqData.industry.length == 0 && this.reqData.buyset.buyerclasscount == -1) {
+                this.reqData.industry = ["全部行业"]
+            }
+        },
+        showData: function () {
+            this.selectlast = this.reqData.industry;
+
+            //$('.result .result_name').html(this.reqData.industry.join('、'));
+
+            $('.industry_item').each(function () {
+                let text = $(this).text();
+                EditIndustry.reqData.industry.forEach(v => {
+                    if (v.trim() == text.trim()) {
+                        $(this).addClass('active')
                     }
-                    document.querySelector('#' + s).scrollIntoView({block:'center'});
                 })
-                // 每个button的点击事件
-                $('.select-area-box .list').on('click', 'button', function (e) {
-                    if($(this).text()=="全部行业"){
-                      if($(this).hasClass('active')){
+            });
+
+            if (this.reqData.buyset.buyerclasscount != -1) { //非全部行业 展示数量
+                $('.total').html(this.reqData.buyset.buyerclasscount);
+                $('.count').html(this.reqData.industry.length);
+                $('.optional_count').css({"width": "100%", "position": "fixed", "top": 0, "z-index": 9999});
+                $('.result').css({"top": $('.optional_count').height()});
+                $('.select-area-box').css({"padding-top": $('.optional_count').height()});
+                if (this.reqData.industry.length >= this.reqData.buyset[2]) {
+                    $('.industry_item:not(.active)').attr('disabled', true);
+                }
+            } else {
+                $("#all").css("display", "");
+                $(".optional_count").css("display", "none");
+            }
+            EditIndustry.findSelectedIndustry(true);
+        },
+        initClick: function () {
+            // 点击导航跳转
+            $("body").on('click', '.slide a', function () {
+                var s = $(this).html()
+                if (s == '#') {
+                    return;
+                }
+                document.querySelector('#' + s).scrollIntoView({block: 'center'});
+            })
+            // 每个button的点击事件
+            $('.select-area-box .list').on('click', 'button', function (e) {
+                if ($(this).text() == "全部行业") {
+                    if ($(this).hasClass('active')) {
                         return
-                      }
-                      if(EditIndustry.reqData.buyset.buyerclasscount!=-1){ //购买不是全部行业 不能点击
+                    }
+                    if (EditIndustry.reqData.buyset.buyerclasscount != -1) { //购买不是全部行业 不能点击
                         EditIndustry.showTip(`<span style="white-space: nowrap;">您只购买了${EditIndustry.reqData.buyset.buyerclasscount}个行业,如需更多请升级<span></p>`);
                         return
-                      }
-                      $('.select-area-box .list button').removeClass('active');
-                      $('#all button').addClass('active');
-                      $('#enter').removeAttr('disabled');
-                    }else{
-                      $(this).toggleClass('active')
-                      if($(".industry_item.active").length==0){//如果没有行业被选中 则选中全部行业
-                        if(EditIndustry.reqData.buyset.buyerclasscount==-1){
-                          $('#all button').addClass('active');
-                        }else{
-                          $('#enter').attr('disabled','disabled');//选择空不能提交
+                    }
+                    $('.select-area-box .list button').removeClass('active');
+                    $('#all button').addClass('active');
+                    $('#enter').removeAttr('disabled');
+                } else {
+                    $(this).toggleClass('active')
+                    if ($(".industry_item.active").length == 0) {//如果没有行业被选中 则选中全部行业
+                        if (EditIndustry.reqData.buyset.buyerclasscount == -1) {
+                            $('#all button').addClass('active');
+                        } else {
+                            $('#enter').attr('disabled', 'disabled');//选择空不能提交
                         }
-                      }else{
+                    } else {
                         $('#all button').removeClass('active');
                         $('#enter').removeAttr('disabled');
-                      }
-                    }
-                    
-                    EditIndustry.findSelectedIndustry(false);
-                })
-                // 取消按钮事件 返回上一页
-                $('#cancel').click(function(){
-                    window.history.go(-1);
-                })
-                // 确定修改事件
-                $('#enter').click(function(){
-                  $("#enter").attr("disabled","disabled");  
-                  //更新对象
-                  if(EditIndustry.reqData.buyset.buyerclasscount==-1&&EditIndustry.reqData.industry[0]=="全部行业"){
-                    EditIndustry.reqData.industry=[];
-                  }
-                  console.log("final select ",EditIndustry.reqData)
-                  $DoPost("/subscribepay/editSub/submit",{"type":"industry","value":JSON.stringify(EditIndustry.reqData.industry)},function(r){
-                    if(r.success){
-                      window.location.replace('/front/vipsubscribe/submitEditSubFinish');
                     }
-                  },false)
-                  $("#enter").removeAttr("disabled");  
-                })
-              },
-              showTip:function(msg){
-                weui.toast(msg,{
-                  duration: 2000,
-                  className: 'custom-toast',
-                });
-              },
-              findSelectedIndustry:function(isInit) {
-                  var buttons = $('.select-area-box .list button')
-                  // 找到已选择的数组(有active类的数组)
-                  var selectedArr = []
-                  buttons.each(function(){
-                      if ($(this).hasClass('active')) {
-                        selectedArr.push($(this).text())
-                      }
-                  })
-                  if(selectedArr.length==$('.select-area-box .list button').length-1){//选中了全部行业
-                    $('#all button').trigger('click');
-                    return
-                  }
-                  var selectCount= selectedArr.length
-                  $('.count').html(selectCount);
-                  // 显示隐藏优惠tips
-                  if (selectedArr.length >= EditIndustry.reqData.buyset.buyerclasscount&& EditIndustry.reqData.buyset.buyerclasscount!=-1) {
-                    if(!isInit){
-                      EditIndustry.showTip(`<span style="white-space: nowrap;">您只购买了${EditIndustry.reqData.buyset.buyerclasscount}个行业,如需更多请升级<span></p>`);
+                }
+
+                EditIndustry.findSelectedIndustry(false);
+            })
+            // 取消按钮事件 返回上一页
+            $('#cancel').click(function () {
+                window.history.go(-1);
+            })
+            // 确定修改事件
+            $('#enter').click(function () {
+                $("#enter").attr("disabled", "disabled");
+                //更新对象
+                if (EditIndustry.reqData.buyset.buyerclasscount == -1 && EditIndustry.reqData.industry[0] == "全部行业") {
+                    EditIndustry.reqData.industry = [];
+                }
+                console.log("final select ", EditIndustry.reqData)
+                $DoPost("/subscribepay/editSub/submit", {
+                    "type": "industry",
+                    "value": JSON.stringify(EditIndustry.reqData.industry)
+                }, function (r) {
+                    if (r.success) {
+                        window.location.replace('/front/vipsubscribe/submitEditSubFinish');
                     }
-                    $('.industry_item:not(.active)').attr('disabled','disabled');
-                  } else {
-                      $('.industry_item:not(.active)').removeAttr('disabled')
-                  }
-                  this.reqData.industry = selectedArr;
-                  var selectedStr = selectedArr.join('、')
-                  $('.result .result_name').text(selectedStr)
-                  if(this.noChange(this.reqData.industry,EditIndustry.selectlast)||this.reqData.industry.length==0){
-                    $('#enter').attr('disabled', 'disabled');
-                  }else{
-                    $('#enter').removeAttr('disabled');
-                  }
-                  $(".select-area-box .list").css("margin-top",$(".result").height()+20);
-              },
-              noChange:function(arr1,arr2){
-                return JSON.stringify(arr1.sort()) === JSON.stringify(arr2.sort());
-              }
-            }
-            $(function(){
-              EditIndustry.init();
+                }, false)
+                $("#enter").removeAttr("disabled");
             })
-            
-        </script>
-    </body>
+        },
+        showTip: function (msg) {
+            weui.toast(msg, {
+                duration: 2000,
+                className: 'custom-toast',
+            });
+        },
+        findSelectedIndustry: function (isInit) {
+            var buttons = $('.select-area-box .list button')
+            // 找到已选择的数组(有active类的数组)
+            var selectedArr = []
+            buttons.each(function () {
+                if ($(this).hasClass('active')) {
+                    selectedArr.push($(this).text())
+                }
+            })
+            if (selectedArr.length == $('.select-area-box .list button').length - 1) {//选中了全部行业
+                $('#all button').trigger('click');
+                return
+            }
+            var selectCount = selectedArr.length
+            $('.count').html(selectCount);
+            // 显示隐藏优惠tips
+            if (selectedArr.length >= EditIndustry.reqData.buyset.buyerclasscount && EditIndustry.reqData.buyset.buyerclasscount != -1) {
+                if (!isInit) {
+                    EditIndustry.showTip(`<span style="white-space: nowrap;">您只购买了${EditIndustry.reqData.buyset.buyerclasscount}个行业,如需更多请升级<span></p>`);
+                }
+                $('.industry_item:not(.active)').attr('disabled', 'disabled');
+            } else {
+                $('.industry_item:not(.active)').removeAttr('disabled')
+            }
+            this.reqData.industry = selectedArr;
+            var selectedStr = selectedArr.join('、')
+            //$('.result .result_name').text(selectedStr)
+            if (this.noChange(this.reqData.industry, EditIndustry.selectlast) || this.reqData.industry.length == 0) {
+                $('#enter').attr('disabled', 'disabled');
+            } else {
+                $('#enter').removeAttr('disabled');
+            }
+        },
+        noChange: function (arr1, arr2) {
+            return JSON.stringify(arr1.sort()) === JSON.stringify(arr2.sort());
+        }
+    }
+    $(function () {
+        EditIndustry.init();
+    })
+
+</script>
+</body>
 </html>

+ 3 - 4
src/web/templates/weixin/vipsubscribe/renew_pay.html

@@ -127,7 +127,7 @@
                     <span class="cancel">取消</span>
                 </div>
                 <div class="box_bd">
-                    <div class="tips profit_tips" style="display: none">已选择10个月,建议“按年订阅”更划算哦~</div>
+                    <div class="tips profit_tips" style="display: none">已选择10个月,建议“按年订阅”</div>
                     <div class="computed_price">¥58.0</div>
                     <div class="bd_select">
                         <div class="weui-cells weui-cells_checkbox choose-form">
@@ -391,7 +391,7 @@
 		        return
             }
             if (currentNum >= 10) {
-            	$('.profit_tips').text("已选择"+currentNum+"个月,建议“按年订阅”更划算哦~");
+            	$('.profit_tips').text("已选择"+currentNum+"个月,建议“按年订阅”");
                 $('.profit_tips').show();
                 if(currentNum==12){ //12个月自动跳转1年
                     $("#number_box_year .year_number:eq(0)").trigger("click");
@@ -457,7 +457,7 @@
             let isChecked = $(this).is(':checked')
             let val = $('.month_number').text();
             if (val >= 10) {
-            	$('.profit_tips').text("已选择"+val+"个月,建议“按年订阅”更划算哦~");
+            	$('.profit_tips').text("已选择"+val+"个月,建议“按年订阅”");
                 $('.profit_tips').show();
                 val = 10;
             }
@@ -799,7 +799,6 @@
 	    		"time": $('.choose_item.select_cycle .info').val(),
 	    		"payWay":"wx_js",
 	    		"pay_source": "Renew",
-	    		"endtime": ends,
 	    	}
 	    	console.log(param)
 	    	$DoPost("/subscribepay/renewUpgrade/renewUpgradeCreateOrder",param,function(r){

+ 15 - 8
src/web/templates/weixin/vipsubscribe/vip_purchase.html

@@ -426,9 +426,9 @@
                     }
                 }
 
-                if (!$.isEmptyObject(data) && !this.areaSelect["一个省"]) {
+                /*if (!$.isEmptyObject(data) && !this.areaSelect["一个省"]) {
                     $(".choose_area").val(provinceArr.join(" ") + " " + cityArr.join(" "));
-                }
+                }*/
 
                 if (!$.isEmptyObject(this.areaSelect) && !this.areaSelect["全国"] && !this.areaSelect["一个省"]) { //选择有行业信息 且不是全国
                     var tipTxt = "已选择 ";
@@ -437,7 +437,12 @@
                         if (provinceArr.length > 0) tipTxt += "、";
                         tipTxt += cityArr.length + " 个地市";
                     }
-                    $(".add_tips.area").text(tipTxt).css("display", "");
+                    $(".choose_area").val(tipTxt);
+                    //$(".add_tips.area").text(tipTxt).css("display", "");
+                }else if(!$.isEmptyObject(this.areaSelect) && this.areaSelect["全国"] ){
+                    $(".choose_area").val("全国");
+                }else {
+                    $(".choose_area").val("");
                 }
             },
             showPrice: function () {
@@ -457,13 +462,15 @@
             },
             showIndustry: function () {
                 let data = this.industrySelect;
-                if (data.length > 0 && data[0] != "一个行业") {
+                /*if (data.length > 0 && data[0] != "一个行业") {
                     $(".choose_industry").val(data.join(" "));
-                }
-
+                }*/
                 if (this.industrySelect.length > 0 && this.industrySelect[0] != "全部行业" && this.industrySelect[0] != "一个行业") { //选择有行业信息
-                    var tipTxt = "已选择 ";
-                    $(".add_tips.industry").text(tipTxt + this.industrySelect.length + " 个行业").css("display", "");
+                    $(".choose_industry").val("已选择 " + this.industrySelect.length + " 个行业");
+                }else if(this.industrySelect.length > 0 && this.industrySelect[0] == "全部行业"){
+                    $(".choose_industry").val("全部行业");
+                }else{
+                    $(".choose_industry").val("");
                 }
             },
             showTime: function () {

+ 29 - 21
src/web/templates/weixin/vipsubscribe/vip_upgrade.html

@@ -607,7 +607,7 @@
             }
             $(".computed_price").show();
             if (currentNum >= 10) {
-            	$('.profit_tips').text("已选择"+currentNum+"个月,建议“按年订阅”更划算哦~");
+            	$('.profit_tips').text("已选择"+currentNum+"个月,建议“按年订阅”");
                 $('.profit_tips').show();
                 if(currentNum==12){ //12个月自动跳转1年
                     $("#number_box_year .year_number:eq(0)").trigger("click");
@@ -674,7 +674,7 @@
             let isChecked = $(this).is(':checked')
             let val = $('.month_number').text();
             if (val >= 10) {
-                $('.profit_tips').text("已选择"+val+"个月,建议“按年订阅”更划算哦~");
+                $('.profit_tips').text("已选择"+val+"个月,建议“按年订阅”");
                 $('.profit_tips').show();
             }
             
@@ -914,6 +914,8 @@
 	 	//
 	 	var area = "";
 	    var buyerclass = "";
+	    var buyArea = "";
+	    var buyIndustry = "";
 	    var cycleunit = "";
 	    var cyclecount = "";
 	 	var startTime = "";
@@ -923,8 +925,10 @@
 //	    var isvalidOk = "";
 	 	$DoPost("/subscribepay/renewUpgrade/getBuyMsg", {}, function (data) {
             if (data) {
-                area = data.allarea;
-			    buyerclass = data.allindustry;
+                area = data.area;
+			    buyerclass = data.buyerclass;
+			    buyArea = data.allarea;
+			    buyIndustry = data.allindustry;
 			    cycleunit = data.cycleunit;
 			    cyclecount = data.cyclecount;
 			    startTime = data.start;
@@ -1080,9 +1084,9 @@
 				}
 			}else{
 				areasArr = null;
-				if(area !== ""&&area !== undefined){
-					for(let province in area){
-			    		let citys = area[province];
+				if(buyArea !== ""&&buyArea !== undefined){
+					for(let province in buyArea){
+			    		let citys = buyArea[province];
 			    		if(citys.length===0){
 							allArea[province] = [];
 			    		}else{
@@ -1160,6 +1164,10 @@
 						industrysArr = ["全部行业"];
 					}
 				}
+			}
+			
+			if(sessionStorage.vipSubSelectIndustryUpgrade!==""&&sessionStorage.vipSubSelectIndustryUpgrade!==undefined){
+				var vipIndustry = JSON.parse(sessionStorage.vipSubSelectIndustryUpgrade);
 				if(buyerclass!==""&&buyerclass!==undefined){
 					for(let i in buyerclass){
 			    		let industry = buyerclass[i];
@@ -1178,9 +1186,9 @@
 				}
 			}else{
 				industrysArr = null;
-				if(buyerclass!==""&&buyerclass!==undefined){
-					for(let i in buyerclass){
-			    		let industry = buyerclass[i];
+				if(buyIndustry!==""&&buyIndustry!==undefined){
+					for(let i in buyIndustry){
+			    		let industry = buyIndustry[i];
 			    		allIndustry.push(industry);
 			    	}
 			    }
@@ -1301,8 +1309,8 @@
 			console.log("month",nowUpgrade)
 			//
 			if (nowUpgradeYear >= 1) {
-				let monthprice = getsubVipOrderPrice(area, buyerclass, [nowUpgrade, 2])
-				let yearprice = getsubVipOrderPrice(area, buyerclass, [nowUpgradeYear, 1])
+				let monthprice = getsubVipOrderPrice(buyArea, buyIndustry, [nowUpgrade, 2])
+				let yearprice = getsubVipOrderPrice(buyArea, buyIndustry, [nowUpgradeYear, 1])
 				oldPrice = yearprice + monthprice
 				if (monthprice == 0) {
 					oldMonthPrice = ((yearprice / nowUpgradeYear) / 10).toFixed(1);
@@ -1312,7 +1320,7 @@
 					oldYearPrice = ((monthprice / nowUpgrade) * 10).toFixed(1);
 				}
 			} else {
-				oldPrice = getsubVipOrderPrice(area, buyerclass, [nowUpgrade, 2])
+				oldPrice = getsubVipOrderPrice(buyArea, buyIndustry, [nowUpgrade, 2])
 				oldMonthPrice = (oldPrice / nowUpgrade)
 				oldYearPrice = ((oldPrice / nowUpgrade) * 10).toFixed(1);
 			}
@@ -1332,12 +1340,12 @@
 					addAreaPriceM = getsubVipOrderPrice(areasArr,industrysArr,[nowUpgrade,2]);
 				}
 				if(areasArr !== null){
-					oldAreaPriceY = getsubVipOrderPrice(areasArr,buyerclass,[nowUpgradeYear,1]);
-					oldAreaPriceM = getsubVipOrderPrice(areasArr,buyerclass,[nowUpgrade,2]);
+					oldAreaPriceY = getsubVipOrderPrice(areasArr,buyIndustry,[nowUpgradeYear,1]);
+					oldAreaPriceM = getsubVipOrderPrice(areasArr,buyIndustry,[nowUpgrade,2]);
 				}
 				if(industrysArr !== null){
-					addIndustryPriceY = getsubVipOrderPrice(area,industrysArr,[nowUpgradeYear,1]);
-					addIndustryPriceM = getsubVipOrderPrice(area,industrysArr,[nowUpgrade,2]);
+					addIndustryPriceY = getsubVipOrderPrice(buyArea,industrysArr,[nowUpgradeYear,1]);
+					addIndustryPriceM = getsubVipOrderPrice(buyArea,industrysArr,[nowUpgrade,2]);
 				}
 				let yearprice = getsubVipOrderPrice(allArea,allIndustry,[nowUpgradeYear,1]);
 				let monthprice = getsubVipOrderPrice(allArea,allIndustry,[nowUpgrade,2]);
@@ -1363,10 +1371,10 @@
 					addAreaPriceM = getsubVipOrderPrice(areasArr,industrysArr,[nowUpgrade,2]);
 				}
 				if(areasArr !== null){
-					oldAreaPriceM = getsubVipOrderPrice(areasArr,buyerclass,[nowUpgrade,2]);
+					oldAreaPriceM = getsubVipOrderPrice(areasArr,buyIndustry,[nowUpgrade,2]);
 				}
 				if(industrysArr !== null){
-					addIndustryPriceM = getsubVipOrderPrice(area,industrysArr,[nowUpgrade,2]);
+					addIndustryPriceM = getsubVipOrderPrice(buyArea,industrysArr,[nowUpgrade,2]);
 				}
 				let monthprice = getsubVipOrderPrice(allArea,allIndustry,[nowUpgrade,2]);
 //				price = getsubVipOrderPrice(areasArr,industrysArr,[nowUpgrade,2]);
@@ -1468,8 +1476,8 @@
         		industryArr = "no";
         	}
             //
-            let areaarr = area;
-        	let industryarr = buyerclass;
+            let areaarr = buyArea;
+        	let industryarr = buyIndustry;
         	let allAreaArr = allArea;
         	let allIndustryArr = allIndustry;
         	if(allAreaArr["全国"]){