update city and provincve

This commit is contained in:
2026-02-16 08:56:34 +03:30
parent f965e47bfd
commit ee6e989396
2 changed files with 8 additions and 10 deletions
@@ -1,5 +1,5 @@
import { IsString, IsOptional, IsNumber, IsBoolean, Min, Max } from 'class-validator';
import { ApiPropertyOptional } from '@nestjs/swagger';
import { ApiPropertyOptional,ApiProperty } from '@nestjs/swagger';
/**
* DTO for updating a user address.
@@ -15,15 +15,13 @@ export class UpdateUserAddressDto {
@IsString()
address?: string;
@ApiPropertyOptional({ description: 'City name', example: 'Tehran' })
@IsOptional()
@ApiProperty({ description: 'City name', example: 'Tehran' })
@IsString()
city?: string;
city: string;
@ApiPropertyOptional({ description: 'Province', example: 'Tehran Province' })
@IsOptional()
@ApiProperty({ description: 'Province', example: 'Tehran Province' })
@IsString()
province?: string;
province: string;
@ApiPropertyOptional({ description: 'Postal/ZIP code', example: '12345-6789' })
@IsOptional()
@@ -14,10 +14,10 @@ export class UserAddress extends BaseEntity {
address!: string;
@Property()
city!: string;
city: string;
@Property({ nullable: true })
province?: string;
@Property()
province: string;
@Property({ nullable: true })
postalCode?: string | null = null;