This commit is contained in:
2022-11-11 19:10:17 +08:00
21 changed files with 333 additions and 228 deletions

View File

@@ -114,14 +114,14 @@
}
try {
let res = await emptyConfirm(this.pkObj, this.qty, this.val1, '2')
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled = false
this.pkId = ''
this.pkObj = {}
this._queryMaterialInfo()
uni.showToast({
title: res.message,
icon: 'none'
})
} catch (e) {
this.disabled = false
}

View File

@@ -114,14 +114,14 @@
}
try {
let res = await emptyConfirm(this.pkObj, this.qty, this.val1, '1')
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled = false
this.pkId = ''
this.pkObj = {}
this._queryMaterialInfo()
uni.showToast({
title: res.message,
icon: 'none'
})
} catch (e) {
this.disabled = false
}

View File

@@ -112,14 +112,14 @@
}
try {
let res = await needEmptyAxis(this.pkObj)
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled1 = false
this.pkId = ''
this.pkObj = {}
this._queryRawFoilList()
uni.showToast({
title: res.message,
icon: 'none'
})
} catch (e) {
this.disabled1 = false
}
@@ -132,14 +132,14 @@
}
try {
let res = await confirmBlanking(this.pkObj)
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled2 = false
this.pkId = ''
this.pkObj = {}
this._queryRawFoilList()
uni.showToast({
title: res.message,
icon: 'none'
})
} catch (e) {
this.disabled2 = false
}

View File

@@ -156,14 +156,13 @@
}
try {
let res = await casingConfirm(this.checkArr, this.val2)
this.disabled = false
this.checkArr = []
this._queryMaterialInfo()
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled = false
this.checkArr = []
this._queryMaterialInfo()
} catch (e) {
this.disabled = false
}

View File

@@ -86,7 +86,7 @@
</view>
</view>
<view class="submit-bar">
<button class="submit-button" :class="{'btn-disabled': !checkArr.length || checkArr.length > 1}" :disabled="disabled1" @tap="_needVehicle">呼叫载具</button>
<button class="submit-button" :class="{'btn-disabled': checkArr.length === 0 || checkArr.length > 1}" :disabled="disabled1" @tap="_needVehicle">呼叫载具</button>
<button class="submit-button" :class="{'btn-disabled': !val1 || !val2}" :disabled="disabled4" @tap="_shippingCheck">配送校验</button>
<button class="submit-button" :class="{'btn-disabled': !checkArr.length}" :disabled="disabled2" @tap="_shippingConfirm">配送确认</button>
<button class="submit-button" :class="{'btn-disabled': !val3}" :disabled="disabled3" @tap="_returnVehicle">载具送回</button>
@@ -108,6 +108,7 @@
return {
val1: '',
val2: '',
val3: '',
options: [],
index: '',
qty: '',
@@ -151,19 +152,19 @@
/** 呼叫载具 */
async _needVehicle () {
this.disabled1 = true
if (!this.checkArr.length || this.checkArr.length > 1) {
if (this.checkArr.length === 0 || this.checkArr.length > 1) {
this.disabled1 = false
return
}
try {
let res = await needVehicle(this.checkArr[0])
this.disabled1 = false
this.checkArr = []
this._queryMaterialInfo()
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled1 = false
this.checkArr = []
this._queryMaterialInfo()
} catch (e) {
this.disabled1 = false
}
@@ -177,13 +178,13 @@
}
try {
let res = await shippingConfirm(this.checkArr, this.val3)
this.disabled2 = false
this.checkArr = []
this._queryMaterialInfo()
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled2 = false
this.checkArr = []
this._queryMaterialInfo()
} catch (e) {
this.disabled2 = false
}

View File

@@ -138,14 +138,14 @@
}
try {
let res = await inConfirm(this.index1, this.pkObj)
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled = false
this.pkId = ''
this.pkObj = {}
this._queryMaterialInfo()
uni.showToast({
title: res.message,
icon: 'none'
})
} catch (e) {
this.disabled = false
}

View File

@@ -200,14 +200,14 @@
}
try {
let res = await outConfirm(this.index1, this.checkArr, this.isV)
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled1 = false
this.checkArr = []
this.isV = '0'
this._queryMaterialInfo()
uni.showToast({
title: res.message,
icon: 'none'
})
} catch (e) {
this.disabled1 = false
}
@@ -245,14 +245,14 @@
}
try {
let res = await conveyConfirm(this.index4)
uni.showToast({
title: res.message,
icon: 'none'
})
this.disabled2 = false
this.index3 = ''
this.index4 = ''
this.active = false
uni.showToast({
title: res.message,
icon: 'none'
})
} catch (e) {
this.disabled2 = false
this.index3 = ''