称重校验
This commit is contained in:
@@ -67,9 +67,10 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row submitbar">
|
||||
<button class="zd-col-15 btn-submit btn-success" :class="{'btn-info': !val1 || dataList.length === 0 || (isV === '1' && index1 === '')}" :disabled="disabled" @tap="_stConfirm">入库确认</button>
|
||||
<button class="zd-col-8 btn-submit btn-success" :class="{'btn-info': !val1 || !val2}" :disabled="disabled1" @tap="_stWeighCheck">称重校验</button>
|
||||
<button class="zd-col-8 btn-submit btn-success" :class="{'btn-info': !val1 || dataList.length === 0 || (isV === '1' && index1 === '')}" :disabled="disabled" @tap="_stConfirm">入库确认</button>
|
||||
<!-- <button class="submit-button" :class="{'btn-disabled': dataList.length === 0}" :disabled="disabled1" @tap="_stPrint">补码</button> -->
|
||||
<button class="zd-col-6 btn-submit btn-success letter-30" @tap="_boxQuery(val1)">查询</button>
|
||||
<button class="zd-col-5 btn-submit btn-success letter-30" @tap="_boxQuery(val1)">查询</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -79,7 +80,7 @@
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
import SearchBoxMx from '@/components/SearchBoxMx.vue'
|
||||
import permision from "@/utils/permission.js"
|
||||
import {boxQuery, stConfirm, stPrint, getStorSect} from '@/utils/getData2.js'
|
||||
import {boxQuery, stConfirm, stPrint, getStorSect, stWeighCheck} from '@/utils/getData2.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
@@ -171,6 +172,24 @@
|
||||
},
|
||||
handleChange (e) {
|
||||
this._boxQuery(this.val1)
|
||||
},
|
||||
// 称重校验
|
||||
async _stWeighCheck () {
|
||||
this.disabled1 = true
|
||||
if (!this.val1 || !this.val2) {
|
||||
this.disabled1 = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await stWeighCheck(this.val1, this.val2)
|
||||
this.disabled1 = false
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
icon: 'none'
|
||||
})
|
||||
} catch (e) {
|
||||
this.disabled1 = false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user