1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- <template>
- <view>
- <u-navbar
- title="历史欠费"
- title-color="#fff"
- :custom-back="customBack"
- :border-bottom="false"
- back-icon-color="#CCE8FF"
- :background="{background: 'linear-gradient(145deg, #41AFF9 0%, #2D8CFB 100%)' }"></u-navbar>
-
- <u-empty class="u-m-t-50" text="很棒!没有欠费订单!" mode="list" v-if="listEmpty"></u-empty>
- <view class="owelist">
- <view class="owelist-item" v-for="(item,index) in owelist" :key="item.id">
- <view class="item-header u-flex u-row-between">
- <view class="vehicle-no">{{item.vehicleNo}}</view>
- <view class="space-name">{{item.spaceName}}</view>
- </view>
- <view class="road-name u-flex">
- <u-icon name="map-fill" color="#3397FA" size="36"></u-icon>
- {{item.roadName}}
- </view>
- <view class="info-item">进场时间:{{item.inTime}}</view>
- <view class="info-item">出场时间:{{item.outTime}}</view>
- <view class="info-item">停车时长:{{item.duration}}</view>
- <view class="info-item">欠费金额:<span class="amount">{{item.payAmount}}元</span></view>
- </view>
- </view>
- <u-toast ref="uToast" />
- </view>
- </template>
- <script>
- export default{
- data(){
- return{
- orderID:'',
- listEmpty:false,
- owelist:[],
- }
- },
- onLoad(page){
- this.orderID = page.orderID;
- console.log('this.orderID',this.orderID)
- },
- onShow(){
- this.handleEntranceOutDetail();
- },
- methods:{
- customBack(){
- this.$u.route({
- // type:'switchTab',
- url: 'pages/index/index'
- });
- },
- handleEntranceOutDetail(){
- uni.showLoading({});
- this.$u.api.entranceOutDetail({spaceId:this.orderID})
- .then(res=>{
- uni.hideLoading();
- // this.$refs.uToast.show({
- // title: res.msg,
- // type: 'success',
- // });
- this.leaveDetail = res.data;
- this.owelist = res.data.oweList;
- if(this.owelist?.length<=0||!this.owelist){this.listEmpty = true};
-
- console.log('entranceOutDetail',res)
- }).catch(err=>{
- uni.hideLoading();
- this.$refs.uToast.show({
- title: err.msg,
- type: 'error',
- });
- console.log('entranceOutDetail ',err)
- });
-
- },
-
- }
- }
- </script>
- <style lang="scss">
- @import './owelist.scss'
- </style>
|