You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
yanzong_qianduan/pages/news3/setOutRecords.vue

377 lines
7.0 KiB

10 months ago
<template>
10 months ago
<view class="updatePrice" style="padding-bottom: 120rpx;">
10 months ago
<view class="head-info">
<!-- 搜索 -->
<view class="searchContent">
10 months ago
<u-input v-model="searchText" style="width:400upx" confirm-type="search" @confirm="getOrderList(1)"
9 months ago
placeholder="收件人名字/订单号/发货公司" />
10 months ago
<u-icon name="search" class="search" @click="getOrderList(1)"></u-icon>
</view>
10 months ago
</view>
10 months ago
<view class="bg">
<image :src="$picUrl+'/static/news3/bg.png'" mode="widthFix"></image>
<view class="text">
只属于非商城订单
</view>
10 months ago
</view>
<view style="padding-bottom: 120upx;" v-if="goodsList.length>0">
10 months ago
<view class="dispatchContent" v-for="(item, index) in goodsList" :key="index">
<view class="orderNum">
订单号{{item.express_no}}
</view>
<view class="dispatchItem" v-for="(item1, index) in item.goods">
<image :src="item1.image" mode="aspectFill"></image>
<view class="right">
<view class="title">
{{item1.name}}
10 months ago
</view>
10 months ago
<view style="display: flex;align-items: center;justify-content: space-between;">
<view class="num">
x{{item1.num}}
</view>
<view class="price">
<text style="font-size: 26upx;">¥</text>
<text>{{item1.price}}</text>
</view>
10 months ago
</view>
10 months ago
</view>
10 months ago
</view>
10 months ago
<view class="totalNum">
<text>共计:</text>
<text style="color: #F21A1C;">¥{{item.total_price}}</text>
10 months ago
</view>
<view class="footerBtn">
<view class="wuliuBtn" @click="onCondiments(item)">
调货记录
</view>
10 months ago
</view>
10 months ago
</view>
</view>
9 months ago
<view v-else style="margin-top: 250rpx;">
<u-empty text="暂无发货记录~" mode="list"></u-empty>
</view>
<view class="goods-fd">
<view class="btn" @click="manualEntry">手动录入</view>
10 months ago
</view>
10 months ago
</view>
10 months ago
</template>
<script>
10 months ago
import * as newFunApi from '@/api/newFun'
export default {
data() {
return {
searchText: '',
goodsList: [],
total: 1,
pageNum: 1,
}
},
onLoad(o) {
this.getOrderList(1)
10 months ago
uni.$on('refreshData', () => {
// 调用列表接口
this.getOrderList(1)
})
},
//页面卸载
onUnload() {
//关闭监听选择收货地址事件
uni.$off('refreshData')
10 months ago
},
10 months ago
onShow() {},
10 months ago
onPullDownRefresh() {
this.pageNum = 1;
this.goodsList = [];
setTimeout(() => {
uni.stopPullDownRefresh();
}, 1000)
},
onReachBottom() {
if (this.goodsList.length <= this.total) {
this.pageNum++;
}
},
methods: {
// 手动录入
manualEntry() {
uni.navigateTo({
url: "/pages/news3/ManualEntry"
})
},
// 调货记录
10 months ago
onCondiments(e) {
10 months ago
uni.navigateTo({
10 months ago
url: "/pages/news3/seasoningCondimentsRecord?item=" + JSON.stringify(e)
10 months ago
})
},
/**
* 获取商品列表
*/
async getOrderList(type) {
uni.showLoading({
title: "加载中"
})
if (type == 1) {
this.pageNum = 1;
this.goodsList = []
}
let {
status,
message,
data
} = await newFunApi.deliveryList({
page: this.pageNum,
10 months ago
search: this.searchText
10 months ago
});
if (status == 200) {
10 months ago
this.goodsList = this.goodsList.concat(data.data)
this.total = data.total
console.log(this.goodsList)
10 months ago
}
},
onClassify(index) {
this.pageNum = 1;
this.goodsList = []
this.getOrderList();
},
10 months ago
}
10 months ago
};
10 months ago
</script>
<style lang="scss" scoped>
10 months ago
page {
min-height: 100%;
background-color: #F7F8FA;
padding: 0 20upx;
}
.head-info {
margin: 22upx 20upx;
.searchContent {
display: flex;
align-items: center;
justify-content: space-between;
position: relative;
10 months ago
background-color: #fff;
border-radius: 60upx;
width: 680upx;
margin-left: 15upx;
10 months ago
::v-deep .u-input {
background: #FFFFFF;
border-radius: 30px 30px 30px 30px;
opacity: 1;
padding-left: 90upx !important;
}
.search {
position: absolute;
top: 20upx;
left: 26upx;
z-index: 9;
}
}
}
.bg {
10 months ago
position: relative;
10 months ago
width: 100%;
display: flex;
align-items: center;
justify-content: center;
10 months ago
image {
10 months ago
10 months ago
height: auto;
10 months ago
width: 690upx;
10 months ago
}
10 months ago
.text {
height: 100%;
width: 100%;
display: flex;
align-items: center;
justify-content: center;
font-size: 42upx;
font-family: YouSheBiaoTiHei, YouSheBiaoTiHei;
font-weight: 400;
color: #FFFFFF;
10 months ago
position: absolute;
10 months ago
left: 0;
top: 0;
10 months ago
}
}
10 months ago
.orderNum {
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
10 months ago
font-weight: 400;
10 months ago
color: #707070;
10 months ago
margin: 16upx 0;
10 months ago
10 months ago
}
10 months ago
.dispatchContent {
10 months ago
padding: 20upx 40upx;
10 months ago
background: #FFF;
border-radius: 6px;
10 months ago
margin: 20upx 14upx;
10 months ago
}
10 months ago
.dispatchItem {
10 months ago
display: flex;
10 months ago
align-items: center;
10 months ago
margin-bottom: 18upx;
10 months ago
image {
10 months ago
width: 158upx;
height: 170upx;
10 months ago
}
10 months ago
.right {
flex: 1;
margin-left: 40upx;
position: relative;
display: flex;
flex-direction: column;
justify-content: space-around;
.title {
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #000000;
10 months ago
margin-bottom: 18upx;
10 months ago
}
.subTitle {
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #7C7C7C;
margin: 14upx 0;
}
.num {
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #1E1E1E;
}
.price {
display: flex;
align-items: center;
justify-content: flex-end;
font-size: 32upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #FF584D;
10 months ago
}
10 months ago
}
10 months ago
}
.totalNum {
text-align: right;
10 months ago
margin-top: 26upx;
10 months ago
text:first-child {
font-size: 32upx;
10 months ago
font-family: PingFang SC, PingFang SC;
font-weight: 700;
color: #3B3B3B;
10 months ago
}
10 months ago
text:nth-child(2) {
10 months ago
font-size: 32upx;
font-family: PingFang SC, PingFang SC;
font-weight: 700;
10 months ago
color: #3B3B3B;
margin: 0 10upx;
}
text:nth-child(3) {
font-size: 32upx;
font-family: PingFang SC, PingFang SC;
font-weight: 600;
10 months ago
color: #F21A1C;
10 months ago
10 months ago
}
}
10 months ago
.footerBtn {
10 months ago
padding: 20upx 0 15upx 30upx;
10 months ago
display: flex;
align-items: center;
border-top: 1px solid #F0F0F0;
justify-content: flex-end;
margin-top: 30upx;
10 months ago
}
10 months ago
.wuliuBtn {
// padding:8upx 46upx;
text-align: center;
10 months ago
height: 66upx;
10 months ago
line-height: 66upx;
border: 1px solid #F63116;
font-size: 28upx;
10 months ago
font-family: PingFang SC, PingFang SC;
font-weight: 500;
10 months ago
color: #F83F11;
border-radius: 20px;
10 months ago
width: 180upx;
10 months ago
}
10 months ago
.goods-fd {
width: 100%;
10 months ago
position: fixed;
left: 0;
bottom: 0;
padding: 0.9375rem;
z-index: 99;
background-color: #fafafa;
box-sizing: border-box;
.btn {
width: 630rpx;
line-height: 88rpx;
background: #F34A40;
border-radius: 88rpx;
text-align: center;
font-size: 28rpx;
font-weight: 500;
color: #FFFFFF;
margin: auto;
}
10 months ago
}
.empty {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
width: 100%;
image {
width: 114rpx;
height: auto;
margin-top: 200rpx;
}
}
10 months ago
</style>