Asp.net源码专业站
首页->上传下载->香蕉Flash在线(Linq)源码>>com.bn388.BLL/Error.cs>>源码在线查看
温馨提示:代码在线浏览功能只能做为源码浏览参考,如果想更进一步了解该代码请下载:香蕉Flash在线(Linq)源码
当前文件:文件类型 BNFlashLinQ/com.bn388.BLL/Error.cs[2K,2009-6-12 11:34:37]打开代码结构图
普通视图
		            
1using System; 2using System.Collections.Generic; 3using System.Linq; 4using System.Text; 5using System.Web; 6 7namespace com.bn388.BLL 8{ 9 public class Error 10 { 11 private static IDAL.Error obj = DALFactory.DataAccess.Create_Error(); 12 13 public static bool add(Model.Error model) 14 { 15 if (obj.add(model) > 0) 16 { 17 return true; 18 } 19 else 20 { 21 return false; 22 } 23 } 24 25 public static bool delete(string id) 26 { 27 if (obj.delete(id) > 0) 28 { 29 return true; 30 } 31 else 32 { 33 return false; 34 } 35 } 36 37 public static bool update(Model.Error model) 38 { 39 if (obj.update(model) > 0) 40 { 41 return true; 42 } 43 else 44 { 45 return false; 46 } 47 } 48 49 public static List<Model.Error> get_List() 50 { 51 return obj.get_List(); 52 } 53 54 public static Model.Error get_Model(string ip) 55 { 56 return obj.get_Model(ip); 57 } 58 59 public static int count() 60 { 61 return obj.count(); 62 } 63 64 public static bool IsLock() 65 { 66 string ip = com.bn388.Tools.Web.GetIP(); 67 if (obj.count(ip) > 0) 68 { 69 Model.Error model = get_Model(ip); 70 if (model.locked == 2) 71 { 72 return true; 73 } 74 else 75 { 76 return false; 77 } 78 } 79 else 80 { 81 return false; 82 } 83 } 84 85 public static void Login_Error() 86 { 87 string ip = com.bn388.Tools.Web.GetIP(); 88 if (obj.count(ip) > 0) 89 { 90 Model.Error model = get_Model(ip); 91 model.count = model.count + 1; 92 if (model.count >= 3) 93 { 94 model.locked = 2; 95 } 96 obj.update(model); 97 } 98 else 99 { 100 Model.Error model = new Model.Error(); 101 model.count = 1; 102 model.dt = DateTime.Now; 103 model.ip = ip; 104 model.locked = 1; 105 add(model); 106 } 107 } 108 109 } 110} 111
还没有找到您心仪的内容?请用.net源码大搜捕
代码片断 打包下载该项目完整源码:香蕉Flash在线(Linq)源码
51Aspx.com 版权所有 CopyRight © 2006-2010. 京ICP备06046876号 本站法律顾问:ITlaw-庄毅雄律师
返回顶部
客户服务:点击这里进行客户咨询 业务合作:点击这里洽谈业务合作 合作热线:010-68880146