예제 #1
0
        public async Task <LanguageReadResponse> GetLanguage(LanguageReadRequest request)
        {
            var response = new LanguageReadResponse();

            var language = await _languageRepository.Select(x => x.Uid == request.LanguageUid);

            if (language.IsNotExist())
            {
                response.SetInvalidBecauseEntityNotFound();
                return(response);
            }

            response.Item   = _languageFactory.CreateDtoFromEntity(language);
            response.Status = ResponseStatus.Success;
            return(response);
        }