Commit 0e072b0e authored by qipeng's avatar qipeng

Merge branch 'develop' of http://git.tbd.yanzuoguang.com/panyongping/uni-pdtravel into develop

parents a9aa5d94 9de7d4dd
......@@ -139,12 +139,6 @@
"enablePullDownRefresh": false
}
}, {
"path": "pages/payment/changeNumPayment/changeNumPayment",
"style": {
"navigationBarTitleText": "支付",
"enablePullDownRefresh": false
}
},
{
"path": "pages/indexs/center/center",
......
......@@ -11,7 +11,7 @@
<view class="middle">
<view class="tabbar">
<view @click="jumpPage(item.projectLinkUrl)" v-for="(item,index) in iconList" :key='index'>
<view @click="jumpPage(item.projectLinkUrl)" v-for="(item,index) in iconList" :key='index' v-show="item.projectStatus==0">
<image :src="item.projectImgUrl"></image>
<view>
{{item.merchantExtendProjectName}}
......@@ -181,7 +181,44 @@ export default {
image: 'http://wx.pangdly.com/static/img/home3.df60ec3.jpg'
}
],
iconList:[],//图标列表
iconList:[//图标列表
{
merchantExtendProjectName:'景区名称',
projectImgUrl:'/static/img/index/classify1.png',
projectLinkUrl:'/pages/scenic/scenicIndex/scenicIndex',
projectStatus:0
},
{
merchantExtendProjectName:'酒店民宿',
projectImgUrl:'/static/img/index/classify2.png',
projectLinkUrl:'/pages/hotel/hotelIndex/hotelIndex',
projectStatus:0
},
{
merchantExtendProjectName:'周边游',
projectImgUrl:'/static/img/index/classify4.png',
projectLinkUrl:'/pages/scenic/scenicIndex/scenicIndex',
projectStatus:0
},
{
merchantExtendProjectName:'跟团游',
projectImgUrl:'/static/img/index/classify5.png',
projectLinkUrl:'/pages/scenic/scenicIndex/scenicIndex',
projectStatus:0
},
{
merchantExtendProjectName:'亲子游',
projectImgUrl:'/static/img/index/classify6.png',
projectLinkUrl:'/pages/scenic/scenicIndex/scenicIndex',
projectStatus:0
},
{
merchantExtendProjectName:'行程订制',
projectImgUrl:'/static/img/index/classify7.png',
projectLinkUrl:'/pages/my/travelList/travelList/travelList',
projectStatus:0
}
],
}
},
onLoad(option){
......@@ -226,7 +263,7 @@ export default {
}
this.$request('scenic/merchantExtendProject/loadList',data).then((res)=>{
if(res.code=='00'){
this.iconList=res.data||[]
this.iconList=res.data
}
})
},
......
......@@ -23,13 +23,12 @@ export default {
methods:{
//---登录
login(){
let _this = this
uni.getProvider({
service: 'oauth',
success(proRes) {
success:proRes=>{
uni.login({
provider: proRes.provider[0],
success: function(res) {
success:res=> {
if (res.code) {
let source = ''
if (proRes.provider[0] == 'weixin') {
......@@ -45,13 +44,13 @@ export default {
if(uni.getStorageSync('enterOptions').query){
data.companyId=uni.getStorageSync('enterOptions').query.companyId||''
}
_this.$request('wechat/wx/getUserInfoByCode', data).then(res => {
this.$request('wechat/wx/getUserInfoByCode', data).then(res => {
if (res.code == '00') {
let openid = res.data.openid
uni.setStorageSync('openid', openid)
let userId = res.data.userId || ''
let datas = { openid, source, userId }
_this.$request('wechatUser/login/findWxUserAndLogin', datas).then(res => {
this.$request('wechatUser/login/findWxUserAndLogin', datas).then(res => {
//通过openid获取token
if (res.code == '00') {
let token = res.data.token || ''
......@@ -71,7 +70,7 @@ export default {
url: '/' + enterOptions.path + '?' + queryTotal
})
//保存当前日期
let oldDate=_this.$commonjs.today()
let oldDate=this.$commonjs.today()
uni.setStorageSync('oldDate', oldDate)
// uni.navigateBack({
// delta:1
......@@ -88,8 +87,8 @@ export default {
title: '登录失败,请退出并重新登录',
icon: 'none'
})
_this.timer = setTimeout(() => {
_this.login()
this.timer = setTimeout(() => {
this.login()
}, 2000)
})
} else {
......@@ -103,8 +102,8 @@ export default {
title: '登录失败,请退出并重新登录',
icon: 'none'
})
_this.timer = setTimeout(() => {
_this.login()
this.timer = setTimeout(() => {
this.login()
}, 2000)
})
}
......
<template>
<!-- 传入价格,通过改变数量改变价格的支付页面 -->
<view class="wrap">
<view class="top">
<view class="name">
皇冠大扶梯
</view>
<view class="number">
<text>
购买数量
</text>
<u-number-box
v-model="buyNumber"
bg-color='#3688FF'
color='#ffffff'
:input-height="60"
size='28'>
</u-number-box>
</view>
<view class="price">
<text>
总价
</text>
<text>
¥6.00
</text>
</view>
<view class="remark">
<input placeholder="添加备注(20字以内)" maxlength="20" v-model.trim="remark" style="margin-bottom:20rpx;" />
</view>
<view class="tips">
温馨提示:请核对以上付款金额、付款对象等信息与交易匹配。
</view>
</view>
<view class="bottom">
<text class="btn">立即支付</text>
</view>
</view>
</template>
<script>
export default {
data() {
return {
remark:'',//备注
payType:'',//支付方式
buyNumber:'',//购买数量
}
},
onLoad(option) {
//#ifdef MP-WEIXIN
this.payType = 42
//#endif
//#ifdef MP-ALIPAY
this.payType = 33
//#endif
},
methods: {
}
}
</script>
<style lang="scss" scoped>
.wrap{
height: 100%;
background: #ffffff;
}
.top{
padding: 40rpx 24rpx;
}
.name{
font-size: 32rpx;
font-weight: bold;
color: #191919;
text-align: center;
}
.number{
display: flex;
justify-content: space-between;
font-weight: bold;
margin-top: 80rpx;
align-items: center;
}
.price{
display: flex;
justify-content: space-between;
font-weight: bold;
margin-top: 48rpx;
text:nth-child(2){
font-size: 40rpx;
color: $red;
}
}
.remark{
margin-top: 48rpx;
color: $grey;
}
.tips{
margin-top: 24rpx;
color: $grey;
font-size: 24rpx;
}
.bottom{
position: fixed;
width: 100%;
height: 100rpx;
display: flex;
align-items: center;
justify-content: center;
bottom: 0;
box-shadow: 0px -4px 12px 2px rgba(0,0,0,0.08);
background: #ffffff;
}
.btn{
display: flex;
align-items: center;
justify-content: center;
width: 90%;
height: 80rpx;
background: #3688FF;
border-radius: 8rpx;
font-size: 32rpx;
font-weight: bold;
}
</style>
......@@ -97,13 +97,12 @@ export default {
methods: {
login() {
//---登录
let _this = this
uni.getProvider({
service: 'oauth',
success(proRes) {
success:proRes=>{
uni.login({
provider: proRes.provider[0],
success: function(res) {
success: res=>{
if (res.code) {
let source = ''
if (proRes.provider[0] == 'weixin') {
......@@ -119,12 +118,12 @@ export default {
if(uni.getStorageSync('enterOptions').query){
data.companyId=uni.getStorageSync('enterOptions').query.companyId||''
}
_this.$request('wechat/wx/getUserInfoByCode', data)
this.$request('wechat/wx/getUserInfoByCode', data)
.then(res => {
if (res.code == '00') {
_this.openid = res.data.openid
uni.setStorageSync('openid', _this.openid)
_this.initDetail()
this.openid = res.data.openid
uni.setStorageSync('openid', this.openid)
this.initDetail()
} else {
uni.showToast({
title: res.message,
......@@ -203,7 +202,6 @@ export default {
},
goPay() {
//-------------------------------------------------------去支付
let _this = this
if (this.errorMessage) {
uni.showToast({
title: this.errorMessage,
......@@ -224,9 +222,9 @@ export default {
package: this.package,
signType: this.signType,
paySign: this.paySign,
success: function(res) {
success:res=>{
uni.navigateTo({
url: '/pages/payment/paySuccess/paySuccess?orderId=' + _this.orderId+'&afterBuyUrl=' + _this.afterBuyUrl + '&ifyukuaiCode=' + _this.ifyukuaiCode
url: '/pages/payment/paySuccess/paySuccess?orderId=' + this.orderId+'&afterBuyUrl=' + this.afterBuyUrl + '&ifyukuaiCode=' + this.ifyukuaiCode
})
},
fail: function(err) {
......@@ -242,9 +240,9 @@ export default {
uni.requestPayment({
provider: 'alipay', // 服务提供商 支付宝支付: alipay 微信支付: wxpay
orderInfo: this.orderInfo, // 支付宝订单号
success: function(res) {
success: res=> {
uni.navigateTo({
url: '/pages/payment/paySuccess/paySuccess?orderId=' + _this.orderId+'&afterBuyUrl=' + _this.afterBuyUrl + '&ifyukuaiCode=' + _this.ifyukuaiCode
url: '/pages/payment/paySuccess/paySuccess?orderId=' + this.orderId+'&afterBuyUrl=' + this.afterBuyUrl + '&ifyukuaiCode=' + this.ifyukuaiCode
})
},
fail: function(err) {
......
<template>
<view class="bigBox">
<view class="bigBox" :style="{background:backgroundColor}">
<template v-if="showMoney">
<view class="top">
<view class="topName">
<text>{{ name }}</text>
<text>{{ companyName }}</text>
</view>
<view class="topMoney">
<view class="moneyText">
付款金额
</view>
<view class="moneyText"> 付款金额 </view>
<view class="moneyNumber">
<text class="iconfont icon-fl-renminbi" style="font-size: 56rpx"></text>
<text>{{ buyMoney }}</text>
<text>{{ orderMoney }}</text>
<text></text>
</view>
</view>
......@@ -59,12 +58,10 @@
<view class="middle">
<view>
<input placeholder="添加备注(20字以内)" maxlength="20" v-model.trim="remark" style="margin-bottom:20rpx;" />
<input placeholder="添加备注(20字以内)" maxlength="20" v-model.trim="remark" style="margin-bottom: 20rpx" />
</view>
<view style="font-size:24rpx;">
温馨提示:请核对以上付款金额、付款对象等信息与交易匹配。
</view>
<view style="font-size: 24rpx"> 温馨提示:请核对以上付款金额、付款对象等信息与交易匹配。 </view>
</view>
<view class="bottom">
......@@ -86,6 +83,48 @@
</view>
</view>
</view>
</template>
<template v-if="showNumber">
<view class="top2">
<view class="top2-name">
{{companyName}}
</view>
<view class="top2-number">
<text>
购买数量
</text>
<u-number-box
@change='numberChange'
v-model="buyNum"
bg-color='#3688FF'
color='#ffffff'
:input-height="60"
:min="1"
size='28'>
</u-number-box>
</view>
<view class="top2-price">
<text>
总价
</text>
<text>
¥{{orderMoney}}
</text>
</view>
<view class="top2-remark">
<input placeholder="添加备注(20字以内)" maxlength="20" v-model.trim="remark" style="margin-bottom:20rpx;" />
</view>
<view class="top2-tips">
温馨提示:请核对以上付款金额、付款对象等信息与交易匹配。
</view>
</view>
<view class="bottom2">
<text class="btn" @click="clickPay()" :style="{ background: payBackground }">立即支付</text>
</view>
</template>
<!-------------------------------------------券弹窗------------------------------>
<orderCoupon :couponData="couponData" ref="orderCoupon" @couponChoose="couponChoose" :chooseCouponObj="chooseCouponObj"></orderCoupon>
</view>
......@@ -99,12 +138,16 @@ export default {
},
data() {
return {
remark:'',//备注
enterUrl: '', //进入页面路由
buyMoney: '', //输入金额
backgroundColor:'#f5f5f5',//背景颜色
showMoney:false,//显示输入金额页面
showNumber:false,//显示输入数量页面
tollPoint:'',//收费点信息
buyNum:1,//购买数量
remark: '', //备注
orderMoney: '', //订单金额
companyId: '', //公司Id
merchantId: '', //商户Id
name: '', //商家名称
companyName: '', //商家名称
payType: '', //支付类型,微信小程序42,支付宝小程序33
paySign: '', //签名
signType: '', //签名方式
......@@ -160,34 +203,26 @@ export default {
},
onLoad(option) {
//#ifdef MP-WEIXIN
this.enterUrl = option.q
this.payType = 42
//#endif
//#ifdef MP-ALIPAY
this.enterUrl = uni.getStorageSync('alipayQrCode')
uni.removeStorageSync('alipayQrCode') //临时解决出租车扫码之后跳转到组合票时,参数会有问题,有时间再根本解决
this.payType = 33
//#endif
if (this.enterUrl) {
//扫普通二维码进入
this.merchantId = this.getUrlKey('merchantId')
this.companyId = this.getUrlKey('companyId')
this.extendInfo = this.getUrlKey('extendInfo')
} else {
//扫小程序二维码进入
this.merchantId = option.merchantId
this.companyId = option.companyId
this.extendInfo = option.extendInfo
this.merchantId=this.$commonjs.getKey(option,'merchantId')
this.companyId=this.$commonjs.getKey(option,'companyId')
this.extendInfo=this.$commonjs.getKey(option,'extendInfo')
if(!this.extendInfo){
this.showMoney=true
}
if (uni.getStorageSync('openid')) {
this.openid = uni.getStorageSync('openid')
if (this.merchantId) {
//大商家的有merchantId
this.init()
this.initMerchant()
} else {
//小商家没有merchantId
this.initTwo()
this.initCompany()
}
this.initCoupon()
} else {
......@@ -205,13 +240,12 @@ export default {
methods: {
login() {
//---登录
let _this = this
uni.getProvider({
service: 'oauth',
success(proRes) {
success:proRes=>{
uni.login({
provider: proRes.provider[0],
success: function (res) {
success:res=>{
if (res.code) {
let source = ''
if (proRes.provider[0] == 'weixin') {
......@@ -222,30 +256,25 @@ export default {
let data = {
code: res.code,
source, //微信小程序3,支付宝小程序4
appid: uni.getStorageSync('appid') || ''
}
if (uni.getStorageSync('enterOptions').query) {
data.companyId = uni.getStorageSync('enterOptions').query.companyId || ''
appid: uni.getStorageSync('appid') || '',
companyId:this.companyId
}
_this.$request('wechat/wx/getUserInfoByCode', data).then(res => {
this.$request('wechat/wx/getUserInfoByCode', data).then(res => {
if (res.code == '00') {
_this.openid = res.data.openid
uni.setStorageSync('openid', _this.openid)
if (_this.merchantId) {
let openid = res.data.openid||''
uni.setStorageSync('openid', openid)
if (this.merchantId) {
//大商家的有merchantId
_this.init()
this.initMerchant()
} else {
//小商家没有merchantId
_this.initTwo()
this.initCompany()
}
_this.initCoupon()
this.initCoupon()
//用于获取token等信息
let userId = res.data.userId || ''
let openid = res.data.openid || ''
let datas = { openid, source, userId }
_this
.$request('wechatUser/login/findWxUserAndLogin', datas)
.then(res => {
this.$request('wechatUser/login/findWxUserAndLogin', datas).then(res => {
if (res.code == '00') {
let token = res.data.token || ''
uni.setStorageSync('token', token)
......@@ -259,14 +288,13 @@ export default {
icon: 'none'
})
}
})
.catch(err => {
}).catch(err => {
uni.showToast({
title: '登录失败',
icon: 'none'
})
_this.timer = setTimeout(() => {
_this.login()
this.timer = setTimeout(() => {
this.login()
}, 2000)
})
} else {
......@@ -275,14 +303,13 @@ export default {
icon: 'none'
})
}
})
.catch(err => {
}).catch(err => {
uni.showToast({
title: '登录失败',
icon: 'none'
})
_this.timer = setTimeout(() => {
_this.login()
this.timer = setTimeout(() => {
this.login()
}, 2000)
})
}
......@@ -291,19 +318,18 @@ export default {
}
})
},
getUrlKey(name) {
//---获取url
return (
(new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(decodeURIComponent(this.enterUrl)) || [, ''])[1].replace(/\+/g, '%20') || ''
)
//---数量改变时
numberChange(e){
let price=this.tollPoint.tollPointPrice
this.orderMoney=parseFloat((price*e.value).toFixed(2))
},
clickNum(i, index, a) {
//---输入数字
clickNum(i, index, a) {
//不超过14位数
if (this.buyMoney.length > 13) {
if (this.orderMoney.length > 13) {
return
}
this.buyMoney += i
this.orderMoney += i
this.leftList[index].child[a].background = '#dddddd'
setTimeout(() => {
this.leftList[index].child[a].background = ''
......@@ -313,9 +339,9 @@ export default {
this.initCoupon()
}, 1500)
},
clickEnter() {
//---退格
this.buyMoney = this.buyMoney.substr(0, this.buyMoney.length - 1)
clickEnter() {
this.orderMoney = this.orderMoney.substr(0, this.orderMoney.length - 1)
this.spaceBackground = '#dddddd'
setTimeout(() => {
this.spaceBackground = ''
......@@ -339,46 +365,63 @@ export default {
//---展示券列表
this.$refs.orderCoupon.showCoupon()
},
init() {
//---初始化获取商家名称,大商家
initMerchant() {
let data = {
merchantId: this.merchantId,
companyId: this.companyId
}
uni.showLoading({ title: '加载中', mask: true })
this.$request('scenic/order/findCodePayInfo', data)
.then(res => {
this.$request('scenic/order/findCodePayInfo', data).then(res => {
uni.hideLoading()
if (res.code == '00') {
this.name = res.data.name
this.companyName = res.data.name
} else {
uni.showToast({
title: res.message,
icon: 'none'
})
}
})
.catch(err => {
}).catch(err => {
uni.hideLoading()
})
},
initTwo() {
//---初始化获取商家名称,没有merchantId的小商家
initCompany() {
let data = {
id: this.companyId
id: this.companyId,//公司Id
tollPoint:this.extendInfo,//扩展信息
}
uni.showLoading({ title: '加载中', mask: true })
this.$request('user/company/detail', data)
.then(res => {
this.$request('user/newCompany/findCompanyById', data).then(res => {
uni.hideLoading()
if (res.code == '00') {
this.companyAttribute = res.data.companyVo.companyAttribute
this.companyAttribute = res.data.companyAttribute
this.paydJumpUrl = res.data.paydJumpUrl
if (this.companyAttribute == 5) {
//出租车显示联系人姓名,其他显示公司名称
this.name = res.data.companyVo.contactName
this.companyName = res.data.contactName
} else {
this.name = res.data.companyVo.companyName
this.companyName = res.data.companyName
}
let list=res.data.companyTollPointVoList
list.forEach(item=>{
if(item.tollPoints==this.extendInfo){
this.tollPoint=item
}
})
if(this.tollPoint.tollPointsModel==0){
//显示输入金额页面
this.showMoney=true
}
if(this.tollPoint.tollPointsModel==1){
//显示数量页面
this.backgroundColor='#ffffff'
this.showNumber=true
//默认总价为一张的价格
this.orderMoney=this.tollPoint.tollPointPrice
//优先取收费点名称,然后是公司名称,然后是联系人名称
this.companyName=this.tollPoint.tollPointByname||res.data.companyName||res.data.contactName
}
} else {
uni.showToast({
......@@ -386,8 +429,7 @@ export default {
icon: 'none'
})
}
})
.catch(err => {
}).catch(err => {
uni.hideLoading()
})
},
......@@ -397,11 +439,11 @@ export default {
this.chooseCouponObj = ''
this.ableConpon = ''
let data = {
money: parseFloat(this.buyMoney) || 0, //订单总价,不算券,和现金红包
money: parseFloat(this.orderMoney) || 0, //订单总价,不算券,和现金红包
merchantId: this.merchantId, //商户Id
companyId: this.companyId, //公司Id
orderSource: this.orderSource, //订单来源 8扫码支付
openid: this.openid
openid:uni.getStorageSync('openid')||''
}
this.$request('wechatUser/myPage/usableCouponList', data).then(res => {
if (res.code == '00') {
......@@ -447,7 +489,7 @@ export default {
},
clickPay() {
//---点击立即支付,获取支付需要的参数
if (!parseFloat(this.buyMoney)) {
if (!parseFloat(this.orderMoney)&&this.showMoney) {
uni.showToast({
title: '请输入正确金额',
icon: 'none'
......@@ -485,14 +527,22 @@ export default {
let data = {
companyId: this.companyId,
merchantId: this.merchantId,
userId: this.openid,
orderMoney: parseFloat(this.buyMoney),
userId: uni.getStorageSync('openid')||'',
orderMoney: parseFloat(this.orderMoney),//总价
buyNum:this.buyNum,//数量
payType: this.payType, //支付类型,
orderSource: this.orderSource, //订单来源 8扫码支付
couponList, //券列表
extendInfo: this.extendInfo ,//额外信息
remark:this.remark,//备注信息
extendInfo: this.extendInfo, //额外信息
remark: this.remark //备注信息
}
if(this.showMoney){
//输入金额页面
data.unitPrice=parseFloat(this.orderMoney)
}
if(this.showNumber){
//输入数量页面
data.unitPrice=this.tollPoint.tollPointPrice
}
this.payBackground = '#cccccc'
//重新加载优惠券
......@@ -533,7 +583,6 @@ export default {
},
goPay() {
//---去支付
let _this = this
// #ifdef MP-WEIXIN
uni.requestPayment({
provider: 'wxpay',
......@@ -542,15 +591,15 @@ export default {
package: this.package,
signType: this.signType,
paySign: this.paySign,
success: function (res) {
if (_this.companyAttribute == 5) {
success:res=>{
if (this.companyAttribute == 5) {
//出租车跳转分销组合票页面
uni.navigateTo({
url: _this.paydJumpUrl
url: this.paydJumpUrl
})
} else {
uni.navigateTo({
url: '/pages/payment/paySuccess/paySuccess?orderId=' + _this.orderId
url: '/pages/payment/paySuccess/paySuccess?orderId=' + this.orderId
})
}
},
......@@ -567,15 +616,15 @@ export default {
uni.requestPayment({
provider: 'alipay', // 服务提供商 支付宝支付: alipay 微信支付: wxpay
orderInfo: this.orderInfo, // 支付宝订单号
success: function (res) {
if (_this.companyAttribute == 5) {
success:res=>{
if (this.companyAttribute == 5) {
//出租车跳转分销组合票页面
uni.navigateTo({
url: _this.paydJumpUrl
url: this.paydJumpUrl
})
} else {
uni.navigateTo({
url: '/pages/payment/paySuccess/paySuccess?orderId=' + _this.orderId
url: '/pages/payment/paySuccess/paySuccess?orderId=' + this.orderId
})
}
},
......@@ -590,31 +639,31 @@ export default {
}
},
watch: {
buyMoney(val, oldVal) {
orderMoney(val, oldVal) {
if (val == '.' && oldVal == '') {
//首位数是小数点自动加上0
this.buyMoney = 0 + '.'
this.orderMoney = 0 + '.'
}
if (val == '0' && oldVal == '') {
//首位数是0自动加上小数点
this.buyMoney = 0 + '.'
this.orderMoney = 0 + '.'
}
if (val.length == 2) {
//防止回退之后出现01,02等状况
if (val.substr(0, 1) == 0 && val.substr(1, 2) != '.') {
this.buyMoney = val.substr(1, 2)
this.orderMoney = val.substr(1, 2)
}
}
if (isNaN(val) && val != '.') {
//出现非数字,输入无效
this.buyMoney = oldVal
this.orderMoney = oldVal
}
var x = String(this.buyMoney).indexOf('.') + 1 //小数点的位置
var y = String(this.buyMoney).length - x //小数的位数
var x = String(this.orderMoney).indexOf('.') + 1 //小数点的位置
var y = String(this.orderMoney).length - x //小数的位数
if (y > 2 && x > 0) {
this.buyMoney = oldVal
this.orderMoney = oldVal
}
if (parseFloat(this.buyMoney)) {
if (parseFloat(this.orderMoney)) {
this.payBackground = '#3688FF'
} else {
this.payBackground = '#cccccc'
......@@ -625,8 +674,8 @@ export default {
</script>
<style lang="scss">
// 输入金额页面样式
.bigBox {
background: #f5f5f5;
height: 100%;
}
/*上部分*/
......@@ -665,7 +714,7 @@ export default {
font-size: 32rpx;
font-weight: bold;
}
.moneyNumber{
.moneyNumber {
margin-top: 30rpx;
}
.moneyNumber text:nth-child(2) {
......@@ -792,4 +841,61 @@ export default {
opacity: 1;
}
}
//输入数字页面样式
.top2{
padding: 40rpx 24rpx;
}
.top2-name{
font-size: 32rpx;
font-weight: bold;
color: #191919;
text-align: center;
}
.top2-number{
display: flex;
justify-content: space-between;
font-weight: bold;
margin-top: 80rpx;
align-items: center;
}
.top2-price{
display: flex;
justify-content: space-between;
font-weight: bold;
margin-top: 48rpx;
text:nth-child(2){
font-size: 40rpx;
color: $red;
}
}
.top2-remark{
margin-top: 48rpx;
color: $grey;
}
.top2-tips{
margin-top: 24rpx;
color: $grey;
font-size: 24rpx;
}
.bottom2{
position: fixed;
width: 100%;
height: 100rpx;
display: flex;
align-items: center;
justify-content: center;
bottom: 0;
box-shadow: 0px -4px 12px 2px rgba(0,0,0,0.08);
background: #ffffff;
}
.btn{
display: flex;
align-items: center;
justify-content: center;
width: 90%;
height: 80rpx;
border-radius: 8rpx;
font-size: 32rpx;
font-weight: bold;
}
</style>
......@@ -57,14 +57,22 @@ export default {
let data = {
orderId: this.orderId
}
this.$request('order/order/getStatusById', data).then((res) => {
this.$request('order/userOrder/getStatusById', data).then((res) => {
if (res.code == '00') {
this.status = res.data
//如果是组合票,直接跳订单列表页面
let orderType=res.data.orderType
if(orderType=='10'){
uni.reLaunch({
url:this.afterBuyUrl+'?orderId=' + this.orderId+'&ifyukuaiCode='+this.ifyukuaiCode
})
return
}
this.status = res.data.orderStatus
if (this.status == '2' || this.status == '4' || this.status == '5') {
//1.跳订单列表,2.订单详情,3.停留该页面显示支付成功(ourPayment页面跳入时,无afterBuyUrl,停留在该页面)
this.title='支付成功!'
this.loadImg=false
uni.redirectTo({
uni.reLaunch({
url:this.afterBuyUrl+'?orderId=' + this.orderId+'&ifyukuaiCode='+this.ifyukuaiCode
})
}
......
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