From bfcbe077d01854ae613dd35b4761a0f02d8c9b60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E6=AD=A3=E6=98=93?= Date: Fri, 17 May 2024 11:36:52 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=98=B2=E6=8A=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../MaterialWarehousing.vue | 39 ++++++++++--------- 1 file changed, 21 insertions(+), 18 deletions(-) diff --git a/pages/materialManagement/MaterialWarehousing/MaterialWarehousing.vue b/pages/materialManagement/MaterialWarehousing/MaterialWarehousing.vue index 5a3900f..5da110a 100644 --- a/pages/materialManagement/MaterialWarehousing/MaterialWarehousing.vue +++ b/pages/materialManagement/MaterialWarehousing/MaterialWarehousing.vue @@ -76,7 +76,7 @@ export default { }); }, start_agv() { - debounce(() => { + uni.$u.throttle(()=>{ if (this.start_point == '' || this.end_point == '') { this.$refs.uToast.show({ type: 'error', @@ -106,28 +106,31 @@ export default { } } }); - }, 5000); + }, 5000) }, stop_agv() { - if (this.reqCode == '') { - this.$refs.uToast.show({ - type: 'error', - message: '无任务编号' - }); - return; - } - const query = { - reqCode: this.reqCode - }; - - emergency_stop_agv(query).then((res) => { - if (res.code == 200) { + uni.$u.throttle(()=>{ + if (this.reqCode == '') { this.$refs.uToast.show({ - type: 'success', - message: '成功取消' + res.data + type: 'error', + message: '无任务编号' }); + return; } - }); + const query = { + reqCode: this.reqCode + }; + + emergency_stop_agv(query).then((res) => { + if (res.code == 200) { + this.$refs.uToast.show({ + type: 'success', + message: '成功取消' + res.data + }); + } + }); + },5000) + } } };