DESKTOP-2IO5MST\huting 1 рік тому
джерело
коміт
718bd1adec

+ 29
- 1
pages.json Переглянути файл

}, { }, {
"path": "pages/nfc/nfc", "path": "pages/nfc/nfc",
"style": { "style": {
"navigationBarTitleText": "NFC接",
"navigationBarTitleText": "NFC接",
"enablePullDownRefresh": false "enablePullDownRefresh": false
} }
}, { }, {
"enablePullDownRefresh": false "enablePullDownRefresh": false
} }
}, },
{
"path": "account-recharge/result",
"style": {
"navigationBarTitleText": "结果",
"enablePullDownRefresh": false
}
},
{ {
"path": "account-recharge/recharge-record", "path": "account-recharge/recharge-record",
"style": { "style": {
{ {
"root": "subpackage/personal-center", //个人中心 "root": "subpackage/personal-center", //个人中心
"pages": [{ "pages": [{
"path": "trapping-and-repairing-account/result",
"style": {
"navigationBarTitleText": "修复成功",
"enablePullDownRefresh": false
}
},
{
"path": "trapping-and-repairing-account/recharge-two",
"style": {
"navigationBarTitleText": "圈存",
"enablePullDownRefresh": false
}
},
{
"path": "trapping-and-repairing-account/recharge-pay",
"style": {
"navigationBarTitleText": "去修复",
"enablePullDownRefresh": false
}
},
{
"path": "trapping-and-repairing/result", "path": "trapping-and-repairing/result",
"style": { "style": {
"navigationBarTitleText": "修复成功", "navigationBarTitleText": "修复成功",

+ 5
- 1
pages/bluetooth/bluetooth.vue Переглянути файл

}; };


function oks() { function oks() {
//routeType 1.激活(订单来) 2.圈存 (/pages/recharge/recharge来)3.ping码解锁 4.信息读取 5从哪里来回哪里去监听bluetoothLink 7消费明细去圈存 8单位账户圈存
//routeType 1.激活(订单来) 2.圈存 (/pages/recharge/recharge来)3.ping码解锁 4.信息读取 5从哪里来回哪里去监听bluetoothLink 7消费明细去圈存 8单位账户圈存 9对公账户修复
if (routeType.value == "1") { if (routeType.value == "1") {
uni.navigateTo({ uni.navigateTo({
url: `/subpackage/after-sale/activation/activate?transfer=${state.transfer}`, url: `/subpackage/after-sale/activation/activate?transfer=${state.transfer}`,
uni.navigateTo({ uni.navigateTo({
url: `/subpackage/after-sale/account-recharge/recharge-weixin?accountId=${state.accountId}`, url: `/subpackage/after-sale/account-recharge/recharge-weixin?accountId=${state.accountId}`,
}); });
} else if (routeType.value == "9") {
uni.navigateTo({
url: `/subpackage/personal-center/trapping-and-repairing-account/recharge-two?rechargeMoney=${state.rechargeMoney}&&orderNum=${state.orderNum}&&payMoney=${state.payMoney}`,
});
} else { } else {
return; return;
} }

+ 3
- 1
pages/nfc/nfc.vue Переглянути файл

NFCAPI.startScanDevice((res) => { NFCAPI.startScanDevice((res) => {
tools.hideLoadingAlert(); tools.hideLoadingAlert();
if (res.code != 0) { if (res.code != 0) {
console.log("1111111")
if (res.code == 1203) { if (res.code == 1203) {
tools.showModalAlert("扫描超时请重新扫描NFC标签", function(res) { tools.showModalAlert("扫描超时请重新扫描NFC标签", function(res) {
if (res.confirm) { if (res.confirm) {
} }
return; return;
} else { } else {
console.log("2222")
NFCAPI.connectDevice(function() { NFCAPI.connectDevice(function() {
if (res.code != 0) { if (res.code != 0) {
tools.showToastAlert(res.msg); tools.showToastAlert(res.msg);
getCardId(items, function() { getCardId(items, function() {
if (routeType.value == "2") { if (routeType.value == "2") {
tools.toUrl( tools.toUrl(
`/pages/recharge/recharge?connectSuccess=1&&cardId=${state.cardId}&&fee=${state.fee}&&transWay=nfc`
`/pages/recharge/recharge-weixin?connectSuccess=1&&cardId=${state.cardId}&&fee=${state.fee}&&transWay=nfc`
); //跳转到圈存界面 ); //跳转到圈存界面
} }
}) })

+ 1
- 1
static/nfc/NFCManagerTool.js Переглянути файл



function initNfcAdapter(callBack) { function initNfcAdapter(callBack) {
// #ifdef MP-ALIPAY // #ifdef MP-ALIPAY
nfcAdapter = my.getNFCAdapter() //获取NFC适配器实例
// nfcAdapter = my.getNFCAdapter() //获取NFC适配器实例
// #endif // #endif
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
nfcAdapter = wx.getNFCAdapter() //获取NFC适配器实例 nfcAdapter = wx.getNFCAdapter() //获取NFC适配器实例

+ 32
- 6
subpackage/after-sale/account-recharge/consumption-record.vue Переглянути файл

@click='search()'>搜索</button> @click='search()'>搜索</button>
</view> </view>
<view class='item' v-for="(item,index) in state.newList"> <view class='item' v-for="(item,index) in state.newList">
<view class='time'><text>时间:{{item.tradeConfirmTime}}</text><text>¥{{item.fee/100}}</text></view>
<view>银行卡号:{{item.bankCardId}}</view>
<view class='time'><text>时间:{{item.tradeTime}}</text><text>¥{{item.fee/100}}</text></view>
<view>对公账户:{{item.corporateAccountId}}</view>
<!-- item.status 1 圈存成功 0 半条 -->
<!-- <view class="but-wrap" v-if="item.status ==0">
<text @click="toTrap(item.fee)">修复</text>
</view> -->
</view> </view>
</view> </view>
</template> </template>
import { transactionRecord } from "@/utils/network/api.js"; import { transactionRecord } from "@/utils/network/api.js";
import { stringToJson } from "@/utils/network/encryption.js"; import { stringToJson } from "@/utils/network/encryption.js";
import { onLoad } from "@dcloudio/uni-app"; import { onLoad } from "@dcloudio/uni-app";
import { getCodeName } from "@/datas/queryKey.js";
const state = reactive({ const state = reactive({
list: '', //所有数据 list: '', //所有数据
newList: '', //最终展示的 newList: '', //最终展示的
const options = { const options = {
type: 2, type: 2,
data: { data: {
'accountId': state.name
'accountId': state.name,
'accountTransactionType': 1
}, },
method: "POST", method: "POST",
showLoading: true, showLoading: true,
request(transactionRecord, options).then((res) => { request(transactionRecord, options).then((res) => {
const data = stringToJson(res.bizContent); const data = stringToJson(res.bizContent);
state.list = data.qtkCorporateAccountDetails; state.list = data.qtkCorporateAccountDetails;
for (var i = 0; i < state.list.length; i++) {
state.list[i].tradeConfirmTime = state.list[i].tradeConfirmTime.split('T').join(' ');
}
state.newList = state.list; state.newList = state.list;
console.log("交易记录", data) console.log("交易记录", data)
}) })
const doSearch = () => { const doSearch = () => {
search(); search();
} }
const toTrap = (rechargeMoney) => {
uni.navigateTo({
url: `/subpackage/personal-center/trapping-and-repairing-account/recharge-pay?rechargeMoney=${rechargeMoney}&&payMoney=0`
})
}
</script> </script>


<style scoped> <style scoped>
margin-bottom: 16rpx; margin-bottom: 16rpx;
justify-content: space-between; justify-content: space-between;
} }

.but-wrap {
display: flex;
justify-content: flex-end;
margin-top: 10rpx;
}

.but-wrap>text {
border: 1px solid white;
color: white;
height: 50rpx;
line-height: 50rpx;
border-radius: 30rpx;
padding: 0 24rpx;
font-size: 28rpx;
box-sizing: border-box;
margin-left: 12rpx;
}
</style> </style>

+ 2
- 2
subpackage/after-sale/account-recharge/login.vue Переглянути файл

<view class="content"> <view class="content">
<view class="item"> <view class="item">
<text>对公用户:</text> <text>对公用户:</text>
<input class="uni-input" focus placeholder="请输入用户名" v-model='state.name' />
<input class="uni-input" placeholder="请输入用户名" v-model='state.name' />
</view> </view>
<view class="item"> <view class="item">
<text>对公用户密码:</text> <text>对公用户密码:</text>
<input style='width:412rpx;' class="uni-input" focus placeholder="请输入对公用户密码" v-model='state.password'
<input style='width:412rpx;' class="uni-input" placeholder="请输入对公用户密码" v-model='state.password'
type='password' /> type='password' />
</view> </view>
<button @click='login()'>登录</button> <button @click='login()'>登录</button>

+ 3
- 2
subpackage/after-sale/account-recharge/recharge-record.vue Переглянути файл

const options = { const options = {
type: 2, type: 2,
data: { data: {
'accountId': state.name
'accountId': state.name,
'accountTransactionType': 0
}, },
method: "POST", method: "POST",
showLoading: true, showLoading: true,
const data = stringToJson(res.bizContent); const data = stringToJson(res.bizContent);
state.list = data.qtkCorporateAccountDetails; state.list = data.qtkCorporateAccountDetails;
for (var i = 0; i < state.list.length; i++) { for (var i = 0; i < state.list.length; i++) {
state.list[i].tradeConfirmTime = state.list[i].tradeConfirmTime.split('T').join(' ');
// state.list[i].tradeConfirmTime = state.list[i].tradeConfirmTime.split('T').join(' ');
} }
state.newList = state.list; state.newList = state.list;
console.log("交易记录", data) console.log("交易记录", data)

+ 12
- 23
subpackage/after-sale/account-recharge/recharge-weixin.vue Переглянути файл

}], }],
tableIndex: 0, tableIndex: 0,
openid: "", openid: "",
connectSuccess: undefined,
fee: 5000, fee: 5000,
money: 50, money: 50,
orderNum: "", orderNum: "",
transWayName: "蓝牙",
transWay: "blu", //“blu”为蓝牙充值方式、“nfc”为NFC充值方式 transWay: "blu", //“blu”为蓝牙充值方式、“nfc”为NFC充值方式
cardId: "", //卡号 需要传参 cardId: "", //卡号 需要传参
mockpreBalance: 2000, //fix:模拟余额 目前没有检测状态接口,第一次会模拟圈存检测来检测状态 mockpreBalance: 2000, //fix:模拟余额 目前没有检测状态接口,第一次会模拟圈存检测来检测状态
show: false, show: false,
items: [{
value: '0',
name: '微信',
checked: 'true'
},
{
value: '1',
name: '对公账户'
}
],
current: 0, current: 0,
tradeType: 14, tradeType: 14,
accountId: "",//对公账户id accountId: "",//对公账户id
accountMoney: 0 //对公账户余额
accountMoney: 0, //对公账户余额
consumeId: "",//消费订单编号
}); });


const selectConfirm = (item : any) => {
state.transWayName = item[0].label
state.transWay = item[0].value
};
//读卡信息 //读卡信息
const card : any = reactive({ const card : any = reactive({
cardId: "", cardId: "",
quanApplyAction(dic).then((value : any) => { quanApplyAction(dic).then((value : any) => {
console.log("圈存申请完后的结果"); console.log("圈存申请完后的结果");
console.log(value.commandType, value); console.log(value.commandType, value);
state.consumeId = value.consumeId
//圈存初始化验证通过 , 进行圈存 //圈存初始化验证通过 , 进行圈存
if (value.commandType === 2) { if (value.commandType === 2) {
uanConfirmAction(value); uanConfirmAction(value);
}; };
uni.hideLoading(); uni.hideLoading();
quanApplyAction(dic).then((values) => { quanApplyAction(dic).then((values) => {
state.consumeId = values.consumeId
console.log("圈存申请完后的结果"); console.log("圈存申请完后的结果");
uanConfirmAction(values); uanConfirmAction(values);
}); });
}; };
console.log("消费成功"); console.log("消费成功");
quanApplyAction(applyDic).then((applyValue) => { quanApplyAction(applyDic).then((applyValue) => {
state.consumeId = applyValue.consumeId
uanConfirmAction(applyValue); uanConfirmAction(applyValue);
}); });
} }
} else if (fixStatus === 2) { } else if (fixStatus === 2) {
uanConfirmSucessAction(value).then((confirmResult) => { uanConfirmSucessAction(value).then((confirmResult) => {
console.log("充值成功") console.log("充值成功")
getCardId(1)
setTimeout(() => { setTimeout(() => {
msg("充值成功"); msg("充值成功");
navTo(`./result?cardId=${card.cardId}`)
navTo(`/subpackage/after-sale/account-recharge/result?cardId=${card.cardId}`)
}, 2000) }, 2000)
}); });
} else if (fixStatus === 1) { } else if (fixStatus === 1) {
cardId: card.cardId, cardId: card.cardId,
fee: state.fee, fee: state.fee,
preBalance: card.money, preBalance: card.money,
tradeType: state.tradeType,
tradeType: 12,
command: data.command, command: data.command,
cosResponse: data.cosResponse, cosResponse: data.cosResponse,
orderId: state.orderNum, orderId: state.orderNum,
rechargeId: data.rechargeId, rechargeId: data.rechargeId,
openId: getItem(StorageKeys.OpenId)
openId: getItem(StorageKeys.OpenId),
accountId: state.accountId
}; };
const options = { const options = {
type: 2, type: 2,
rechargeId: data.rechargeId, rechargeId: data.rechargeId,
paidAmount: state.fee, paidAmount: state.fee,
giftAmount: 0, giftAmount: 0,
consumeId: state.consumeId
}; };
const options = { const options = {
type: 2, type: 2,
const res = await request(quanConfirm, options); const res = await request(quanConfirm, options);
const data = stringToJson(res.bizContent); const data = stringToJson(res.bizContent);
console.log("data充值成功", data); console.log("data充值成功", data);
getCardId(1)
// getCardId()
setTimeout(() => { setTimeout(() => {
msg("充值成功"); msg("充值成功");
navTo(`./result?cardId=${card.cardId}`)
navTo(`/subpackage/after-sale/account-recharge/result?cardId=${card.cardId}`)
}, 2000) }, 2000)
}).catch((error) => { }).catch((error) => {
console.log('输出内容', error) console.log('输出内容', error)

+ 1
- 1
subpackage/after-sale/activation/operation-tips.vue Переглянути файл

</view> </view>
<view class="hint"> <view class="hint">
<image :src="`${$imgUrl}common/icon-hint.png`" class="icon"></image> <image :src="`${$imgUrl}common/icon-hint.png`" class="icon"></image>
<view>激活时,需要录入您的车牌号和手机号,并确保OBU蓝牙和手机蓝牙处于打开状态。</view>
<view>激活时,确保OBU蓝牙和手机蓝牙处于打开状态。</view>
</view> </view>
<view class="btn"> <view class="btn">
<submit-button @submit="gotoNextStep" title="已知悉,下一步"></submit-button> <submit-button @submit="gotoNextStep" title="已知悉,下一步"></submit-button>

+ 1
- 1
subpackage/after-sale/deviceInfo/deviceInfo.vue Переглянути файл

<view class="info-card"> <view class="info-card">
<view class="title">OBU信息</view> <view class="title">OBU信息</view>
<view class="cell"> <view class="cell">
<view class="cell-left">序列号</view>
<view class="cell-left">obu号</view>
<view class="cell-right">{{ obu.num }}</view> <view class="cell-right">{{ obu.num }}</view>
</view> </view>
<view class="cell"> <view class="cell">

+ 4
- 3
subpackage/orders/editAddress.vue Переглянути файл

<u-input placeholder="名字" :customStyle="btnGetCode" v-model="state.formData.consignee" /> <u-input placeholder="名字" :customStyle="btnGetCode" v-model="state.formData.consignee" />
</u-form-item> </u-form-item>
<u-form-item label="手机号"> <u-form-item label="手机号">
<u-input placeholder="手机号" :customStyle="btnGetCode" type="number"
v-model="state.formData.consigneeTel" />
<u-input placeholder="手机号" :customStyle="btnGetCode" type="number" v-model="state.formData.consigneeTel"
maxlength="11" />
</u-form-item> </u-form-item>
<u-form-item label="所在地区"> <u-form-item label="所在地区">
<u-input :customStyle="btnGetCode" type="select" :select-open="state.show" <u-input :customStyle="btnGetCode" type="select" :select-open="state.show"
</u-form-item> </u-form-item>


<u-form-item label="详细地址"> <u-form-item label="详细地址">
<u-input placeholder="小区楼栋/乡村名称" :customStyle="textareaStyle" v-model="state.formData.address" />
<u-input placeholder="小区楼栋/乡村名称" :customStyle="textareaStyle" v-model="state.formData.address"
maxlength="100" />
</u-form-item> </u-form-item>
<u-form-item label="邮政编码"> <u-form-item label="邮政编码">
<u-input placeholder="邮政编码" :customStyle="btnGetCode" v-model="state.formData.postalCode" /> <u-input placeholder="邮政编码" :customStyle="btnGetCode" v-model="state.formData.postalCode" />

+ 0
- 24
subpackage/orders/opening-account-people.vue Переглянути файл

<u-input v-model="state.form.userName" placeholder='请输入姓名' :disabled="state.isEnableOCRData" <u-input v-model="state.form.userName" placeholder='请输入姓名' :disabled="state.isEnableOCRData"
maxlength="20" @input="replaceInput" /> maxlength="20" @input="replaceInput" />
</u-form-item> </u-form-item>

<!-- <u-form-item label="性别">
<u-input placeholder='请选择性别' v-model="state.form.gender" @click="userGenderAction()"
type="select" />
</u-form-item> -->
<u-form-item label="身份证号"> <u-form-item label="身份证号">
<u-input placeholder='请输入身份证' type="idcard" v-model="state.form.userIdNum" <u-input placeholder='请输入身份证' type="idcard" v-model="state.form.userIdNum"
:disabled="state.isEnableOCRData" maxlength="18" /> :disabled="state.isEnableOCRData" maxlength="18" />
<u-input placeholder='请输入地址' :autoHeight='true' v-model="state.form.address" <u-input placeholder='请输入地址' :autoHeight='true' v-model="state.form.address"
:disabled="state.isEnableOCRData" maxlength="100" /> :disabled="state.isEnableOCRData" maxlength="100" />
</u-form-item> </u-form-item>
<!-- <u-form-item label="证件有效期">
<u-input v-model="state.form.begindate" type="select" />
</u-form-item> -->
<u-form-item label="联系方式"> <u-form-item label="联系方式">
<u-input placeholder='请输入联系方式' type="number" v-model="state.form.tel" maxlength="11" /> <u-input placeholder='请输入联系方式' type="number" v-model="state.form.tel" maxlength="11" />
</u-form-item> </u-form-item>
<u-input inputAlign="right" placeholder='请输入姓名' v-model="state.form.userName" <u-input inputAlign="right" placeholder='请输入姓名' v-model="state.form.userName"
:disabled="state.isEnableOCRData" maxlength="20" /> :disabled="state.isEnableOCRData" maxlength="20" />
</u-form-item> </u-form-item>
<!-- <u-form-item label="性别">
<u-input inputAlign="right" placeholder='请选择性别' v-model="state.form.gender" type="select" />
</u-form-item> -->
<u-form-item label="身份证号"> <u-form-item label="身份证号">
<u-input inputAlign="right" placeholder='请输入身份证号' v-model="state.form.userIdNum" <u-input inputAlign="right" placeholder='请输入身份证号' v-model="state.form.userIdNum"
:disabled="state.isEnableOCRData" type="idcard" /> :disabled="state.isEnableOCRData" type="idcard" />
</u-form-item> </u-form-item>
<!-- <u-form-item label="">
<u-input v-model="state.form.userIdNum" />
</u-form-item> -->
<!-- <u-form-item label="证件有效期">
<u-input v-model="state.form.begindate" type="select" />
</u-form-item> -->
<u-form-item label="联系方式"> <u-form-item label="联系方式">
<u-input inputAlign="right" placeholder='请输入联系方式' v-model="state.form.tel" maxlength="11" /> <u-input inputAlign="right" placeholder='请输入联系方式' v-model="state.form.tel" maxlength="11" />
</u-form-item> </u-form-item>
<u-input inputAlign="right" placeholder='请输入经办人姓名' v-model="state.form.agentName" <u-input inputAlign="right" placeholder='请输入经办人姓名' v-model="state.form.agentName"
:disabled="state.isEnableOCRData" maxlength="20" /> :disabled="state.isEnableOCRData" maxlength="20" />
</u-form-item> </u-form-item>
<!-- <u-form-item label="性别">
<u-input v-model="state.form.agentGender" type="select" />
</u-form-item> -->
<u-form-item label="身份证号"> <u-form-item label="身份证号">
<u-input inputAlign="right" placeholder='请输入身份证号' v-model="state.form.agentIdNum" <u-input inputAlign="right" placeholder='请输入身份证号' v-model="state.form.agentIdNum"
:disabled="state.isEnableOCRData" maxlength="18" type="idcard" /> :disabled="state.isEnableOCRData" maxlength="18" type="idcard" />
</u-form-item> </u-form-item>
<!-- <u-form-item label="证件有效期">
<u-input v-model="state.form.begindate" type="select" />
</u-form-item> -->
<u-form-item label="联系方式"> <u-form-item label="联系方式">
<u-input inputAlign="right" placeholder='请输入联系方式' v-model="state.form.agentTel" type="number" <u-input inputAlign="right" placeholder='请输入联系方式' v-model="state.form.agentTel" type="number"
maxlength="11" /> maxlength="11" />
showLoading: true, showLoading: true,
}; };
request(etcUserCardInfoSubmit, options).then((res) => { request(etcUserCardInfoSubmit, options).then((res) => {
// let result = stringToJson(res.bizContent);
console.log(res); console.log(res);
uni.redirectTo({ uni.redirectTo({
url: `/subpackage/orders/car-release?orderId=${state.orderId}&vehiclePlateColor=${state.vehiclePlateColor}&type=${state.type}&isSign=${state.isSign}`, url: `/subpackage/orders/car-release?orderId=${state.orderId}&vehiclePlateColor=${state.vehiclePlateColor}&type=${state.type}&isSign=${state.isSign}`,

+ 8
- 0
subpackage/orders/order_payment.vue Переглянути файл

state.dataArray[i].payName = '预存金' state.dataArray[i].payName = '预存金'
} else if (state.dataArray[i].payType === 'EQUITY') { } else if (state.dataArray[i].payType === 'EQUITY') {
state.dataArray[i].payName = '权益费' state.dataArray[i].payName = '权益费'
} else if (state.dataArray[i].payType === 'REPAIROBU') {
state.dataArray[i].payName = '增补obu'
} else if (state.dataArray[i].payType === 'CHANGECARD') {
state.dataArray[i].payName = '更换卡'
} else if (state.dataArray[i].payType === 'CHANGEOBU') {
state.dataArray[i].payName = '更换签'
} else if (state.dataArray[i].payType === 'CHANGEALL') {
state.dataArray[i].payName = '更换卡签'
} else { } else {
state.dataArray[i].payName = '未知费' state.dataArray[i].payName = '未知费'
} }

+ 1
- 1
subpackage/personal-center/consumption-record.vue Переглянути файл

<view>ETC卡号:{{item.cardId}}<text class="payStatus">{{item.payStatusC}}</text></view> <view>ETC卡号:{{item.cardId}}<text class="payStatus">{{item.payStatusC}}</text></view>
<view>充值金额:¥{{item.rechargeMoney/100}}</view> <view>充值金额:¥{{item.rechargeMoney/100}}</view>
<view>车牌号:{{item.vehiclePlate}}</view> <view>车牌号:{{item.vehiclePlate}}</view>
<view>申请时间:{{item.insertTime}}</view>
<view>创建时间:{{item.insertTime}}</view>
<view>圈存状态:{{item.statusC}}</view> <view>圈存状态:{{item.statusC}}</view>
<!-- 支付成功和未圈存 --> <!-- 支付成功和未圈存 -->
<view class="but-wrap" v-if="item.statusC =='待支付'"> <view class="but-wrap" v-if="item.statusC =='待支付'">

+ 50
- 25
subpackage/personal-center/search/etcFlowingWater.vue Переглянути файл

<u-icon name="calendar" :custom-style="{color:'#999999', size: '28rpx'}"></u-icon> <u-icon name="calendar" :custom-style="{color:'#999999', size: '28rpx'}"></u-icon>
</view> </view>
</view> </view>
<view class="time-btn" @click="search">查询</view>
<view class="time-btn" @click="search(1)">查询</view>
</view> </view>
<view class="total-num" v-if="state.list.length > 0"> <view class="total-num" v-if="state.list.length > 0">
<text>金额合计:{{state.aggregateAmount/100}}</text> <text>金额合计:{{state.aggregateAmount/100}}</text>
<view class="btn-1 btn" v-if="item.status === 3" @click="toEvaluate(item)">去评价</view> <view class="btn-1 btn" v-if="item.status === 3" @click="toEvaluate(item)">去评价</view>
</view> </view>
</view> </view>
<view class="bottom-line" v-if="state.flags">我是有底线的~~~</view>
</view> </view>
<view class="blank" v-else> <view class="blank" v-else>
<view class="text-center">暂无数据</view> <view class="text-center">暂无数据</view>
downloadBills, downloadBills,
} from "@/utils/network/api.js"; } from "@/utils/network/api.js";
import { import {
onLoad
onLoad,
onReachBottom
} from '@dcloudio/uni-app' } from '@dcloudio/uni-app'
import {downloadFileURL} from '@/datas/fileURL.js'
import {
downloadFileURL
} from '@/datas/fileURL.js'
const dataTime = reactive({ const dataTime = reactive({
startDate: "开始时间", startDate: "开始时间",
endDate: "结束时间" endDate: "结束时间"
passTotal: 0, passTotal: 0,
parkTotal: 0, parkTotal: 0,
aggregateAmount: 0, aggregateAmount: 0,
pageSize: 10, //每页数据量
pageNo: 1, // 当前页
flags: false,
}) })
onLoad((option) => { onLoad((option) => {
state.cardId = option.cardId; state.cardId = option.cardId;
}) })


const search = () => {
// 触底加载
onReachBottom(() => {
if (state.list.length < state.pageNo * 10) return state.flags = true
console.log("触底了")
state.pageNo++
search(2)
})
const search = (val) => {
getPpassBillCount() getPpassBillCount()

if (val == 1) {
state.pageNo = 1
}
if (state.pageNo == 1 && state.list.length > 0) {
state.list = []
}
const options = { const options = {
type: 2, type: 2,
data: { data: {
cardId: state.cardId, cardId: state.cardId,
beforeDate: dataTime.startDate, beforeDate: dataTime.startDate,
afterDate: dataTime.endDate, afterDate: dataTime.endDate,
pageNo: state.pageNo,
pageSize: state.pageSize,
}, },
method: "POST", method: "POST",
showLoading: true, showLoading: true,
console.log(res); console.log(res);
let result = stringToJson(res.bizContent) let result = stringToJson(res.bizContent)
console.log(result); console.log(result);
state.list = result.data ?result.data: []
state.list = [...state.list, ...stringToJson(res.bizContent).data]
console.log(result.data); console.log(result.data);


// let orderInfo = JSON.parse(res.bizContent);
}) })


} }
}; };
request(passBillCount, options).then((res) => { request(passBillCount, options).then((res) => {
let result = stringToJson(res.bizContent) let result = stringToJson(res.bizContent)
state.aggregateAmount = result.aggregateAmount ?result.aggregateAmount: 0
state.passTotal = result.passTotal ? result.passTotal: 0
state.parkTotal = result.parkTotal ?result.parkTotal: 0
state.aggregateAmount = result.aggregateAmount ? result.aggregateAmount : 0
state.passTotal = result.passTotal ? result.passTotal : 0
state.parkTotal = result.parkTotal ? result.parkTotal : 0
console.log(result); console.log(result);
}) })
} }
const options = { const options = {
type: 2, type: 2,
data: { data: {
cardId: state.cardId,
cardId: state.cardId,
starDate: dataTime.startDate, starDate: dataTime.startDate,
endDate: dataTime.endDate, endDate: dataTime.endDate,
}, },
}; };
request(downloadBills, options).then((res) => { request(downloadBills, options).then((res) => {
let result = stringToJson(res.bizContent) let result = stringToJson(res.bizContent)
console.log("downloadFileURL",downloadFileURL+result.ossFilePath);
download(downloadFileURL+result.ossFilePath)
console.log("downloadFileURL", downloadFileURL + result.ossFilePath);
download(downloadFileURL + result.ossFilePath)
}) })
} }


align-items: center; align-items: center;
box-sizing: border-box; box-sizing: border-box;
} }
.picker{

.picker {
flex: 1; flex: 1;
} }

.search-time-box { .search-time-box {
flex: 1; flex: 1;
} }
// margin-left: 41rpx; // margin-left: 41rpx;
// } // }
} }
.btn-download{
padding: 0 20rpx;
border: 1px solid #00B38B;
height: 60rpx;
line-height: 60rpx;
border-radius: 30rpx;
font-size: 28rpx;
color: #00B38B;

.btn-download {
padding: 0 20rpx;
border: 1px solid #00B38B;
height: 60rpx;
line-height: 60rpx;
border-radius: 30rpx;
font-size: 28rpx;
color: #00B38B;
} }


.list-wrap { .list-wrap {
color: #999999; color: #999999;
} }
} }

.bottom-line {
text-align: center;
margin: 30rpx 0;
}
</style> </style>

+ 239
- 0
subpackage/personal-center/trapping-and-repairing-account/recharge-pay.vue Переглянути файл

<template>
<view class="content">
<view @click="rechargeAction">
<view style="display: flex;align-items: center;">
<image class="photo" :src="fileURL + 'image/index/goRecharge.png'"></image>去修复
</view>
<image class="photo1" src="../../static/image/icon-back.png" mode="widthFix"></image>
</view>
<view>
<view>选择充值方式:</view>
<view style="width: 67%;display: flex;align-items: center;">
<radio-group @change="radioChange" style="display: flex;align-items: center;">
<label style="align-items: center;margin-right: 40rpx;margin-top: 0;"
class="uni-list-cell uni-list-cell-pd" v-for="(item, index) in state.transWayTypeList"
:key="item.value">
<view>
<radio :value="item.value" :checked="index === state.current" />
</view>
<view>{{item.name}}</view>
</label>
</radio-group>
</view>
</view>
</view>
<view class="tips" v-if="source=='WECHAT'">温馨提示: <text class="red">NFC修复</text>仅支持在<text
class="red">安卓手机</text>进行ETC储值卡充值!</view>
</template>

<script setup lang="ts">
import {
stringToJson
} from "@/utils/network/encryption";
import {
onLoad,
onShow
} from "@dcloudio/uni-app";
import {
request
} from "@/utils/network/request.js";
import {
reactive
} from "vue";
import {
navTo, msg
} from "@/utils/utils";
import {
fileURL
} from "@/datas/fileURL.js";
import { source } from "@/utils/network/difference";
const datas = require("../../../static/etcUtil/datas.js");
const bluetoothUtil = require("../../../static/etcUtil/index.js");
const cmd = require("../../../static/etcUtil/cmdConfig.js");
const tools = require("../../../static/etcUtil/tools.js");
const NFCAPI = require('../../../static/nfc/NFCAPI.js');

const state = reactive({
transWayTypeShow: false,
// #ifdef MP-ALIPAY
transWayTypeList: [{
name: "蓝牙",
value: "blu",
}],
// #endif
// #ifdef MP-WEIXIN
transWayTypeList: [],
// #endif
tableIndex: 0,
transWayName: "蓝牙",
transWay: "blu", //“blu”为蓝牙充值方式、“nfc”为NFC充值方式
cardId: "", //卡号 需要传参
current: 0,
rechargeMoney: "", //圈存金额
orderNum: "",//消费明细 传orderNum说明去支付
payMoney: 0, //0 修复 1支付
});

const selectConfirm = (item : any) => {
state.transWayName = item[0].label
state.transWay = item[0].value
};

onLoad((option) => {
// #ifdef MP-WEIXIN
state.rechargeMoney = option.rechargeMoney
state.orderNum = option.orderNum
state.payMoney = option.payMoney
console.log("参数", option)
uni.getSystemInfo({
success: (res) => {
console.log("res", res['osName'])
// ios
if (res['osName'] == 'ios') {
state.transWayTypeList = [{
name: "蓝牙",
value: "blu",
}]
} else {
// 安卓
state.transWayTypeList = [{
name: "蓝牙",
value: "blu",
}, {
name: "NFC",
value: "nfc",
}]
}
}
});
// #endif
});

function radioChange(evt) {
console.log('输出内容', evt)
state.transWay = evt.detail.value; //“blu”为蓝牙充值方式、“nfc”为NFC充值方式
for (var k = 0; k < state.transWayTypeList.length; k++) {
if (state.transWayTypeList[k]['value'] == evt.detail.value) {
state.transWayName = state.transWayTypeList[k]['name']
return;
}
}
}

/*点击充值按钮*/
const rechargeAction = () => {
if (state.transWay == 'blu') {
uni.redirectTo({
url: `/pages/bluetooth/bluetooth?routeType=9&&rechargeMoney=${state.rechargeMoney}&&orderNum=${state.orderNum}&&payMoney=${state.payMoney}`,
});
} else {
uni.redirectTo({
url: `/pages/nfc/nfc?routeType=9&&rechargeMoney=${state.rechargeMoney}&&orderNum=${state.orderNum}&&payMoney=${state.payMoney}`,
});
}


};
const goRecord = () => {
uni.navigateTo({
url: `/subpackage/personal-center/consumption-record?cardId=${state.cardId}`
})
}
</script>

<style>
.record {
width: 90%;
display: flex;
justify-content: space-between;
margin: 0 auto;
align-items: center;
}

.arrow {
width: 14rpx;
height: 26rpx;
}

.tabs .tab-tit {
font-size: 30rpx;
color: #333;
padding: 45rpx 0 22rpx 30rpx;
}

.tabs .tab {
display: flex;
flex-wrap: wrap;
justify-content: space-evenly;
}

.tabs .tab .item {
width: 210rpx;
height: 100rpx;
background: #f6fff7;
border: 1px solid #dcdde1;
box-sizing: border-box;
line-height: 100rpx;
border-radius: 6rpx;
text-align: center;
margin-bottom: 24rpx;
color: #333333;
font-size: 32rpx;
}

.tabs .tab .item.active {
border: 1px solid #24cc49;
color: #24cc49;
}

.btn-primary {
width: 670rpx;
height: 80rpx;
line-height: 80rpx;
background: linear-gradient(-90deg, #43a1e0 0%, #13e7c1 100%);
border-radius: 40rpx;
font-size: 32rpx;
color: #ffffff;
margin: 200rpx 40rpx 0;
text-align: center;
}

label {
display: flex;
justify-content: space-between;
margin-top: 30rpx;
}

.photo {
width: 40rpx;
height: 40rpx;
margin-right: 40rpx;
}

.photo1 {
width: 40rpx;
transform: rotateY(180deg);
}

.content {
font-size: 32rpx;
}

.content>view {
border-bottom: 1rpx solid #c1c1c1;
display: flex;
padding: 16rpx 20rpx;
align-items: center;
justify-content: space-between;
height: 60rpx;
}

.red {
color: red;
}

.tips {
font-size: 32rpx;
padding: 20rpx;
}
</style>

+ 1037
- 0
subpackage/personal-center/trapping-and-repairing-account/recharge-two.vue
Різницю між файлами не показано, бо вона завелика
Переглянути файл


+ 56
- 0
subpackage/personal-center/trapping-and-repairing-account/result.vue Переглянути файл

<template>
<view class="wrapper">
<image :src="`${$imgUrl}common/reharge-success.png`" class="pic-status" mode="widthFix"></image>
<view class="text-result">修复成功</view>
<view class="sub-text">您办理的账户充值业务已生成订单</view>
<view class="btn btn-primary" @click="view">返回查看</view>
</view>
</template>

<script lang="ts" setup>
const view = () => {
uni.navigateBack({
delta: 3
})
}
</script>

<style>
.wrapper {
display: flex;
flex-direction: column;
justify-content: center;
text-align: center;
}

.text-result {
font-size: 36rpx;
color: #333;
font-weight: 400;
}

.sub-text {
font-size: 26rpx;
font-weight: 400;
color: #999999;
padding-top: 40rpx;
}

.pic-status {
width: 690rpx;
height: 300rpx;
margin: 98rpx 30rpx 25rpx;
}

.btn-primary {
width: 670rpx;
height: 80rpx;
line-height: 80rpx;
background: linear-gradient(-90deg, #43A1E0 0%, #13E7C1 100%);
border-radius: 40rpx;
font-size: 32rpx;
color: #ffffff;
margin: 300rpx 40rpx 0;
text-align: center;
}
</style>

Завантаження…
Відмінити
Зберегти