5.31宁夏问题修改

This commit is contained in:
FrancisHu 2024-05-31 18:58:56 +08:00
parent c6498429c2
commit 9238036a4e
1 changed files with 5 additions and 4 deletions

View File

@ -18,7 +18,7 @@
:clear="false"
></uni-data-select>
</view>
<h5 class="tit">当前型号剩余库存{{ leftNum }}</h5>
<h5 class="tit">当前规格剩余库存{{ leftNum }}</h5>
<h5 class="tit">预约数量</h5>
<view class="select-num">
<uni-number-box v-model="deviceNum" @change="numChange" :min="1"/>
@ -96,15 +96,16 @@ import { basePath } from '../../public';
title: '请选择规格!'
})
} else {
console.log(this.typeId, this.deviceNum, this.companyId, this.leftNum);
console.log(this.typeId, this.deviceNum, this.companyId, this.leftNum, uni.getStorageSync('userInfo').userid);
//
if (this.deviceNum > this.leftNum) {
uni.showToast({
icon: 'none',
title: '当前领料数量大于库存数量!'
icon: 'none',
title: '领料数量大于该规格库存数量!'
})
} else {
that.$api.fetchMaterial.addItemToCart({
userId: uni.getStorageSync('userInfo').userid,
typeId: this.typeId,
bookNum: this.deviceNum,
companyId: this.companyId