mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
fix chat estracture
This commit is contained in:
@@ -75,6 +75,7 @@ export class MessageLocalDataSourceService {
|
||||
|
||||
async getLastMessageByRoomId(roomId: string): Promise<Result<undefined|TableMessage, any>> {
|
||||
try {
|
||||
console.log({roomId})
|
||||
const lastMessage = await messageDataSource.message
|
||||
.where('roomId')
|
||||
.equals(roomId)
|
||||
@@ -107,7 +108,7 @@ export class MessageLocalDataSourceService {
|
||||
}
|
||||
|
||||
|
||||
// @ValidateSchema(tableSchema)
|
||||
// @ValidateSchema(tableSchema)
|
||||
async createMessage(data: MessageInputDTO) {
|
||||
|
||||
try {
|
||||
|
||||
@@ -179,6 +179,10 @@ export class RoomLocalDataSourceService {
|
||||
return await roomDataSource.room.toArray()
|
||||
}
|
||||
|
||||
getMemberLive(data: {roomId, wxUserId}) {
|
||||
const $roomIdUserId = data.roomId + data.wxUserId
|
||||
return liveQuery(() => roomDataSource.memberList.get($roomIdUserId)) as any;
|
||||
}
|
||||
|
||||
getItemsLive(): Observable<RoomListOutPutDTO[]> {
|
||||
return liveQuery(() => roomDataSource.room.toArray()) as any;
|
||||
|
||||
+6
-2
@@ -11,8 +11,12 @@ export class UserTypingLiveDataSourceService {
|
||||
private SignalRLiveDataSourceService: SignalRService
|
||||
) { }
|
||||
|
||||
sendTyping(roomId) {
|
||||
return this.SignalRLiveDataSourceService.sendTyping({roomId, UserName:SessionStore.user.FullName})
|
||||
sendTyping(roomId, ) {
|
||||
return this.SignalRLiveDataSourceService.sendTyping({
|
||||
roomId,
|
||||
UserName:SessionStore.user.FullName,
|
||||
userId:SessionStore.user.UserId
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user