public int UpdatePasswordByID(UsersModel Model) { String sql = "UPDATE Users SET uPwd=@uPwd WHERE UID=@UID"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@uPwd", Model.uPwd), new SqlParameter("@UID", Model.UID), })); }
public int UpdateByModel(RootMenuModel Model) { String sql = "UPDATE RootMenu SET Title=@Title,ParentID=@ParentID,Link=@Link WHERE ID=@ID"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@Title", Model.Title), new SqlParameter("@ParentID", Model.ParentID), new SqlParameter("@Link", Model.Link), })); }
public int InsertByModel(RootMenuModel Model) { String sql = "INSERT INTO RootMenu(Title,ParentID,Link) VALUES(@Title,@ParentID,@Link)"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@Title", Model.Title), new SqlParameter("@ParentID", Model.ParentID), new SqlParameter("@Link", Model.Link), })); }
public int UpdateByModel(UsersModel Model) { String sql = "UPDATE Users SET uPwd=@uPwd,UName=@UName WHERE UID=@UID"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@UID", Model.UID), new SqlParameter("@uPwd", Model.uPwd), new SqlParameter("@UName", Model.UName), })); }
public int InsertByModel(UsersModel Model) { String sql = "INSERT INTO Users(UCode,uPwd,UName) VALUES(@UCode,@uPwd,@UName)"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@UID", Model.UID), new SqlParameter("@UCode", Model.UCode), new SqlParameter("@uPwd", Model.uPwd), new SqlParameter("@UName", Model.UName), })); }
public int UpdateByModel(RoteInfoModel Model) { String sql = "UPDATE RoteInfo SET RID=@RIDRUID=@RUID,UID=@UID,RIP=@RIP,RCreateTime=@RCreateTime WHERE ID=@ID"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@RID", Model.RID), new SqlParameter("@RUID", Model.RUID), new SqlParameter("@UID", Model.UID), new SqlParameter("@RIP", Model.RIP), new SqlParameter("@RCreateTime", Model.RCreateTime), })); }
public int InsertByModel(RoteInfoModel Model) { String sql = "INSERT INTO RoteInfo(RUID,UID,RIP,RCreateTime) VALUES(@RUID,@UID,@RIP,@RCreateTime)"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@RID", Model.RID), new SqlParameter("@RUID", Model.RUID), new SqlParameter("@UID", Model.UID), new SqlParameter("@RIP", Model.RIP), new SqlParameter("@RCreateTime", Model.RCreateTime), })); }
public int UpdateByModel(ActionInfoModel Model) { String sql = "UPDATE ActionInfo SET AName=@AName,ADetail=@ADetail,ABeginTime=@ABeginTime,AEndTime=@AEndTime,AStatus=@AStatus WHERE AID=@AID"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@AID", Model.AID), new SqlParameter("@AName", Model.AName), new SqlParameter("@ADetail", Model.ADetail), new SqlParameter("@ABeginTime", Model.ABeginTime), new SqlParameter("@AEndTime", Model.AEndTime), new SqlParameter("@AStatus", Model.AStatus), })); }
public int InsertByModel(ActionInfoModel Model) { String sql = "INSERT INTO ActionInfo(AName,ADetail,ABeginTime,AEndTime,AStatus) VALUES(@AName,@ADetail,@ABeginTime,@AEndTime,@AStatus)"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@AID", Model.AID), new SqlParameter("@AName", Model.AName), new SqlParameter("@ADetail", Model.ADetail), new SqlParameter("@ABeginTime", Model.ABeginTime), new SqlParameter("@AEndTime", Model.AEndTime), new SqlParameter("@AStatus", Model.AStatus), })); }
public int InsertByModel(RoteUserModel Model) { String sql = "INSERT INTO RoteUser(AID,RUName,RUSex,RUAge,RUDetail,RUImGUrl) VALUES(@AID,@RUName,@RUSex,@RUAge,@RUDetail,@RUImGUrl)"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@RUID", Model.RUID), new SqlParameter("@AID", Model.AID), new SqlParameter("@RUName", Model.RUName), new SqlParameter("@RUSex", Model.RUSex), new SqlParameter("@RUAge", Model.RUAge), new SqlParameter("@RUDetail", Model.RUDetail), new SqlParameter("@RUImGUrl", Model.RUImGUrl), })); }
public int UpdateByModel(RoteUserModel Model) { String ImgSql = Model.RUImGUrl == ""?"":" ,RUImGUrl=@RUImGUrl "; String sql = "UPDATE RoteUser SET AID=@AID,RUName=@RUName,RUSex=@RUSex,RUAge=@RUAge,RUDetail=@RUDetail " + ImgSql + " WHERE RUID=@RUID"; return(DataBaseOpen.NoQuery(sql, new SqlParameter[] { new SqlParameter("@RUID", Model.RUID), new SqlParameter("@AID", Model.AID), new SqlParameter("@RUName", Model.RUName), new SqlParameter("@RUSex", Model.RUSex), new SqlParameter("@RUAge", Model.RUAge), new SqlParameter("@RUDetail", Model.RUDetail), new SqlParameter("@RUImGUrl", Model.RUImGUrl), })); }
public int DeleteByID(int ID) { String sql = "DELETE RoteUser WHERE RUID=" + ID; return(DataBaseOpen.NoQuery(sql)); }
public int DeleteByID(int ID) { String sql = "DELETE RootMenu WHERE ID=" + ID; return(DataBaseOpen.NoQuery(sql)); }
public int DeleteByID(int ID) { String sql = "DELETE ActionInfo WHERE AID=" + ID + " AND AStatus=1"; return(DataBaseOpen.NoQuery(sql)); }