/// <summary>
        /// Updates the current configuration.
        /// </summary>
        public async Task UpdateAsync(UpdateAppConfigVM request)
        {
            var config = await _db.Config
                         .FirstAsync();

            _mapper.Map(request, config);
        }
Beispiel #2
0
        public async Task <ActionResult> Update(UpdateAppConfigVM vm)
        {
            await _configMgr.UpdateAsync(vm);

            await _db.SaveChangesAsync();

            _config.ResetCache();

            return(RedirectToSuccess("Настройки сохранены"));
        }