tianyi 3 weeks ago
parent
commit
ead418f3a7
  1. 7
      App.vue

7
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;

Loading…
Cancel
Save