|
@@ -48,6 +48,7 @@ var vm = new Vue({
|
|
|
dValue: '',
|
|
|
pShow: false,
|
|
|
curDate: '',
|
|
|
+ minDate: '',
|
|
|
maxTime: '',
|
|
|
points: [],
|
|
|
years: '',
|
|
@@ -71,6 +72,7 @@ var vm = new Vue({
|
|
|
this.months = parseInt(new Date().getMonth() + 1)
|
|
|
this.dValue = this.years + '年' + this.months + '月'
|
|
|
this.curDate = new Date()
|
|
|
+ this.minDate = new Date(2021, 0)
|
|
|
this.maxTime = new Date(this.years, this.months - 1)
|
|
|
this.subPoint()
|
|
|
this.onLoad()
|
|
@@ -90,15 +92,10 @@ var vm = new Vue({
|
|
|
}).done(res => {
|
|
|
if (res.error_code == 0) {
|
|
|
this.points = res.data
|
|
|
- if (res.data.provin === -1 && res.data.total == 0) {
|
|
|
+ if (res.data.provin === -1 && res.data.usage == res.data.total) { // 用户订阅全国且机会用完
|
|
|
this.contracted = true
|
|
|
- this.$dialog.alert({
|
|
|
- message: '每订购1个省,可查看50个企业画像/月。 您订购全国的企业画像查看权限已用完,如需更多权益,请联系客服。',
|
|
|
- className: 'pro-log',
|
|
|
- messageAlign: 'left',
|
|
|
- confirmButtonColor: '#2ABED1',
|
|
|
- confirmButtonText: '我知道了'
|
|
|
- })
|
|
|
+ } else {
|
|
|
+ this.contracted = false
|
|
|
}
|
|
|
}
|
|
|
})
|
|
@@ -161,7 +158,16 @@ var vm = new Vue({
|
|
|
},
|
|
|
helpTiped() {
|
|
|
let _this = this
|
|
|
- if (_this.points.provin === -1&&_this.points.usage !== _this.points.total) {
|
|
|
+ if (_this.points.provin === -1 && _this.points.usage == _this.points.total) { // 用户订阅全国且机会用完
|
|
|
+ this.contracted = true
|
|
|
+ this.$dialog.alert({
|
|
|
+ message: '每订购1个省,可查看50个企业画像/月。您当前订阅全国,查看机会已经消耗完毕。如需更多权益,请联系客服。',
|
|
|
+ className: 'pro-log',
|
|
|
+ messageAlign: 'left',
|
|
|
+ confirmButtonColor: '#2ABED1',
|
|
|
+ confirmButtonText: '我知道了'
|
|
|
+ })
|
|
|
+ } else if (_this.points.usage !== _this.points.total) { // 订阅全国和非订阅全国的次数未用完时
|
|
|
this.$dialog.alert({
|
|
|
message: '每订购1个省,可查看50个企业画像/月。',
|
|
|
className: 'pro-log',
|
|
@@ -169,10 +175,8 @@ var vm = new Vue({
|
|
|
confirmButtonColor: '#2ABED1',
|
|
|
confirmButtonText: '我知道了',
|
|
|
closeOnClickOverlay: true
|
|
|
- }).then(() => {
|
|
|
- // location.href = '/jyapp/vipsubscribe/toSubVipSetPage'
|
|
|
})
|
|
|
- } else {
|
|
|
+ } else if (_this.points.provin !== -1) { // 用户未订阅全国
|
|
|
this.$dialog.alert({
|
|
|
message: '每订购1个省,可查看50个企业画像/月。 您当前订阅了' + `<span style="color:#2ABED1">${_this.points.provin}</span>` + '个省,如需更多权益,请订购更多省份。',
|
|
|
className: 'pro-log',
|
|
@@ -207,7 +211,7 @@ var vm = new Vue({
|
|
|
location.href = '/weixin/frontPage/collection/sess/ent_portrait?eId=' + ids + '&svip=1'
|
|
|
},
|
|
|
contractPerson() {
|
|
|
- location.href = '/big/wx/page/customer'
|
|
|
+ location.href = '400-108-6670'
|
|
|
},
|
|
|
setBook() {
|
|
|
location.href = '/front/vipsubscribe/toSubVipSetPage'
|