ec-nest/src/agency/dto.ts
liuyun 856e906740 feat(c0): agency 机构模块(按租户读写机构信息)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-10-14 12:48:27 +08:00

62 lines
1.5 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { ApiPropertyOptional } from '@nestjs/swagger';
import { IsDateString, IsInt, IsOptional, IsString, Min } from 'class-validator';
/**
* 更新机构信息。仅暴露业务可编辑字段:
* - 不含主键 `code`(= 租户 code,服务端按 ctx.tenantCode 注入);
* - 不含 `locCode`/`locName`(参保地,PRD 定为只读);
* - 不含 `createdAt/createdBy/updatedAt/deletedAt`(系统字段)。
*/
export class UpdateAgencyDto {
@ApiPropertyOptional({ description: '机构名称' })
@IsOptional()
@IsString()
orgName?: string;
@ApiPropertyOptional({ description: '机构类型' })
@IsOptional()
@IsString()
orgType?: string;
@ApiPropertyOptional({ description: '统一社会信用代码' })
@IsOptional()
@IsString()
creditCode?: string;
@ApiPropertyOptional({ description: '服务来源' })
@IsOptional()
@IsString()
svcSource?: string;
@ApiPropertyOptional({ description: '许可证号' })
@IsOptional()
@IsString()
licenseNo?: string;
@ApiPropertyOptional({ description: '地址' })
@IsOptional()
@IsString()
address?: string;
@ApiPropertyOptional({ description: '法人/联系人' })
@IsOptional()
@IsString()
contactName?: string;
@ApiPropertyOptional({ description: '联系方式' })
@IsOptional()
@IsString()
contactPhone?: string;
@ApiPropertyOptional({ description: '床位数' })
@IsOptional()
@IsInt()
@Min(0)
bedCount?: number;
@ApiPropertyOptional({ description: '签约日期(YYYY-MM-DD)' })
@IsOptional()
@IsDateString()
signDate?: string;
}