Showing
4 changed files
with
40 additions
and
17 deletions
@@ -1102,7 +1102,6 @@ function actionTipPic() { | @@ -1102,7 +1102,6 @@ function actionTipPic() { | ||
1102 | 1102 | ||
1103 | 1103 | ||
1104 | 1104 | ||
1105 | - | ||
1106 | function closeCover() { | 1105 | function closeCover() { |
1107 | var $cover = $('#cover'); | 1106 | var $cover = $('#cover'); |
1108 | 1107 | ||
@@ -1649,11 +1648,13 @@ function actionLoopUpdCartNum() { | @@ -1649,11 +1648,13 @@ function actionLoopUpdCartNum() { | ||
1649 | function actionExeTemplate() { | 1648 | function actionExeTemplate() { |
1650 | var $goodcartempwarpper = $('#goodcartempwarpper'); | 1649 | var $goodcartempwarpper = $('#goodcartempwarpper'); |
1651 | var resulthtml = ''; | 1650 | var resulthtml = ''; |
1652 | - | ||
1653 | - if ($goodcartempwarpper && $goodcartempwarpper.html()) { | ||
1654 | - resulthtml = $('#goodcartempwarpper').html().replace(/\\/g, ''); | ||
1655 | - $('#goodcartempwarpper').html(resulthtml); | ||
1656 | - vipInfoCombine = handlebars.compile($('#tmpl-my-login-new').html()); | 1651 | + |
1652 | + if ($goodcartempwarpper) { | ||
1653 | + if ($goodcartempwarpper.html()) { | ||
1654 | + resulthtml = $('#goodcartempwarpper').html().replace(/\\/g, ''); | ||
1655 | + $('#goodcartempwarpper').html(resulthtml); | ||
1656 | + vipInfoCombine = handlebars.compile($('#tmpl-my-login-new').html()); | ||
1657 | + } | ||
1657 | } | 1658 | } |
1658 | } | 1659 | } |
1659 | /** | 1660 | /** |
@@ -1836,7 +1837,7 @@ function init() { | @@ -1836,7 +1837,7 @@ function init() { | ||
1836 | actionListenCartMore(); // | 1837 | actionListenCartMore(); // |
1837 | actionLoginInfo(); //获取登录信息 | 1838 | actionLoginInfo(); //获取登录信息 |
1838 | actionCover(); //初次登录弹框 | 1839 | actionCover(); //初次登录弹框 |
1839 | - actionAddKeyWords();//增加关键字 | 1840 | + actionAddKeyWords(); //增加关键字 |
1840 | } | 1841 | } |
1841 | 1842 | ||
1842 | init(); | 1843 | init(); |
@@ -2661,7 +2662,11 @@ $('#brand-favor').on('click', function() { | @@ -2661,7 +2662,11 @@ $('#brand-favor').on('click', function() { | ||
2661 | } | 2662 | } |
2662 | }).then(function(res) { | 2663 | }).then(function(res) { |
2663 | if (res.code === 200) { | 2664 | if (res.code === 200) { |
2664 | - $this.addClass('favored'); | 2665 | + if (res.message === 'add') { |
2666 | + $this.find('i').addClass('coled'); | ||
2667 | + } else { | ||
2668 | + $this.find('i').removeClass('coled'); | ||
2669 | + } | ||
2665 | } | 2670 | } |
2666 | }); | 2671 | }); |
2667 | }); | 2672 | }); |
@@ -6056,7 +6061,7 @@ function chooseProtocol() { | @@ -6056,7 +6061,7 @@ function chooseProtocol() { | ||
6056 | }); | 6061 | }); |
6057 | } | 6062 | } |
6058 | 6063 | ||
6059 | - }) | 6064 | + }); |
6060 | } | 6065 | } |
6061 | 6066 | ||
6062 | function chooseAreaToogle() { | 6067 | function chooseAreaToogle() { |
@@ -6068,12 +6073,18 @@ function chooseAreaToogle() { | @@ -6068,12 +6073,18 @@ function chooseAreaToogle() { | ||
6068 | function cancelChooseArea() { | 6073 | function cancelChooseArea() { |
6069 | $(document).on('click', 'body', function(e) { | 6074 | $(document).on('click', 'body', function(e) { |
6070 | var $target = $(e.target); | 6075 | var $target = $(e.target); |
6071 | - if ($target.hasClass('yohoselectarea') || $target.hasClass('yohoselectarea') || $target.hasClass('areaname') || $target.hasClass('righttag') || $target.hasClass('optionslist') || $target.hasClass('optionitem')) { | 6076 | + |
6077 | + if ($target.hasClass('yohoselectarea') || | ||
6078 | + $target.hasClass('yohoselectarea') || | ||
6079 | + $target.hasClass('areaname') || | ||
6080 | + $target.hasClass('righttag') || | ||
6081 | + $target.hasClass('optionslist') || | ||
6082 | + $target.hasClass('optionitem')) { | ||
6072 | return; | 6083 | return; |
6073 | } else { | 6084 | } else { |
6074 | $('.optionslist').addClass('hide'); | 6085 | $('.optionslist').addClass('hide'); |
6075 | } | 6086 | } |
6076 | - }) | 6087 | + }); |
6077 | } | 6088 | } |
6078 | 6089 | ||
6079 | function chooseArea() { | 6090 | function chooseArea() { |
@@ -6081,17 +6092,29 @@ function chooseArea() { | @@ -6081,17 +6092,29 @@ function chooseArea() { | ||
6081 | var $option = $(this); | 6092 | var $option = $(this); |
6082 | var areanum = $option.attr('areanum'); | 6093 | var areanum = $option.attr('areanum'); |
6083 | var areaname = $option.text(); | 6094 | var areaname = $option.text(); |
6095 | + | ||
6084 | $('#areaname').text(areaname); | 6096 | $('#areaname').text(areaname); |
6085 | $('#areanum').text(areanum); | 6097 | $('#areanum').text(areanum); |
6086 | $('#areacode').val(areanum); | 6098 | $('#areacode').val(areanum); |
6087 | $('.optionslist').addClass('hide'); | 6099 | $('.optionslist').addClass('hide'); |
6088 | - }) | 6100 | + }); |
6089 | } | 6101 | } |
6090 | 6102 | ||
6091 | function isagree() { | 6103 | function isagree() { |
6092 | return $('.choosetag').attr('checked'); | 6104 | return $('.choosetag').attr('checked'); |
6093 | } | 6105 | } |
6094 | 6106 | ||
6107 | +function closeMask() { | ||
6108 | + var $target; | ||
6109 | + | ||
6110 | + $(document).on('click', '#alreayregist', function(e) { | ||
6111 | + $target = $(e.target); | ||
6112 | + if ($target.hasClass('mask') || $target.hasClass('backdrop')) { | ||
6113 | + $('#alreayregist').hide(); | ||
6114 | + } | ||
6115 | + }) | ||
6116 | +} | ||
6117 | + | ||
6095 | function nextStep() { | 6118 | function nextStep() { |
6096 | var openId = ''; | 6119 | var openId = ''; |
6097 | var sourceType = ''; | 6120 | var sourceType = ''; |
@@ -6113,7 +6136,7 @@ function nextStep() { | @@ -6113,7 +6136,7 @@ function nextStep() { | ||
6113 | openId = $('#openId').val() || '29803EC6D4AAC3AAB8ABDB6AE829D579'; | 6136 | openId = $('#openId').val() || '29803EC6D4AAC3AAB8ABDB6AE829D579'; |
6114 | sourceType = $('#sourceType').val() || 'qq'; | 6137 | sourceType = $('#sourceType').val() || 'qq'; |
6115 | $.ajax({ | 6138 | $.ajax({ |
6116 | - type: "post", | 6139 | + type: 'post', |
6117 | url: '/passport/autouserinfo/bindCheck', | 6140 | url: '/passport/autouserinfo/bindCheck', |
6118 | data: { | 6141 | data: { |
6119 | mobile: mobile, | 6142 | mobile: mobile, |
@@ -6125,18 +6148,17 @@ function nextStep() { | @@ -6125,18 +6148,17 @@ function nextStep() { | ||
6125 | success: function(data) { | 6148 | success: function(data) { |
6126 | if (data.code === 200) { | 6149 | if (data.code === 200) { |
6127 | if (data.data.isReg === 0) { | 6150 | if (data.data.isReg === 0) { |
6128 | - $('#bindmobileform').attr('action','/passport/thirdlogin/noregist'); | 6151 | + $('#bindmobileform').attr('action', '/passport/thirdlogin/noregist'); |
6129 | $('#bindmobileform').submit(); | 6152 | $('#bindmobileform').submit(); |
6130 | } else { | 6153 | } else { |
6131 | - | 6154 | + $('#alreayregist').show(); |
6132 | } | 6155 | } |
6133 | } else { | 6156 | } else { |
6134 | alert(data.message); | 6157 | alert(data.message); |
6135 | } | 6158 | } |
6136 | - | ||
6137 | } | 6159 | } |
6138 | }); | 6160 | }); |
6139 | - }) | 6161 | + }); |
6140 | } | 6162 | } |
6141 | 6163 | ||
6142 | function init() { | 6164 | function init() { |
@@ -6145,6 +6167,7 @@ function init() { | @@ -6145,6 +6167,7 @@ function init() { | ||
6145 | chooseAreaToogle(); | 6167 | chooseAreaToogle(); |
6146 | cancelChooseArea(); | 6168 | cancelChooseArea(); |
6147 | nextStep(); | 6169 | nextStep(); |
6170 | + closeMask(); | ||
6148 | } | 6171 | } |
6149 | init(); | 6172 | init(); |
6150 | }); | 6173 | }); |
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
-
Please register or login to post a comment