public override async Task <IDisplayResult> UpdateAsync(StaffPart part, IUpdateModel updater, UpdatePartEditorContext context) { var viewModel = new StaffPartViewModel(); await updater.TryUpdateModelAsync(viewModel, Prefix); part.SomeText.Text = viewModel.SomeText; return(await EditAsync(part, context)); }
private static void PopulateViewModel(StaffPart part, StaffPartViewModel viewModel) { viewModel.SomeText = part.SomeText.Text; }