0
public ViewResult Details(int ID)
{
tblMp3 item = db.tblMp3.Single(t => t.ID == ID);
ViewBag.Mp3Tags= db.tblTags.Where(c => c.tblMp3.Any(a => a.ID == ID)).ToList();
return View(item);
}
這是我的控制器,我讀到它不推薦使用ViewBag,我必須使用Model,但不幸的是我不知道該怎麼做,任何人都可以幫忙?由於將ViewBag轉換爲模型