123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186 |
- <template>
- <view class="cleared-container">
- <scroll-view class="scroll-con" scroll-y :scroll-top="scrollTop" @scrolltolower="onreachBottom">
-
- <view class="cell-item-con">
- <view class="cell-item" v-for="(item, index) in listdata" :key="index">
- <view class="cell-item-c">
- <view class="cell-item-date">{{item.createDate}}</view>
- <view class="cell-item-orderNum">
- {{item.createDate}}
- <u-icon name="arrow-right" :size="28" color="#999"></u-icon>
- </view>
- </view>
- <u-grid :col="3" :hover-class="none">
- <u-grid-item>
- <view class="cell-item-main">
- <text class="cell-item-number blue">26</text>
- <text class="cell-item-unit">个</text>
- </view>
- <view class="cell-item-exp">清运网点数</view>
- </u-grid-item>
- <u-grid-item>
- <view class="cell-item-main">
- <text class="cell-item-number green">26</text>
- <text class="cell-item-unit">个</text>
- </view>
- <view class="cell-item-exp">清运箱体数</view>
- </u-grid-item>
- <u-grid-item>
- <view class="cell-item-main">
- <text class="cell-item-number red">26</text>
- <text class="cell-item-unit">kg</text>
- </view>
- <view class="cell-item-exp">清运总重量</view>
- </u-grid-item>
- </u-grid>
- </view>
- </view>
- <u-empty class="nodata" :text="noDataText" v-if="listdata.length==0 && status!='loading'" mode="list"></u-empty>
- <view class="loadmore">
- <u-loadmore v-if="total>pageSize || status=='loading'" :status="status" />
- </view>
- </scroll-view>
- </view>
- </template>
- <script>
-
- export default {
- data() {
- return {
- listdata: [],
- pageNo: 1,
- pageSize: 10,
- total: 0,
- noDataText: '暂无数据',
- status: 'loadmore',
- customBtnStyle: {
- borderColor: '#ed1c24',
- backgroundColor: '#ed1c24',
- color: '#fff'
- },
- scrollTop: 0,
- }
- },
- onLoad() {
- this.refresh({})
- },
- methods:{
-
- refresh(){
- this.listdata = []
- this.total = 0
- this.searchHandle(1)
- },
-
- revokeFun(row){
- const _this = this
- uni.showModal({
- title: '提示',
- content: '撤销单据后乐豆将全部退回给原支付账号,确认撤销吗?',
- success(res) {
- if (res.confirm) {
-
-
-
-
-
-
- }
- }
- })
- },
-
- searchHandle (pageNo) {
-
- pageNo ? this.pageNo = pageNo : null
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- },
-
- onreachBottom() {
- if(this.listdata.length < this.total){
- this.pageNo += 1
- this.searchHandle()
- }else{
- uni.showToast({ title: '已经到底了', icon: 'none' })
- this.status = "nomore"
- }
- }
- }
- }
- </script>
- <style lang="scss">
- page{
- height: 100%;
- }
- .cleared-container {
- width: 100%;
- height: 100%;
- display: flex;
- flex-direction: column;
- // 列表
- .scroll-con{
- flex: 1;
- overflow: auto;
- }
- // 列表样式
- .cell-item-con{
- .cell-item{
- margin: $uni-spacing-col-base $uni-spacing-row-base;
- background-color: #fff;
- border-radius: $uni-border-radius-base;
- color: $uni-text-color;
- font-size: $uni-font-size-base;
- box-shadow: 3rpx 3rpx 5rpx #eee;
- .cell-item-c{
- display: flex;
- justify-content: space-between;
- padding: $uni-spacing-col-base $uni-spacing-row-base;
- .cell-item-date{
- color: $uni-text-color-grey;
- }
- }
- .cell-item-main{
- display: inline-block;
- margin-bottom: 10rpx;
- .cell-item-number{
- margin-right: 5rpx;
- }
- .cell-item-unit{
- font-size: 26rpx;
- }
- .blue {
- color: #1890FF;
- }
- .green {
- color: #16b50e;
- }
- .red {
- color: red;
- }
- }
- }
- }
- }
- </style>
|