<template>
|
<view class="main">
|
<view class="main-body">
|
<u-empty mode="data"
|
icon="http://cdn.uviewui.com/uview/empty/data.png"
|
textSize="30"
|
iconSize="1000"
|
v-if="recordList.length == 0"></u-empty>
|
<view class="main-block"
|
v-for="item in recordList"
|
:key="item.id">
|
<view class="coal-name">
|
煤种名称:{{item.coalName}}
|
</view>
|
<view class="code">
|
提煤单编号:{{item.code}}
|
</view>
|
<view class="reservationTime">
|
预约时间:{{item.yuYueTime||''}}
|
</view>
|
<view class="weigh-item">
|
<view class="item">
|
<view class="concrete"
|
style="background: url('https://mx.jzeg.cn:9095/appimg/image/banner/skin.png') no-repeat;background-size: cover;">
|
皮</view>
|
<view class="num">{{ item.skin }}</view>
|
</view>
|
<view class="item">
|
<view class="concrete"
|
style="background: url('https://mx.jzeg.cn:9095/appimg/image/banner/hair.png') no-repeat;background-size: cover;">
|
毛</view>
|
<view class="num">{{ item.hair }}</view>
|
</view>
|
<view class="item">
|
<view class="concrete"
|
style="background: url('https://mx.jzeg.cn:9095/appimg/image/banner/clean.png') no-repeat;background-size: cover;">
|
净</view>
|
<view class="num">{{ item.clean }}</view>
|
</view>
|
</view>
|
<view class="utils-button">
|
<u-button @click="select(item)"
|
type="primary"
|
text="选择"
|
:disabled="item.canClick">
|
</u-button>
|
</view>
|
</view>
|
</view>
|
</view>
|
</template>
|
|
<script>
|
export default {
|
data() {
|
return {
|
recordList: [],
|
deptId: "",
|
filedId: "",
|
canClick: false
|
}
|
},
|
computed: {},
|
onLoad(params) {
|
this.filedId = params.filedId
|
this.deptId = params.deptId
|
},
|
onShow() {
|
this.getTmTaskCoalOrderType()
|
},
|
methods: {
|
getTmTaskCoalOrderType() {
|
uni.showLoading({
|
title: '加载中'
|
})
|
this.$reqGet('getTmTaskCoalOrderType', {
|
deptId: this.deptId,
|
filedId: this.filedId,
|
orderType: '外销'
|
}).then(res => {
|
if (res.data && res.data?.length !== 0) {
|
console.log(res, '外销订单数据');
|
uni.hideLoading()
|
this.recordList = res.data
|
this.recordList = this.recordList.map(v => {
|
let canClick = v.clean !== 0
|
return {
|
...v,
|
canClick
|
}
|
})
|
}
|
})
|
},
|
select(item) {
|
this.$reqPost('updateTmTaskCoalState', { neiGouOrzhuanRuTmId: item.id }, 'params').then(res => {
|
console.log(res);
|
if (res.code == 0) {
|
uni.navigateTo({
|
url: `/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details?orderPlanId=${item.id}&overTmWaixiao=1`
|
})
|
} else {
|
this.$u.toast('出现错误,请稍后重试')
|
}
|
})
|
}
|
}
|
}
|
</script>
|
|
<style lang="scss"
|
scoped>
|
@mixin flex {
|
display: flex;
|
justify-content: center;
|
align-items: center;
|
}
|
|
.main {
|
width: 100%;
|
@include flex;
|
|
.main-body {
|
width: 96%;
|
margin-top: 20rpx;
|
overflow: hidden;
|
@include flex;
|
flex-direction: column;
|
justify-content: space-between;
|
|
.main-block {
|
width: 690rpx;
|
height: 396rpx;
|
margin-top: 10rpx;
|
padding: 15rpx;
|
background: #ffffff;
|
box-shadow: 4rpx 6rpx 51rpx 0rpx rgba(73, 120, 240, 0.11);
|
border-radius: 20rpx;
|
position: relative;
|
font-size: 30rpx;
|
font-weight: 300;
|
color: #303030;
|
overflow: hidden;
|
@include flex;
|
flex-direction: column;
|
justify-content: space-between;
|
align-items: flex-start;
|
|
.code,
|
.coal-name,
|
.reservationTime {
|
color: #7D7D7D;
|
}
|
|
.weigh-item {
|
width: 100%;
|
height: vww(36);
|
@include flex;
|
justify-content: space-around;
|
|
.item {
|
min-width: vww(50);
|
height: vww(45);
|
font-size: 21rpx;
|
font-weight: 400;
|
color: #ffffff;
|
text-align: center;
|
line-height: vww(30);
|
@include flex;
|
|
.concrete {
|
width: vww(36);
|
height: vww(36);
|
}
|
|
.num {
|
font-size: 40rpx;
|
font-weight: 300;
|
color: #303030;
|
}
|
}
|
}
|
|
.utils-button {
|
width: 100%;
|
@include flex;
|
justify-content: flex-end;
|
|
/deep/.u-button {
|
width: 208rpx;
|
height: 60rpx;
|
font-size: 28rpx;
|
letter-spacing: 4rpx;
|
font-weight: 300;
|
background-color: #497BFB;
|
color: #ffffff;
|
box-shadow: 2rpx 3rpx 13rpx 0rpx rgba(43, 98, 239, 0.5), 0rpx 0rpx 9rpx 0rpx rgba(247, 250, 253, 0.29);
|
border-radius: 37rpx 37rpx 37rpx 37rpx;
|
margin: 0;
|
margin-right: 38rpx;
|
}
|
}
|
}
|
}
|
}
|
</style>
|