mirror of
https://github.com/docmost/docmost.git
synced 2026-05-07 06:23:06 +08:00
feat(base): emit base:rows:deleted websocket event
This commit is contained in:
@@ -9,6 +9,7 @@ import {
|
||||
BasePropertyUpdatedEvent,
|
||||
BaseRowCreatedEvent,
|
||||
BaseRowDeletedEvent,
|
||||
BaseRowsDeletedEvent,
|
||||
BaseRowReorderedEvent,
|
||||
BaseRowUpdatedEvent,
|
||||
BaseSchemaBumpedEvent,
|
||||
@@ -63,6 +64,17 @@ export class BaseWsConsumers {
|
||||
});
|
||||
}
|
||||
|
||||
@OnEvent(EventName.BASE_ROWS_DELETED)
|
||||
onRowsDeleted(e: BaseRowsDeletedEvent) {
|
||||
this.ws.emitToBase(e.baseId, {
|
||||
operation: 'base:rows:deleted',
|
||||
baseId: e.baseId,
|
||||
rowIds: e.rowIds,
|
||||
actorId: e.actorId ?? null,
|
||||
requestId: e.requestId ?? null,
|
||||
});
|
||||
}
|
||||
|
||||
@OnEvent(EventName.BASE_ROW_REORDERED)
|
||||
onRowReordered(e: BaseRowReorderedEvent) {
|
||||
this.ws.emitToBase(e.baseId, {
|
||||
|
||||
Reference in New Issue
Block a user