摘要: 1 public ActionResult xx([Bind(Exclude = "id")] xxModel xx, HttpPostedFileBase file)//排除id验证2 3 //Bind(Include="name,age") 只允许name和age验证ModelState.Re... 阅读全文
posted @ 2015-07-15 16:10 X-Jonney 阅读(716) 评论(0) 推荐(0) 编辑
摘要: 1 List parameters = new List();2 SqlParameter param; 3 foreach (...)4 {5 param = new SqlParameter(...);6 parameters.Add(param);7 }8 SqlParameter[] p =... 阅读全文
posted @ 2015-07-15 16:01 X-Jonney 阅读(117) 评论(0) 推荐(0) 编辑
摘要: [翻译] 使用ASP.NET MVC操作过滤器记录日志原文地址:http://www.singingeels.com/Articles/Logging_with_ASPNET_MVC_Action_Filters.aspx翻译:Anders Liu摘要:日志记录是一种常见的交错关注点(Cross-C... 阅读全文
posted @ 2015-07-15 15:57 X-Jonney 阅读(337) 评论(0) 推荐(0) 编辑