From 7b02977dc17d1290f50016085452906a7119a64e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?TOP=E7=B3=AF=E7=B1=B3?= <1130395124@qq.com> Date: Sat, 25 Feb 2023 18:54:51 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9EserviceActions=E6=96=B9?= =?UTF-8?q?=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/core/utils.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/core/utils.js b/src/core/utils.js index 389925e..b7dba6f 100644 --- a/src/core/utils.js +++ b/src/core/utils.js @@ -168,6 +168,18 @@ function toast(title, options) { }); } +function serviceActions() { + uni.showActionSheet({ + itemList: ['电话客服', '微信客服', '微信客服二'], + success(res) { + console.log('选中了第' + (res.tapIndex + 1) + '个按钮'); + }, + fail(res) { + console.log(res.errMsg); + } + }); +} + export default { time, datetime, @@ -180,4 +192,5 @@ export default { rpx2px, toPage, toast, + serviceActions, }