在Html.ActionLink中运用二维判断语句

@Html.ActionLink("公告信息", "notice", "article", null, new { @class = ViewData["getclass"]!="notice"?"":"currclass" })
@Html.ActionLink("历史查询", "index", "home", new { hd = DateTime.Today.ToString("yyyy-MM-dd") }, new { @class = ViewData["getclass"] == "order" && Request["hd"] != null ? "currclass" : "" })

 

你可能感兴趣的:(action)