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

export class PlantingOrderCreatedEvent implements DomainEvent {
  readonly type = 'PlantingOrderCreated';
  readonly aggregateType = 'PlantingOrder';
  readonly occurredAt: Date;

  constructor(
    public readonly aggregateId: string,
    public readonly data: {
      orderNo: string;
      userId: string;
      accountSequence: string;
      treeCount: number;
      totalAmount: number;
    },
  ) {
    this.occurredAt = new Date();
  }
}
