public IActionResult Delete(int id, DeleteSingerViewModel model) { var singer = _singerAppService.GetSingerById(id); model = new DeleteSingerViewModel() { Id = singer.Id, Name = singer.Name }; return(PartialView("_Delete", model)); }
public IActionResult Delete(DeleteSingerViewModel model) { _singerAppService.Delete(model.Id); return(Json(new JsonResultEntity() { Message = "删除成功", JsonObject = Json(new SingerViewModel() { Id = model.Id }) })); }