You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
244 lines
5.3 KiB
Vue
244 lines
5.3 KiB
Vue
<template>
|
|
<view class="container">
|
|
<view class="tui-searchbox">
|
|
<view class="tui-search-input">
|
|
<icon type="search" :size='20' color='#333'></icon>
|
|
<input confirm-type="search" placeholder="请输入箱号" :focus="true" auto-focus
|
|
placeholder-class="tui-input-plholder" class="tui-input" v-model.trim="postData.CNTRNO"
|
|
@confirm="getInfo" />
|
|
<icon type="clear" :size='20' color='#bcbcbc' @tap="cleanCNTRNO" v-show="postData.CNTRNO"></icon>
|
|
</view>
|
|
<view class="tui-search-input">
|
|
<icon type="search" :size='20' color='#333'></icon>
|
|
<input confirm-type="search" placeholder="请输入班列号" :focus="true" auto-focus
|
|
placeholder-class="tui-input-plholder" class="tui-input" v-model.trim="postData.TRAINNUM"
|
|
@confirm="getInfo" />
|
|
<icon type="clear" :size='20' color='#bcbcbc' @tap="cleanTRAINNUM" v-show="postData.TRAINNUM"></icon>
|
|
</view>
|
|
</view>
|
|
<view class="tag-view" v-if="info" v-for="(item,index) in info" :key="index" style="margin-left: 20rpx;">
|
|
<uni-badge class="uni-badge-left-margin" :text="item.count" absolute="rightTop" size="small">
|
|
<uni-tag :inverted="true" :text="item.train" type="primary"></uni-tag>
|
|
</uni-badge>
|
|
</view>
|
|
<uni-card v-if="list" v-for="(item,index) in list" :title="item.worktype" :key="index">
|
|
<view class="example">
|
|
<uni-forms ref="form" :modelValue="item" label-position="left">
|
|
<uni-forms-item label="预计日期" name="plandate">
|
|
<uni-easyinput type="text" :disabled="true" v-model="item.plandate" />
|
|
</uni-forms-item>
|
|
<uni-forms-item label="箱号" name="cntrno">
|
|
<uni-easyinput type="text" :disabled="true" v-model="item.cntrno" />
|
|
</uni-forms-item>
|
|
<uni-forms-item label="班列号" name="trainnum">
|
|
<uni-easyinput type="text" :disabled="true" v-model="item.trainnum" />
|
|
</uni-forms-item>
|
|
<uni-forms-item label="状态" name="workstatus">
|
|
<uni-easyinput type="text" :disabled="true" v-model="item.workstatus" />
|
|
</uni-forms-item>
|
|
</uni-forms>
|
|
<button @click="skip(item.gid)">核对</button>
|
|
</view>
|
|
</uni-card>
|
|
</view>
|
|
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
data() {
|
|
return {
|
|
info: [],
|
|
loadData: [],
|
|
pageIndex: 1,
|
|
loadding: false,
|
|
pullUpOn: true,
|
|
isShow: false,
|
|
postData: {
|
|
CNTRNO: "",
|
|
TRAINNUM: "",
|
|
},
|
|
skipData: {
|
|
WMSPLANID: "",
|
|
},
|
|
key: "",
|
|
list: '',
|
|
type:''
|
|
}
|
|
},
|
|
onShow() {
|
|
this.list = ''
|
|
this.skipData.type = ''
|
|
this.postData.CNTRNO = ''
|
|
this.postData.TRAINNUM = ''
|
|
this.getInfo()
|
|
},
|
|
methods: {
|
|
back: function() {
|
|
uni.navigateBack();
|
|
},
|
|
cleanCNTRNO: function() {
|
|
this.postData.CNTRNO = ''
|
|
},
|
|
cleanTRAINNUM: function() {
|
|
this.postData.TRAINNUM = ''
|
|
},
|
|
getInfo: function() {
|
|
uni.showLoading()
|
|
console.log(this.postData)
|
|
this.tui.request("/App/GetTrainWorkList", "POST", this.postData, false, false, false)
|
|
.then((
|
|
res) => {
|
|
console.log(res)
|
|
if (res.succeeded) {
|
|
this.list = res.data[0]
|
|
this.info = res.data[1]
|
|
uni.hideLoading()
|
|
} else {
|
|
this.tui.toast(res.message, 2000, 'none')
|
|
}
|
|
}).catch((err) => {
|
|
console.log(err)
|
|
this.tui.toast('异常:' + err, 2000, 'none')
|
|
uni.hideLoading()
|
|
})
|
|
},
|
|
skip: function(id) {
|
|
uni.setStorageSync("trainWorkId", id)
|
|
uni.navigateTo({
|
|
url: '../train-check/train-check'
|
|
})
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style>
|
|
.example {
|
|
padding: 15px;
|
|
background-color: #fff;
|
|
}
|
|
|
|
.button-group {
|
|
margin-top: 15px;
|
|
display: flex;
|
|
justify-content: space-around;
|
|
}
|
|
|
|
.form-item {
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.button {
|
|
display: flex;
|
|
align-items: center;
|
|
height: 35px;
|
|
margin-left: 10px;
|
|
}
|
|
|
|
/* @import '../../static/style/thorui.css'; */
|
|
.tui-msg-box {
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.tui-msg-pic {
|
|
width: 100rpx;
|
|
height: 100rpx;
|
|
border-radius: 50%;
|
|
display: block;
|
|
margin-right: 24rpx;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.tui-msg-item {
|
|
max-width: 500rpx;
|
|
/* min-height: 100rpx; */
|
|
overflow: hidden;
|
|
display: flex;
|
|
flex-direction: column;
|
|
justify-content: space-between;
|
|
}
|
|
|
|
.tui-msg-name {
|
|
overflow: hidden;
|
|
white-space: nowrap;
|
|
text-overflow: ellipsis;
|
|
font-size: 45rpx;
|
|
line-height: 2;
|
|
justify-content: space-between;
|
|
color: #262b3a;
|
|
}
|
|
|
|
.tui-item-box {
|
|
width: 100%;
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.tui-list-cell_name {
|
|
padding-left: 20rpx;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
.tui-ml-auto {
|
|
margin-left: auto;
|
|
}
|
|
|
|
.tui-right {
|
|
margin-left: auto;
|
|
margin-right: 34rpx;
|
|
font-size: 26rpx;
|
|
color: #999;
|
|
}
|
|
|
|
.tui-logo {
|
|
height: 52rpx;
|
|
width: 52rpx;
|
|
flex-shrink: 0;
|
|
}
|
|
</style>
|
|
<style lang='scss'>
|
|
.tui-searchbox {
|
|
padding: 30rpx 0;
|
|
box-sizing: border-box;
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.tui-search-input {
|
|
width: 100%;
|
|
height: 66rpx;
|
|
border-radius: 35rpx;
|
|
padding: 0 30rpx;
|
|
box-sizing: border-box;
|
|
background: #f2f2f2;
|
|
display: flex;
|
|
align-items: center;
|
|
flex-wrap: nowrap;
|
|
}
|
|
|
|
.tui-input {
|
|
flex: 1;
|
|
color: #333;
|
|
padding: 0 16rpx;
|
|
font-size: 28rpx;
|
|
}
|
|
|
|
.tui-input-plholder {
|
|
font-size: 28rpx;
|
|
color: #b2b2b2;
|
|
}
|
|
|
|
.fr-btn {
|
|
float: right;
|
|
height: 60upx;
|
|
font-size: 28upx;
|
|
line-height: 60upx;
|
|
margin: 14upx 0;
|
|
}
|
|
</style>
|