private void HandleRiskInformationNotification(RiskInformationNotification notification) { NotificationSerialNumber = notification.serialnumber; string providerName = GoogleCheckoutLog.GetProviderNameFromOrderNumber(notification.googleordernumber); if (providerName.Length > 0) { GCheckoutNotificationHandlerProvider provider = GCheckoutNotificationManager.Providers[providerName]; if (provider != null) { provider.HandleRiskInformationNotification(RequestXml, notification); return; } } // if no provider found just log it SiteSettings siteSettings = CacheHelper.GetCurrentSiteSettings(); GoogleCheckoutLog gLog = new GoogleCheckoutLog(); gLog.SiteGuid = siteSettings.SiteGuid; gLog.RawResponse = RequestXml; gLog.NotificationType = "RiskInformationNotification"; gLog.SerialNumber = notification.serialnumber; gLog.OrderNumber = notification.googleordernumber; gLog.GTimestamp = notification.timestamp; gLog.AvsResponse = notification.riskinformation.avsresponse; gLog.CvnResponse = notification.riskinformation.cvnresponse; gLog.BuyerId = notification.riskinformation.ipaddress; gLog.Save(); }
private void HandleChargebackAmountNotification(ChargebackAmountNotification notification) { NotificationSerialNumber = notification.serialnumber; string providerName = GoogleCheckoutLog.GetProviderNameFromOrderNumber(notification.googleordernumber); if (providerName.Length > 0) { GCheckoutNotificationHandlerProvider provider = GCheckoutNotificationManager.Providers[providerName]; if (provider != null) { provider.HandleChargebackAmountNotification(RequestXml, notification); return; } } // if no provider found just log it SiteSettings siteSettings = CacheHelper.GetCurrentSiteSettings(); GoogleCheckoutLog gLog = new GoogleCheckoutLog(); gLog.SiteGuid = siteSettings.SiteGuid; gLog.NotificationType = "ChargebackAmountNotification"; gLog.RawResponse = RequestXml; gLog.SerialNumber = notification.serialnumber; gLog.OrderNumber = notification.googleordernumber; gLog.GTimestamp = notification.timestamp; gLog.LatestChargeback = notification.latestchargebackamount.Value; gLog.TotalChargeback = notification.totalchargebackamount.Value; gLog.Save(); }
private void HandleOrderStateChangeNotification(OrderStateChangeNotification notification) { NotificationSerialNumber = notification.serialnumber; string providerName = GoogleCheckoutLog.GetProviderNameFromOrderNumber(notification.googleordernumber); if (providerName.Length > 0) { GCheckoutNotificationHandlerProvider provider = GCheckoutNotificationManager.Providers[providerName]; if (provider != null) { provider.HandleOrderStateChangeNotification(RequestXml, notification); return; } } // if no provider found just log it log.Info("No GCheckoutNotification Provider found for google order " + notification.googleordernumber + " so just logging it"); Guid orderGuid = GoogleCheckoutLog.GetCartGuidFromOrderNumber(notification.googleordernumber); SiteSettings siteSettings = CacheHelper.GetCurrentSiteSettings(); GoogleCheckoutLog gLog = new GoogleCheckoutLog(); gLog.SiteGuid = siteSettings.SiteGuid; gLog.RawResponse = RequestXml; gLog.NotificationType = "OrderStateChangeNotification"; gLog.SerialNumber = notification.serialnumber; gLog.OrderNumber = notification.googleordernumber; gLog.FinanceState = notification.newfinancialorderstate.ToString(); gLog.FullfillState = notification.newfulfillmentorderstate.ToString(); gLog.GTimestamp = notification.timestamp; gLog.AvsResponse = notification.reason; gLog.CartGuid = orderGuid; gLog.Save(); }
private void HandleAuthorizationAmountNotification(AuthorizationAmountNotification notification) { NotificationSerialNumber = notification.serialnumber; string providerName = GoogleCheckoutLog.GetProviderNameFromOrderNumber(notification.googleordernumber); if (providerName.Length > 0) { GCheckoutNotificationHandlerProvider provider = GCheckoutNotificationManager.Providers[providerName]; if (provider != null) { provider.HandleAuthorizationAmountNotification(RequestXml, notification); return; } } // if no provider found just log it SiteSettings siteSettings = CacheHelper.GetCurrentSiteSettings(); GoogleCheckoutLog gLog = new GoogleCheckoutLog(); gLog.SiteGuid = siteSettings.SiteGuid; gLog.NotificationType = "AuthorizationAmountNotification"; gLog.RawResponse = RequestXml; gLog.SerialNumber = notification.serialnumber; gLog.OrderNumber = notification.googleordernumber; gLog.GTimestamp = notification.timestamp; gLog.AuthAmt = notification.authorizationamount.Value; gLog.AuthExpDate = notification.authorizationexpirationdate; gLog.CvnResponse = notification.cvnresponse; gLog.AvsResponse = notification.avsresponse; gLog.Save(); }