@@ -13,7 +13,41 @@ | |||
}}</view> | |||
</view> | |||
</view> | |||
<!-- <view class="register-main"> | |||
<view class="title">请输入验证码</view> | |||
<view class="hint">验证码已发送至:{{ phone }}</view> | |||
<view class="input-code"> | |||
<verification-code-input v-model="code" ></verification-code-input> | |||
</view> | |||
<view class="hint2"> | |||
<view class="green">{{ codeDuration === 0 ? "" : codeDuration }}</view> | |||
<view class="grey" @click="sendRegisterCode">{{ | |||
codeDuration === 0 ? "重新发送验证码" : "秒后可重新发送验证码" | |||
}}</view> | |||
</view> | |||
</view> --> | |||
<u-form ref="myForm"> | |||
<view class="from"> | |||
<u-form-item prop="phone"> | |||
<view class="from_item" style="background-color: #f7f7f7"> | |||
<text><text style="color: red"></text>手机号:</text> | |||
<u-input v-model="phone" :disabled="true" class="input" /> | |||
</view> | |||
</u-form-item> | |||
<u-form-item prop="code"> | |||
<view class="from_item"> | |||
<text><text style="color: red"></text>验证码:</text> | |||
<u-input v-model="code" placeholder="请输入验证码" class="input" /> | |||
<view class="hint2"> | |||
<view class="green">{{ codeDuration === 0 ? "" : codeDuration }}</view> | |||
<view class="grey" @click="sendRegisterCode">{{ | |||
codeDuration === 0 ? "发送验证码" : "秒后可重发" | |||
}}</view> | |||
</view> | |||
</view> | |||
</u-form-item> | |||
</view> | |||
</u-form> | |||
<view class="btn"> | |||
<submit-button title="下一步" @submit="nextStep"></submit-button> | |||
</view> |
@@ -253,7 +253,7 @@ const selectConfirm = (item: any) => { | |||
const rechargeAction = () => { | |||
state.fee = state.money * 100; //元换成分 | |||
wx.showModal({ | |||
uni.showModal({ | |||
title: '圈存确认', | |||
content: '您确定要充值圈存吗', | |||
success: function (res) { | |||
@@ -754,7 +754,7 @@ const selectConfirm = (item: any) => { | |||
const aliPayment = () => { | |||
// #ifdef MP-ALIPAY | |||
my.getAuthCode({ | |||
scopes: 'auth_user', | |||
scopes: 'auth_base', | |||
success: res => { | |||
const optionsUser = { | |||
type: 2, | |||
@@ -774,7 +774,7 @@ const selectConfirm = (item: any) => { | |||
wxOpenId: data.openId, | |||
cardId: state.cardId, | |||
orderNum: state.orderNum, | |||
payConfigId: wechatPayConfigId, | |||
payConfigId: "6a9a54123456578934edfre132b1234", | |||
body: "储值卡充值", | |||
}, | |||
method: "POST", | |||
@@ -784,7 +784,7 @@ const selectConfirm = (item: any) => { | |||
const data = stringToJson(res.bizContent); | |||
my.tradePay ({ | |||
// 调用统一收单交易创建接口(alipay.trade.create),获得返回字段支付宝交易号 trade_no | |||
tradeNO: data.prepayId, | |||
tradeNO: data.tranPackage, | |||
success: res => { | |||
console.log("支付成功", res); | |||
checkOrder(); |
@@ -234,9 +234,13 @@ | |||
console.log('======获取OBU号======') | |||
let cmdArray = [cmd.HOME_DIRECTORY, cmd.OBU_SYSTEM_FILE, cmd.RANDOM_NUMBER]; | |||
tools.showLoadingAlert("正在执行指令"); | |||
console.log('======cmdArray======',cmdArray) | |||
bluetoothUtil.transCmd(cmdArray, "20", function(res) { | |||
console.log('======cmdArray1======',cmdArray) | |||
tools.hideLoadingAlert(); | |||
console.log('======cmdArray2======',cmdArray) | |||
var status = res[1].substring(res[1].length - 4, res[1].length); | |||
console.log('获取OBU号执行结果' + status) | |||
//第一次获取随机数 | |||
if (status == "9000") { |
@@ -309,7 +309,8 @@ | |||
paySign: data.sign, | |||
success: function(e) { | |||
console.log("支付成功", e); | |||
checkOrder(); | |||
const dataaa = stringToJson(res.bizContent); | |||
checkOrder(dataaa.orderId); | |||
}, | |||
fail: function(err) { | |||
confirm(err, () => {}, "支付失败", false); | |||
@@ -317,61 +318,83 @@ | |||
}); | |||
}); | |||
// #endif | |||
// #ifdef MP-ALIPAY | |||
my.getAuthCode({ | |||
scopes: 'auth_user', | |||
success: res => { | |||
const optionsUser = { | |||
type: 2, | |||
data: { | |||
payConfigId: aliPayConfigId, | |||
code: res.authCode | |||
}, | |||
method: "POST", | |||
showLoading: true, | |||
}; | |||
console.log('支付宝用户编号请求:',optionsUser) | |||
request(obtainUserId, optionsUser).then((res) => { | |||
console.log('支付宝用户编号返回:',res) | |||
const data = stringToJson(res.bizContent); | |||
const optionsali = { | |||
type: 2, | |||
data: { | |||
openid: data.openId, | |||
suppleNoList: state.suppleNoList, | |||
totalFee: allPrice.value * 100, | |||
payConfigId: aliPayConfigId, | |||
}, | |||
method: "POST", | |||
showLoading: true, | |||
}; | |||
console.log('支付下单请求:',optionsali) | |||
request(CardBillPlaceOrder, optionsali).then((res) => { | |||
console.log('支付下单返回:',res) | |||
const data = stringToJson(res.bizContent); | |||
state.orderId = data.orderId | |||
my.tradePay ({ | |||
// 调用统一收单交易创建接口(alipay.trade.create),获得返回字段支付宝交易号 trade_no | |||
tradeNO: data.prepayId, | |||
success: res => { | |||
console.log("支付成功", res); | |||
checkOrder(); | |||
}, | |||
fail: res => { | |||
confirm(res, () => {}, "支付失败", false); | |||
}, | |||
}); | |||
// #ifdef MP-ALIPAY | |||
my.getAuthCode({ | |||
scopes: 'auth_base', | |||
success: res => { | |||
const optionsUser = { | |||
type: 2, | |||
data: { | |||
payConfigId: aliPayConfigId, | |||
code: res.authCode | |||
}, | |||
method: "POST", | |||
showLoading: true, | |||
}; | |||
console.log('支付宝用户编号请求:',optionsUser) | |||
request(obtainUserId, optionsUser).then((res) => { | |||
console.log('支付宝用户编号返回:',res) | |||
const data = stringToJson(res.bizContent); | |||
const optionsali = { | |||
type: 2, | |||
data: { | |||
openid: data.openId, | |||
suppleNoList: state.suppleNoList, | |||
totalFee: allPrice.value * 100, | |||
payConfigId: "6a9a54123456578934edfre132b1234", | |||
}, | |||
method: "POST", | |||
showLoading: true, | |||
}; | |||
console.log('支付下单请求:',optionsali) | |||
request(CardBillPlaceOrder, optionsali).then((res) => { | |||
console.log('支付下单返回:',res) | |||
const data = stringToJson(res.bizContent); | |||
my.tradePay ({ | |||
// 调用统一收单交易创建接口(alipay.trade.create),获得返回字段支付宝交易号 trade_no | |||
tradeNO: data.tranPackage, | |||
success: res => { | |||
console.log("支付成功", res); | |||
const dataaa = stringToJson(res.bizContent); | |||
allPrice.value = 0 | |||
}); | |||
}); | |||
}, | |||
fail: err => { | |||
console.log('my.getAuthCode 调用失败', err) | |||
} | |||
}); | |||
// #endif | |||
const options = { | |||
type: 2, | |||
data: { | |||
opId: getItem('openId') | |||
}, | |||
method: "POST", | |||
showLoading: true, | |||
}; | |||
request(CardBillQuery, options).then((res) => { | |||
const data = stringToJson(res.bizContent); | |||
console.log(data); | |||
data.data = data.data.map(val => { | |||
val.checked = false | |||
val.fee = val.fee / 100 | |||
val.totalFee = val.totalFee / 100 | |||
val.serviceFee = val.serviceFee / 100 | |||
return val | |||
}) | |||
state.list = data.data | |||
console.log(state.list, "我是处理后得列表"); | |||
}) | |||
}, | |||
fail: res => { | |||
console.log("支付失败", res); | |||
}, | |||
}); | |||
}); | |||
}); | |||
}, | |||
fail: err => { | |||
console.log('my.getAuthCode 调用失败', err) | |||
} | |||
}); | |||
// #endif | |||
} else { | |||
msg("未勾选补缴订单!") | |||
} | |||
@@ -381,11 +404,11 @@ | |||
//支付成功改变订单状态 | |||
const checkOrder = () => { | |||
const checkOrder = (orderId) => { | |||
const options = { | |||
type: 2, | |||
data: { | |||
orderId: state.orderId, | |||
orderId: orderId, | |||
}, | |||
method: "POST", | |||
showLoading: true, |
@@ -1,7 +1,7 @@ | |||
<template> | |||
<view class="content"> | |||
<view class="value"> | |||
尊敬的用户: 一旦注销九州ETC会员账号,您将无法通过九州ETC小程序、九州ETC公众号等会员登录渠道查看及找回账户相 | |||
尊敬的用户: 一旦注销九州ETC会员账号,您将无法通过九州ETC小程序、九州ETC公众号等会员登录渠道查看及找回账户 | |||
</view> | |||
<view class="subBtn"> | |||
<submit-button title="注销账户" form-type="submit" @submit="formSubmit"> |
@@ -11,32 +11,41 @@ | |||
<t-td>记账副卡当日开卡数</t-td> | |||
<t-td>记账卡累计发卡数</t-td> | |||
</t-tr> | |||
<t-tr v-for="(item,index) in dataAll.vehicleData.vehicleDataDetails" :key="index" fontSize="12"> | |||
<t-tr v-if="dataAll.vehicleData" v-for="(item,index) in dataAll.vehicleData.vehicleDataDetails" :key="index" fontSize="12"> | |||
<t-td>{{ item.vehicleType }}</t-td> | |||
<t-td>{{ item.dayCardCount }}</t-td> | |||
<t-td>{{ item.cardCount }}</t-td> | |||
</t-tr> | |||
<t-tr font-size="12"> | |||
<t-td>合计</t-td> | |||
<t-td>{{ dataAll.vehicleData.vehicleDataCount.dayCardCount }}</t-td> | |||
<t-td>{{ dataAll.vehicleData.vehicleDataCount.cardCount }}</t-td> | |||
<t-td>{{ dataAll.vehicleData? dataAll.vehicleData.vehicleDataCount.dayCardCount:null }}</t-td> | |||
<t-td>{{ dataAll.vehicleData? dataAll.vehicleData.vehicleDataCount.cardCount:null }}</t-td> | |||
</t-tr> | |||
</t-table> | |||
</view> | |||
<!-- 改变类型和时间 --> | |||
<view class="change_type"> | |||
<uni-data-select v-model="selectTypeValue" :localdata="typeRange" @change="changeType" | |||
<uni-data-select v-if="!isAli" v-model="selectTypeName" :localdata="typeRange" @change="changeType" | |||
:clear="false"></uni-data-select> | |||
<view class='time'> | |||
<uni-datetime-picker type="date" :clear-icon="false" v-model="dateTime" @change="change" | |||
<uni-datetime-picker v-if="!isAli" type="date" :clear-icon="false" v-model="dateTime" @change="change" | |||
@show="showTan" @close="closeTan" /> | |||
<!-- <button class="page-body-button" v-if="isAli" type="primary" @click="aliDate()">选择日期:yyyy-MM-dd</button> --> | |||
<view v-if="isAli" class="info_plate"> | |||
<text>日期</text> | |||
<u-input v-model="dateTime" @click="aliDate" class="input" disabled placeholder="请选择日期" /> | |||
<!-- <u-icon name="arrow-right" @click="aliDate" style="margin-left: 10px;display: flex;"></u-icon> --> | |||
</view> | |||
</view> | |||
</view> | |||
<view v-if="pieData !={} || chartData !={} || lineData !={} "> | |||
<view v-if=" isShow===0 "> | |||
<view class=" title title_pie"> | |||
<view class="choice_item1"><uni-data-select v-model="selectPieValue" :localdata="pieRange" | |||
@change="changePie" :clear="false"></uni-data-select></view> | |||
<view class="choice_item1"><uni-data-select v-if="!isAli" v-model="selectPieValue" :localdata="pieRange" | |||
@change="changePie" :clear="false"> | |||
</uni-data-select></view> | |||
</view> | |||
<view class="charts-box" v-if="hideCanvas"> | |||
<qiun type="pie" :opts="opts" :chartData="pieData" /> | |||
@@ -64,6 +73,7 @@ | |||
</view> | |||
<!-- <view v-else>暂无数据统计信息</view> --> | |||
<u-select v-model="selectTypeName" :list="typeRange" @confirm="selectConfirm"></u-select> | |||
</view> | |||
</template> | |||
@@ -92,9 +102,10 @@ | |||
export default { | |||
data() { | |||
return { | |||
isAli: false, | |||
hideCanvas: false, | |||
canvasShow: false, | |||
dateTime: Date.now(), //日期 | |||
dateTime: "", //日期 | |||
noDealDateTime: '', //没有处理过的时间,传给后端 | |||
dealDateTime: [], //处理过后的时间,前端展示 | |||
dataAll: '', //总的数据 | |||
@@ -200,7 +211,14 @@ | |||
qiun | |||
}, | |||
onLoad() { | |||
// #ifdef MP-ALIPAY | |||
this.isAli = true | |||
// #endif | |||
// #ifdef MP-WEIXIN | |||
this.isAli = false | |||
// #endif | |||
this.noDealDateTime = nowDate(new Date()); | |||
this.dateTime = nowDate(new Date()); | |||
// this.noDealDateTime='2023-04-17'; | |||
this.dealDateTime = nowDate(new Date()).split('-'); | |||
this.reqPie(); //饼状图数据请求 | |||
@@ -293,14 +311,18 @@ | |||
.then((res) => { | |||
tools.hideLoadingAlert(); | |||
this.dataAll = stringToJson(res.bizContent); | |||
if (this.dataAll.cardData) { | |||
console.log("this.dataAll", this.dataAll) | |||
this.dealPieData(stringToJson(res.bizContent)); //处理饼状图数据 | |||
this.getPieData(this.pieDataAll[0]); //饼状图展示 | |||
this.dealLineData(stringToJson(res.bizContent)); //处理折线图数据 | |||
this.getLineData(this.lineDataAll[0]); //折线图展示 | |||
this.dealColData(stringToJson(res.bizContent)) //处理柱状图数据 | |||
this.getColumnData(this.colData.xData, this.colData.yData[0]); //柱状图 | |||
try{ | |||
if (this.dataAll.cardData) { | |||
console.log("this.dataAll", this.dataAll) | |||
this.dealPieData(stringToJson(res.bizContent)); //处理饼状图数据 | |||
this.getPieData(this.pieDataAll[0]); //饼状图展示 | |||
this.dealLineData(stringToJson(res.bizContent)); //处理折线图数据 | |||
this.getLineData(this.lineDataAll[0]); //折线图展示 | |||
this.dealColData(stringToJson(res.bizContent)) //处理柱状图数据 | |||
this.getColumnData(this.colData.xData, this.colData.yData[0]); //柱状图 | |||
} | |||
}catch(error){ | |||
console.log(error.name + ":" + error.message ) | |||
} | |||
}) | |||
}, | |||
@@ -450,7 +472,23 @@ | |||
// this.canvasShow = getItem("show") | |||
}, | |||
} | |||
aliDate(){ | |||
my.datePicker({ | |||
success: (res) => { | |||
console.log("您选择的日期为:"+res.date) | |||
this.dateTime = res.date; | |||
console.log("您选择的日期为:"+ this.dateTime) | |||
this.dealDateTime = res.date.split('-'); | |||
console.log("您选择的日期为:"+ this.dealDateTime) | |||
this.noDealDateTime = res.date; | |||
console.log("您选择的日期为:"+ this.noDealDateTime) | |||
this.reqPie(); | |||
}, | |||
}); | |||
} | |||
}, | |||
}; | |||
</script> | |||
@@ -499,7 +537,15 @@ | |||
.uni-stat__select { | |||
width: 40% !important; | |||
} | |||
.info_plate { | |||
display: flex; | |||
flex-direction: row; | |||
width: 94%; | |||
height: 100rpx; | |||
margin: 0 auto; | |||
border-bottom: 2rpx solid #f2f2f2; | |||
} | |||
.title_pie { | |||
display: flex; | |||
justify-content: flex-end; | |||
@@ -527,6 +573,7 @@ | |||
width: 40%; | |||
} | |||
.title_name { | |||
width: 95%; | |||
font-weight: 600; |