public Language(LanguageInputViewModel obj) { Key = obj.Key; Page = obj.Page; Vi = obj.Vi; En = obj.En; }
public async Task <IActionResult> Index(LanguageInputViewModel model) { if (!ModelState.IsValid) { return(this.View(model)); } int id = default(int); try { id = await this.languageService.SaveFormData(model, this.userName); } catch (Exception e) { this.logger.LogDebug(e, $"An exception happened for user {userName}"); return(this.BadRequest()); } return(this.Redirect(Url.RouteUrl(new { controller = "Resume", action = "Display" }) + $"#{id}")); }