bug修改
This commit is contained in:
parent
65e5c884fa
commit
17c53afdb4
@ -55,7 +55,10 @@
|
|||||||
"urlCheck" : false,
|
"urlCheck" : false,
|
||||||
"es6" : true
|
"es6" : true
|
||||||
},
|
},
|
||||||
"usingComponents" : true
|
"usingComponents" : true,
|
||||||
|
"optimization" : {
|
||||||
|
"subpackages" : true
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"mp-alipay" : {
|
"mp-alipay" : {
|
||||||
"usingComponents" : true
|
"usingComponents" : true
|
||||||
|
@ -35,7 +35,7 @@
|
|||||||
import VNavigationBar from '@/components/VNavigationBar.vue'
|
import VNavigationBar from '@/components/VNavigationBar.vue'
|
||||||
import request from "@/utils/request";
|
import request from "@/utils/request";
|
||||||
import {getUserInfoRequest} from "@/utils/common.js";
|
import {getUserInfoRequest} from "@/utils/common.js";
|
||||||
import {getToken,setUserInfo} from '@/utils/auth.js'
|
import {getToken,setUserInfo,getUserInfo} from '@/utils/auth.js'
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
VNavigationBar,
|
VNavigationBar,
|
||||||
@ -76,13 +76,25 @@ export default {
|
|||||||
})
|
})
|
||||||
}else{
|
}else{
|
||||||
console.log("已登录")
|
console.log("已登录")
|
||||||
this.getUserInfos()
|
if(!getUserInfo()){
|
||||||
|
console.log("没有用户信息")
|
||||||
|
this.getUserInfos()
|
||||||
|
}else{
|
||||||
|
this.customInfo = JSON.parse(getUserInfo())
|
||||||
|
this.getActive()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(data) {
|
onLoad(data) {
|
||||||
this.getActive()
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
preventKeyboard(e) {
|
||||||
|
// 阻止键盘弹出
|
||||||
|
e.preventDefault();
|
||||||
|
// 将焦点移除,这样就不会有键盘弹出
|
||||||
|
e.target.blur();
|
||||||
|
},
|
||||||
isNumber(value) {
|
isNumber(value) {
|
||||||
return /^\d+(\.\d+)?$/.test(value);
|
return /^\d+(\.\d+)?$/.test(value);
|
||||||
},
|
},
|
||||||
@ -108,12 +120,27 @@ export default {
|
|||||||
},
|
},
|
||||||
//获取当前登录用户信息
|
//获取当前登录用户信息
|
||||||
async getUserInfos() {
|
async getUserInfos() {
|
||||||
await getUserInfoRequest()
|
request({
|
||||||
await this.getActive()
|
url: "/userClient/customer/getUserCustomer",
|
||||||
|
method: 'get',
|
||||||
|
params:{}
|
||||||
|
}).then(res=>{
|
||||||
|
if(!res.data){
|
||||||
|
uni.reLaunch({
|
||||||
|
url: '/pages/my/register'
|
||||||
|
})
|
||||||
|
}else{
|
||||||
|
setUserInfo(JSON.stringify(res.data))
|
||||||
|
this.customInfo = res.data
|
||||||
|
this.getActive()
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
//查询营销活动列表
|
//查询营销活动列表
|
||||||
async getActive() {
|
async getActive() {
|
||||||
this.customInfo = JSON.parse(uni.getStorageSync('customerInfo'))
|
this.activeList=[]
|
||||||
|
this.couponList=[]
|
||||||
|
this.array=[]
|
||||||
const data = {
|
const data = {
|
||||||
cusId: this.customInfo.id
|
cusId: this.customInfo.id
|
||||||
}
|
}
|
||||||
@ -265,9 +292,7 @@ export default {
|
|||||||
flex: 1;
|
flex: 1;
|
||||||
height: 0;
|
height: 0;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding: 30rpx 0;
|
padding: 30rpx 32rpx;
|
||||||
margin: 0 32rpx;
|
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
row-gap: 20rpx;
|
row-gap: 20rpx;
|
||||||
|
@ -93,7 +93,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import VNavigationBar from '@/components/VNavigationBar.vue'
|
import VNavigationBar from '@/components/VNavigationBar.vue'
|
||||||
import reservationOrder from '@/components/reservationOrder/reservationOrder.vue'
|
import reservationOrder from '@/components/reservationOrder/reservationOrder.vue'
|
||||||
import TicketsItem from "@/components/ticketsItem/ticketsItem.vue";
|
import TicketsItem from "@/pages-order/ticketsItem/ticketsItem.vue";
|
||||||
import request from "../../utils/request";
|
import request from "../../utils/request";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
@ -66,8 +66,7 @@
|
|||||||
import tabBarVue from '@/components/tabBar/tabBar.vue'
|
import tabBarVue from '@/components/tabBar/tabBar.vue'
|
||||||
import request from "@/utils/request";
|
import request from "@/utils/request";
|
||||||
import {getUserInfoRequest} from "@/utils/common.js";
|
import {getUserInfoRequest} from "@/utils/common.js";
|
||||||
import {getToken,setUserInfo} from '@/utils/auth.js'
|
import {getToken,setUserInfo,getUserInfo} from '@/utils/auth.js'
|
||||||
import {getUserInfo} from "../../utils/auth";
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
tabBarVue,
|
tabBarVue,
|
||||||
@ -80,7 +79,11 @@
|
|||||||
})
|
})
|
||||||
}else{
|
}else{
|
||||||
console.log("已登录")
|
console.log("已登录")
|
||||||
this.getServer()
|
if(!getUserInfo()){
|
||||||
|
this.getServer()
|
||||||
|
}else{
|
||||||
|
this.customInfo = JSON.parse(getUserInfo())
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
@ -103,7 +103,7 @@
|
|||||||
import VNavigationBar from '@/components/VNavigationBar.vue'
|
import VNavigationBar from '@/components/VNavigationBar.vue'
|
||||||
import config from "@/config";
|
import config from "@/config";
|
||||||
import {getUserInfoRequest} from "@/utils/common.js";
|
import {getUserInfoRequest} from "@/utils/common.js";
|
||||||
import {getToken,setUserInfo} from '@/utils/auth.js'
|
import {getToken,getUserInfo} from '@/utils/auth.js'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
@ -123,7 +123,7 @@
|
|||||||
},
|
},
|
||||||
focus: {
|
focus: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: true,
|
default: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
Loading…
Reference in New Issue
Block a user