import { DomainEvent } from './domain-event.interface';

export class TransferCompletedEvent implements DomainEvent {
  readonly type = 'TransferCompleted';
  readonly aggregateType = 'TransferOrder';
  readonly occurredAt: Date;

  constructor(
    public readonly aggregateId: string,
    public readonly data: {
      transferOrderNo: string;
      sellerUserId: string;
      sellerAccountSequence: string;
      buyerUserId: string;
      buyerAccountSequence: string;
      sourceOrderNo: string;
      treeCount: number;
      contributionPerTree: string;
      selectedProvince: string;
      selectedCity: string;
      originalAdoptionDate: string;
      originalExpireDate: string;
      transferPrice: string;
      completedAt: string;
    },
  ) {
    this.occurredAt = new Date();
  }
}
