public async Task Remove_Language_From_Host()
        {
            await _languageManager.RemoveAsync(null, "tr");

            var languages = await _languageManager.GetLanguagesAsync(null);

            languages.Count.ShouldBe(2);
            languages.FirstOrDefault(l => l.Name == "tr").ShouldBeNull();
        }
        public async Task DeleteLanguage(string code)
        {
            using (CurrentUnitOfWork.DisableFilter(AbpDataFilters.SoftDelete))
            {
                //Much texts, many memory
                DeleteAllTextsFromLanguage(code);
                var language = _languagesRepository.FirstOrDefault(a => a.Name == code);
                await _applicationLanguageManager.RemoveAsync(AbpSession.TenantId, code);

                await _languagesAppNotificationSender.SendLanguageDeletedNotification(language, (await GetCurrentUserAsync()));
            }
        }
        public async Task DeleteLanguage(EntityDto input)
        {
            var language = await _languageRepository.GetAsync(input.Id);

            await _applicationLanguageManager.RemoveAsync(AbpSession.TenantId, language.Name);
        }
Пример #4
0
 public async Task RemoveAsync(int?tenantId, string languageName)
 {
     await _languageManager.RemoveAsync(tenantId, languageName);
 }