Commit e8d2eecd authored by lijiongliang's avatar lijiongliang

页面逻辑修改

parent e88bab69
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
</view> </view>
</u-swiper> </u-swiper>
<u-gap bgColor="transparent" height="15"></u-gap> <u-gap bgColor="transparent" height="15"></u-gap>
<div class="content__code" v-if="freeCode.mainImgUrl"> <div class="content__code" v-if="freeCode || freeCode.mainImgUrl">
<div class="code__img"> <div class="code__img">
<image :src="freeCode.mainImgUrl" class="code__img"></image> <image :src="freeCode.mainImgUrl" class="code__img"></image>
</div> </div>
...@@ -180,8 +180,11 @@ ...@@ -180,8 +180,11 @@
let url = "car.m.jd.com/h5/list.html?source=managerprocedure" let url = "car.m.jd.com/h5/list.html?source=managerprocedure"
util.redirectToH5({page:url}) util.redirectToH5({page:url})
}else{ }else{
// uni.navigateTo({
// url: '/pagesA/pages/index/getPrice?orderId=' + this.freeCode.id
// });
uni.navigateTo({ uni.navigateTo({
url: '/pagesA/pages/index/getPrice?orderId=' + this.freeCode.id url: '/pagesA/pages/index/getCoupon'
}); });
} }
} }
......
...@@ -83,6 +83,7 @@ ...@@ -83,6 +83,7 @@
that.http.httpTokenRequest(opts, {}).then(res => { that.http.httpTokenRequest(opts, {}).then(res => {
if (res.data.code == 200) { if (res.data.code == 200) {
let xcxIndexPath = res.data.data.xcxIndexPath let xcxIndexPath = res.data.data.xcxIndexPath
console.log(xcxIndexPath,path,'扫一扫进入')
if (xcxIndexPath) { if (xcxIndexPath) {
xcxIndexPath = path.replace(xcxIndexPath, '').replace( xcxIndexPath = path.replace(xcxIndexPath, '').replace(
"?", '') "?", '')
...@@ -196,7 +197,6 @@ ...@@ -196,7 +197,6 @@
} }
console.log(option,uni.getStorageSync('scene'),22222222222)
let token = uni.getStorageSync('userToken') let token = uni.getStorageSync('userToken')
if (!token) { if (!token) {
let ptKey = plugin.getPtKey(); let ptKey = plugin.getPtKey();
...@@ -211,7 +211,7 @@ ...@@ -211,7 +211,7 @@
token, token,
message message
} = res; } = res;
console.log(res,22222222)
if (!token) { if (!token) {
uni.navigateTo({ uni.navigateTo({
url:"/pages/login/index/index" url:"/pages/login/index/index"
......
...@@ -22,11 +22,18 @@ ...@@ -22,11 +22,18 @@
}, },
methods:{ methods:{
getCoupon(){ getCoupon(){
let opts = { url: '/app/user/send/coupon', method: 'post' };
this.http.httpTokenRequest(opts, {}).then(res => {
console.log(res.data,1111111)
if(res.data.code == 200){
uni.showToast({ uni.showToast({
title: "领取成功!", title: "领取成功!",
icon: 'none', icon: 'none',
}); });
} }
})
}
} }
} }
</script> </script>
......
...@@ -65,7 +65,7 @@ ...@@ -65,7 +65,7 @@
行驶里程 行驶里程
</view> </view>
<view class="right"> <view class="right">
{{carInfo.mileage}}KM {{carInfo.mileage || 0}}KM
</view> </view>
</view> </view>
...@@ -173,7 +173,7 @@ export default { ...@@ -173,7 +173,7 @@ export default {
// } // }
// }) // })
uni.showToast({ uni.showToast({
title: "绑定成功!", title: "绑定成功!",
icon: 'none', icon: 'none',
}); });
setTimeout(()=>{ setTimeout(()=>{
......
...@@ -58,19 +58,20 @@ export default { ...@@ -58,19 +58,20 @@ export default {
userInfo: { userInfo: {
nickName: '默认昵称', nickName: '默认昵称',
}, },
formData: [{ formData: [
id: "kjjns", //id必须唯一 可以是数字 // {
placeholder: "请填写", // id: "kjjns", //id必须唯一 可以是数字
label: "手机号", // 提示输入名 // placeholder: "请填写",
type: "text", //类型 // label: "手机号", // 提示输入名
disabled: true, //是否禁用 // type: "text", //类型
rules: { // disabled: true, //是否禁用
name: "mobile", //字段名 即提交给后端的字段 // rules: {
value: "", // name: "mobile", //字段名 即提交给后端的字段
verify: false, //是否开启校验 // value: "",
errMess: "手机号未填写", //校验不通过的错误提示 // verify: false, //是否开启校验
}, // errMess: "手机号未填写", //校验不通过的错误提示
}, // },
// },
{ {
id: "kjjns", //id必须唯一 可以是数字 id: "kjjns", //id必须唯一 可以是数字
placeholder: "请填写", placeholder: "请填写",
...@@ -216,13 +217,13 @@ export default { ...@@ -216,13 +217,13 @@ export default {
clickFn(e) { clickFn(e) {
//console.log(e) //console.log(e)
switch (e) { switch (e) {
case 1: case 0:
this.show = true this.show = true
break; break;
case 2: case 1:
this.show__six = true this.show__six = true
break; break;
case 3: case 2:
this.show__date = true this.show__date = true
break; break;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment