diff --git a/App.vue b/App.vue index 8e3bc3e..139b238 100644 --- a/App.vue +++ b/App.vue @@ -143,6 +143,7 @@ } //用户收到了通知消息 + console.log('通知的消息1',result) if (result.notificationEventType == 'notificationArrived') { if (result.content.includes('订单出餐已超时')) { this.onPlayAudio(2) @@ -161,6 +162,8 @@ this.onPlayAudio(6) } else if (result.content.includes('您有一笔订单用户申请售后,请尽快处理')) { this.onPlayAudio(8) + } else if (result.content.includes('您有一笔预约订单可以出餐啦')) { + this.onPlayAudio(9) } // 将消息数据推入打印队列 this.globalData.printData.push(JSON.parse(result.android.inAppExtras)) @@ -315,9 +318,11 @@ audio.src = 'https://jewel-shop.oss-cn-beijing.aliyuncs.com/2fe04974ece245a79cd078dc7def773d.mp3'; } else if (type == 8) { //申请售后 audio.src = 'https://jewel-shop.oss-cn-beijing.aliyuncs.com/1f3bfb020a9c4eb9af7c11e850538f56.mp3'; + } else if (type == 9) { //预约订单可以出餐 + audio.src = 'https://jewel-shop.oss-cn-beijing.aliyuncs.com/1b6b61995c214e0799feaa4f7d4fe0fa.mp3'; } // #endif - + audio.play(); audio.onEnded(function(res) { audio = null;