readNotification 에서의 로직 개선.
This commit is contained in:
parent
cc73faaaa3
commit
2f3a76a7f7
@ -925,30 +925,6 @@ export class Effects {
|
|||||||
})
|
})
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// not opened room :: unread count increased
|
|
||||||
if (
|
|
||||||
action.SVC_TYPE === SVC_TYPE_EVENT &&
|
|
||||||
action.SSVC_TYPE === SSVC_TYPE_EVENT_SEND_RES
|
|
||||||
) {
|
|
||||||
/**
|
|
||||||
* 다른 디바이스에서 대화를 송신 할경우 RES 가 noti 로 유입될 수 있다.
|
|
||||||
* 이때 unread count 를 중가하지 않는다.
|
|
||||||
*/
|
|
||||||
} else {
|
|
||||||
if (!roomInfo || roomInfo.roomSeq !== action.roomSeq) {
|
|
||||||
if (!!trgtRoomInfos && !!trgtRoomInfos[action.roomSeq]) {
|
|
||||||
const noReadCnt = trgtRoomInfos[action.roomSeq].noReadCnt;
|
|
||||||
this.store.dispatch(
|
|
||||||
SyncStore.updateUnreadCount({
|
|
||||||
roomSeq: action.roomSeq,
|
|
||||||
noReadCnt: noReadCnt + 1
|
|
||||||
})
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (action.info.type === EventType.File) {
|
if (action.info.type === EventType.File) {
|
||||||
// File 정보 수집.
|
// File 정보 수집.
|
||||||
@ -962,6 +938,28 @@ export class Effects {
|
|||||||
})
|
})
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
// not opened room :: unread count increased
|
||||||
|
if (
|
||||||
|
action.SVC_TYPE === SVC_TYPE_EVENT &&
|
||||||
|
action.SSVC_TYPE === SSVC_TYPE_EVENT_SEND_RES
|
||||||
|
) {
|
||||||
|
/**
|
||||||
|
* 다른 디바이스에서 대화를 송신 할경우 RES 가 noti 로 유입될 수 있다.
|
||||||
|
* 이때 unread count 를 중가하지 않는다.
|
||||||
|
*/
|
||||||
|
} else {
|
||||||
|
if (!!trgtRoomInfos && !!trgtRoomInfos[action.roomSeq]) {
|
||||||
|
const noReadCnt = trgtRoomInfos[action.roomSeq].noReadCnt;
|
||||||
|
this.store.dispatch(
|
||||||
|
SyncStore.updateUnreadCount({
|
||||||
|
roomSeq: action.roomSeq,
|
||||||
|
noReadCnt: noReadCnt + 1
|
||||||
|
})
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 대화 > 리스트 :: finalEventMessage refresh
|
// 대화 > 리스트 :: finalEventMessage refresh
|
||||||
this.store.dispatch(ChatStore.newEventMessage(action));
|
this.store.dispatch(ChatStore.newEventMessage(action));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user