/// <summary> /// 加载单个实体对象 /// </summary> /// <param name="reader"></param> /// <returns></returns> private static AttachPaymentlogInfo LoadSingleAttachPaymentlogInfo(IDataReader reader) { AttachPaymentlogInfo attachPaymentlogInfo = new AttachPaymentlogInfo(); attachPaymentlogInfo.Id = TypeConverter.ObjectToInt(reader["id"]); attachPaymentlogInfo.Uid = TypeConverter.ObjectToInt(reader["uid"]); attachPaymentlogInfo.UserName = reader["username"].ToString().Trim(); attachPaymentlogInfo.Aid = TypeConverter.ObjectToInt(reader["aid"]); attachPaymentlogInfo.Authorid = TypeConverter.ObjectToInt(reader["authorid"]); attachPaymentlogInfo.PostDateTime = Convert.ToDateTime(reader["postdatetime"]); attachPaymentlogInfo.Amount = TypeConverter.ObjectToInt(reader["amount"]); attachPaymentlogInfo.NetAmount = TypeConverter.ObjectToInt(reader["netamount"]); return(attachPaymentlogInfo); }
/// <summary> /// 创建附件交易信息 /// </summary> /// <param name="attachPaymentLogInfo">要创建的附件交易信息</param> /// <returns>创建的交易id</returns> public static int CreateAttachPaymentLog(AttachPaymentlogInfo attachPaymentLogInfo) { return(Data.AttachPaymentLogs.CreateAttachPaymentLog(attachPaymentLogInfo)); }
/// <summary> /// 更新的附件交易信息 /// </summary> /// <param name="attachPaymentLogInfo">要更新的附件交易信息</param> /// <returns></returns> public static int UpdateAttachPaymetLog(AttachPaymentlogInfo attachPaymentLogInfo) { return(DatabaseProvider.GetInstance().UpdateAttachPaymetLog(attachPaymentLogInfo)); }