public static async Task<AssetBasicViewModel> ToBasicViewModelAsync(this IAsset model) { if (model == null) return null; var viewModel = new AssetBasicViewModel(); await model.ExtrudeBasicInfo(viewModel); return viewModel; }
private static async Task ExtrudeBasicInfo(this IAsset model, AssetBasicViewModel viewModel) { viewModel.Id = model.Id; viewModel.Url = model.Url; }