private void AddPaymentLog(PaymentBILog logInfo) { string tableName = BITypes.Payment.ToString(); Dictionary <string, object> values = new Dictionary <string, object>() { { "UserId", logInfo.UserId }, { "RemoteAdress", logInfo.RemoteAdress }, { "CashCount", logInfo.CashCount }, { "GameTokenCount", logInfo.GameTokenCount }, { "RewardTokenCount", logInfo.RewardTokenCount }, { "AttachInfo", logInfo.AttachInfo } }; db.Insert(tableName, values); }
public void AddNewMail(string message, int AttachId, int AttachCount) { if (CacheSet.ItemTable.GetData(AttachId) == null && CacheSet.GearTable.GetData(AttachId) == null && CacheSet.SoulTable.GetData(AttachId) == null && CacheSet.EpigraphTable.GetData(AttachId) == null) { return; } DBProvider db = new DBProvider("Game"); Dictionary <string, object> values = new Dictionary <string, object>(); values["Message"] = message; values["AttachType"] = AttachId; values["AttachCount"] = AttachCount; values["BeginTime"] = DateTime.UtcNow.ToString("yyyy-MM-dd HH:mm:ss"); DateTime expireDay = DateTime.UtcNow.AddDays(GameConfigs.GetInt("Mail_Expire_Days", 7)); values["ExpireTime"] = expireDay.ToString("yyyy-MM-dd HH:mm:ss"); values["ToUser"] = m_UserId; db.Insert("mails", values); }