This commit is contained in:
lixuan
2022-06-10 10:13:38 +08:00
parent 8534bd605e
commit 4ffb634e97
12 changed files with 284 additions and 7 deletions

View File

@@ -83,6 +83,15 @@
</view>
<text>{{ item.name }}</text>
</view>
<view class="cu-item" @tap="routerTo(cuIconList[9].path)">
<view :class="['cuIcon-' + cuIconList[9].cuIcon, 'text-' + cuIconList[9].color]" class="text-sl">
<view class="cu-tag badge" v-if="cuIconList[9].badge != 0">
<block v-if="cuIconList[9].badge != 9">
{{ cuIconList[9].badge > 99 ? '99+' : cuIconList[9].badge }}</block>
</view>
</view>
<text>{{ cuIconList[9].name }}</text>
</view>
<view class="cu-item" @tap="routerTo('/pages/station-price/station-price')">
<view :class="['cuIcon-' + cuIconList[1].cuIcon, 'text-' + cuIconList[1].color]" class="text-sl">
<view class="cu-tag badge" v-if="cuIconList[1].badge != 0">
@@ -269,7 +278,13 @@
badge: 0,
name: '交易统计'
},
{
cuIcon: 'refund',
path: '/oilPricesReported/oilPricesReported',
color: 'purple',
badge: 0,
name: '油价上报'
},
]
};

View File

@@ -135,6 +135,8 @@
url = '/pages/stationDetail/ZYSite?type=RIRISHUN'
} else if (res.indexOf('OP') != -1 ){
url = '/pages/stationDetail/openStationDetail'
}else if (res.indexOf('confirmerCode')!=-1){
url = '/pages/stationDetail/ZYSite?type=ANNENG'
}else{
uni.showToast({
title: '未知二维码',

View File

@@ -58,7 +58,7 @@
</view>
<view class="newdirvercard_name ">
<view class="newdirvercard_name_text ">{{ type=='RIRISHUN'? '日日顺司机': type=='shunfeng'?'顺丰司机': siteData.customerName}}</view>
<view class="newdirvercard_name_phone ">{{ type=='RIRISHUN'? '保密': type=='shunfeng'?'保密': siteData.customerPhone}}</view>
<view class="newdirvercard_name_phone " v-if="type!='ANNENG'">{{ type=='RIRISHUN'? '保密': type=='shunfeng'?'保密': siteData.customerPhone}}</view>
</view>
</view>
<view class="newdirvercard_right">
@@ -373,7 +373,7 @@
}
},
onLoad(option) {
console.log(option) //接收option.type
console.log(option) //接收option.type
if (option.user == 'kl') {
let code = uni.getStorageSync('qrCode'),
orderId = code.slice(0, -3)
@@ -647,6 +647,10 @@
this.FyOrder()
return
}
if (this.type == 'ANNENG') {
this.NnOrder()
return
}
if (this.testResult) {
if (this.qrCode.substring(0, 4) == 'XING') {
this.saveZeyiOrder()
@@ -742,6 +746,83 @@
}, 400)
}
}
})
},//安能
NnOrder() {
const data7 = {
qrCode: uni.getStorageSync('qrCode'), //类型String 必有字段 二维码 qrcode
orderSource: "WECHAT_MINIAPPS",
siteId: this.siteData.siteId, //类型String 必有字段 油站id siteId
priceId: this.insertResult.priceId, //类型String 必有字段 油价id priceId
companyId: this.siteData.companyId, //类型String 必有字段 企业id companyId
customerId: this.siteData.customerId, //类型String 必有字段 司机id customerId
volume: parseFloat(this.insertResult.vol), //类型number 必有字段 升数 volume,
vehicleLicenseNum: this.carNumber,
version: 1, //类型Number 必有字段 备注:版本号
xoilAmountGun: this.insertResult.vol, //类型String 必有字段 备注:加油升数
}
console.log(data7)
if (!data7.qrCode) {
uni.showToast({
title: 'qrCode为空',
icon: 'none'
});
return false
}
if (!data7.siteId) {
uni.showToast({
title: '请选择油站id',
icon: 'none'
});
return false
}
if (!data7.companyId) {
uni.showToast({
title: '请选择企业id',
icon: 'none'
});
return false
}
if (!data7.customerId) {
uni.showToast({
title: '请选择司机id',
icon: 'none'
});
return false
}
if (!data7.volume) {
uni.showToast({
title: '请输入加油体积',
icon: 'none'
});
return false
}
oliSiteApi.AnPay(data7).then(res => {
if (res.code === 20000) {
uni.showToast({
title: '下单成功!'
});
uni.setStorageSync('orderInfo', data7)
console.log(res.data.orderId)
let orderId = res.data.orderId
// this.checkSf(res.data.orderId)
this.gotoOrderStatus(res.data)
// uni.setStorageSync('formQr', true)
// uni.setStorageSync('orderSource', 'mpxoil')
// if (!this.isG7) {
// setTimeout(() => {
// this.toDetails(res.data.orderId)
// }, 400)
// } else {
// this.beforePay = false
// setTimeout(() => {
// this.orderId = res.data.orderId
// this.queryTimer()
// this.getPayStatus(this.orderId)
// }, 400)
// }
}
})
},