|
@@ -15,10 +15,14 @@ import store from "@/store/index.js";
|
|
|
//#endif
|
|
|
class SocketEvent {
|
|
|
app = null;
|
|
|
+ // #ifdef APP-PLUS-NVUE
|
|
|
allApp = null;
|
|
|
+ //#endif
|
|
|
constructor(app) {
|
|
|
this.app = app;
|
|
|
- this.allApp = getApp()
|
|
|
+ // #ifdef APP-PLUS-NVUE
|
|
|
+ this.allApp = getApp({allowDefault: true})
|
|
|
+ //#endif
|
|
|
}
|
|
|
/**
|
|
|
* 打开项目
|
|
@@ -84,10 +88,19 @@ class SocketEvent {
|
|
|
if(res.code == 'friend_add') {
|
|
|
if(this.app.utils.isJSON(res.data)) {
|
|
|
var data= JSON.parse(res.data);
|
|
|
+ // #ifdef APP-PLUS-NVUE
|
|
|
//消息提示
|
|
|
let bagenumAr = allApp.$store.state.txbagenum;
|
|
|
bagenumAr.applyCount ++;
|
|
|
allApp.$store.commit('setTxbagenum',bagenumAr);
|
|
|
+ //#endif
|
|
|
+ // #ifndef APP-PLUS-NVUE
|
|
|
+ //消息提示
|
|
|
+ let bagenumAr = store.state.txbagenum;
|
|
|
+ bagenumAr.applyCount ++;
|
|
|
+ store.commit('setTxbagenum',bagenumAr);
|
|
|
+ //#endif
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
|