Skip to content

SudoSOS Back-end API / internal/subscribers/transaction-subscriber / TransactionSubscriber

Class: TransactionSubscriber ​

Implements ​

  • EntitySubscriberInterface

Constructors ​

Constructor ​

ts
new TransactionSubscriber(): TransactionSubscriber;

Returns ​

TransactionSubscriber

Methods ​

afterInsert() ​

ts
afterInsert(event): Promise<void>;

Called after entity is inserted to the database.

Parameters ​

ParameterType
eventInsertEvent<Transaction>

Returns ​

Promise<void>

Implementation of ​

ts
EntitySubscriberInterface.afterInsert

listenTo() ​

ts
listenTo(): string | Function;

Returns the class of the entity to which events will listen. If this method is omitted, then subscriber will listen to events of all entities.

Returns ​

string | Function

Implementation of ​

ts
EntitySubscriberInterface.listenTo