Files
aeroresolve_backend/src/modules/master-data/dto/create-operator.dto.ts
T
Syed Waseem f3acfd2181 feat(master-data): add jurisdiction and rule category entities with CRUD operations
- Introduced Jurisdiction and RuleCategory entities along with their respective values.
- Implemented service methods for managing rule categories and values.
- Updated MasterDataService to include seeding logic for jurisdictions and rule categories.
- Added DTOs for creating and updating rule categories and values.

feat(policy-engine): enhance policy management with new entities and operations

- Created Policy, PolicyRule, PolicyAction, PolicyTargetAudience, and RuleCondition entities.
- Implemented create, update, and delete operations for policies and their associated rules and actions.
- Added enums for PolicyStatus and AudienceType to manage policy states and target audiences.
- Developed DTOs for creating and updating policies with nested structures for rules and audiences.
2026-07-21 11:22:54 +05:30

30 lines
851 B
TypeScript

import { ApiPropertyOptional } from '@nestjs/swagger';
import { IsBoolean, IsNotEmpty, IsOptional, IsString, IsNumber } from 'class-validator';
export class CreateOperatorDto {
@ApiPropertyOptional({ example: 'EQ', description: 'Unique operator code' })
@IsString()
@IsNotEmpty()
code: string;
@ApiPropertyOptional({ example: 'Equals', description: 'Display name of the operator' })
@IsString()
@IsNotEmpty()
name: string;
@ApiPropertyOptional({ example: '=', description: 'Operator symbol' })
@IsString()
@IsOptional()
symbol?: string;
@ApiPropertyOptional({ example: 1, description: 'Order used for display sorting' })
@IsNumber()
@IsOptional()
displayOrder?: number;
@ApiPropertyOptional({ example: true, description: 'Whether the operator is active' })
@IsBoolean()
@IsOptional()
isActive?: boolean;
}