105 lines
2.1 KiB
Vue
105 lines
2.1 KiB
Vue
<template>
|
|
<view class="shet-cont">
|
|
<view class="jsfm-item" style="margin-top: 0;">
|
|
<u-row justify="between">
|
|
<text class="font-28 font-weight">总件数</text>
|
|
<view>
|
|
<u-number-box v-model="modelInfo.parcelQty" :min="1" :max="100000" buttonSize="50" inputWidth="100" iconStyle="font-size: 18rpx;"></u-number-box>
|
|
</view>
|
|
</u-row>
|
|
</view>
|
|
<view class="jsfm-item">
|
|
<u-row justify="between">
|
|
<text class="font-28 font-weight">实际重量</text>
|
|
<view>
|
|
<tpx-input v-model:value="modelInfo.billWeight" placeholder="" inputAlign="right" suffix="kg" _digit="4"></tpx-input>
|
|
</view>
|
|
</u-row>
|
|
</view>
|
|
|
|
<view class="jsfm-item">
|
|
<u-row justify="between" align="top">
|
|
<text class="font-28 pt-20 font-weight">总体积</text>
|
|
<view v-if="totalVolume || true">
|
|
<tpx-input v-model:value="modelInfo.totalVolume" placeholder="" inputAlign="right" suffix="m³" _digit="4"></tpx-input>
|
|
</view>
|
|
</u-row>
|
|
</view>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
import * as apiService from "@/common/api"
|
|
export default {
|
|
computed: {
|
|
modelInfo: {
|
|
get(){
|
|
return this.value
|
|
}
|
|
},
|
|
totalVolume() {
|
|
let totalVolume = this.modelInfo.totalVolume
|
|
|
|
|
|
return totalVolume
|
|
},
|
|
isCargoListOnchange() {
|
|
return this.modelInfo.cargoList
|
|
}
|
|
},
|
|
watch: {
|
|
isCargoListOnchange: {
|
|
handler(newVal){
|
|
console.log("===bpe-goodsize-tmp isCargoListOnchange===")
|
|
this.handleCargoChange(newVal)
|
|
},
|
|
deep: true,
|
|
}
|
|
},
|
|
props: {
|
|
value: {
|
|
default () {
|
|
return { }
|
|
}
|
|
}
|
|
},
|
|
data() {
|
|
return {
|
|
}
|
|
},
|
|
created() {
|
|
},
|
|
onHide() {
|
|
|
|
},
|
|
unmounted() {
|
|
|
|
},
|
|
|
|
methods: {
|
|
handleCargoChange(list){
|
|
let parcelQty = 0, totalVolume = 0
|
|
list.map(t=> {
|
|
totalVolume += (+t.volume) || 0
|
|
})
|
|
this.modelInfo.totalVolume = totalVolume.toFixed(4)
|
|
},
|
|
async calceOther() {
|
|
|
|
},
|
|
async validData() {
|
|
await this.calceOther()
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped lang="scss">
|
|
.shet-cont{
|
|
padding: 0;
|
|
}
|
|
.jsfm-item{
|
|
margin-top: 30rpx;
|
|
}
|
|
|
|
</style> |