public async Task <TownDTO> GetTown([FromBody] TownDTO townDTO)
        {
            if (townDTO == null)
            {
                townDTO = new TownDTO();
            }
            var town = new Town {
                Id = townDTO.Id
            };

            town = await TownService.Get(town.Id);

            return(town == null ? null : new TownDTO
            {
                Id = town.Id,
                Code = town.Code,
                Name = town.Name,
                DistrictId = town.DistrictId,
            });
        }
 public Town Get(long id)
 {
     return(_townService.Get(id));
 }