import { ApiProperty } from '@nestjs/swagger';

export class WorkflowStageDto {
  @ApiProperty()
  stageId: string;
  @ApiProperty()
  stageKey: string;
  @ApiProperty()
  stageName: string;
  @ApiProperty()
  stageOrder: number;
  @ApiProperty()
  stageCategory: string;
  @ApiProperty()
  description: string;
  @ApiProperty({ type: Object, required: false })
  prerequisiteRulesConfig?: any;
  @ApiProperty({ type: Object, required: false })
  executionRulesConfig?: any;
  @ApiProperty({ type: Object, required: false })
  actionButtons?: any;
  @ApiProperty({ type: Object, required: false })
  completionActionsConfig?: any;
}

export class WorkflowConfigurationResponseDto {
  @ApiProperty()
  workflowId: number;

  @ApiProperty()
  workflowKey: string;
  
  @ApiProperty()
  workflowName: string;
  @ApiProperty()
  programType: string;
  @ApiProperty()
  workflowVersion: string;
  @ApiProperty()
  lifecycleStatus: string;
  @ApiProperty()
  description: string;
  @ApiProperty()
  lastUpdated: string;
  @ApiProperty({ type: Object })
  registrationRules: any;
  @ApiProperty({ type: Object })
  initialStage: any;
  @ApiProperty({ type: [WorkflowStageDto] })
  stages: WorkflowStageDto[];
  @ApiProperty({ type: Object })
  independentActions: any;
}
