File: D:/HostingSpaces/TDijk1/erp-apps.eu/wwwroot/App_Code/CMSModules/Ecommerce/GoPay/Config.cs
using System;
using System.Collections.Generic;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
using CMS.CMSHelper;
using CMS.SettingsProvider;
using CMS.GlobalHelper;
using CMS.DataEngine;
using CMS.SiteProvider;
using CMS.Helpers;
namespace CMS.Ecommerce.Gopay{
public class Config {
/// <summary>
/// URL platebni brany pro uplnou integraci
/// </summary>
public static bool IsTestMode
{
get
{
return SettingsKeyInfoProvider.GetBoolValue(SiteContext.CurrentSiteName + ".CMSIsTestMode");
}
}
/// <summary>
/// URL platebni brany pro uplnou integraci
/// </summary>
public static string FullIntegrationUrl
{
get
{
if (IsTestMode)
return SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSTestGatewayUrl");
else
return SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSGatewayUrl");
}
}
/// <summary>
/// URL WSDL webservice
/// </summary>
public static string WsWsdl
{
get
{
if (IsTestMode)
return SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSTestWsWsdlUrl");
else
return SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSWsWsdlUrl");
}
}
/// <summary>
/// URL webservice
/// </summary>
public static string Ws
{
get
{
if (IsTestMode)
return SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSTestWsUrl");
else
return SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSWsUrl");
}
}
public static string SecureKey
{
get
{
return SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSGoPaySecretKey");
}
}
public static long GOID
{
get
{
return Convert.ToInt64(SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSGoPayId"));
}
}
public static string CALLBACK_URL
{
get
{
return "http://" + SiteContext.CurrentSite.DomainName + URLHelper.ResolveUrl("~/CMSModules/Ecommerce/CMSPages/GoPayPN.aspx");
}
}
public static string SUCCESS_URL
{
get
{
return "http://" + SiteContext.CurrentSite.DomainName + URLHelper.ResolveUrl(SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSGoPaySuccessUrl"));
}
}
public static string FAILED_URL
{
get
{
return "http://" + SiteContext.CurrentSite.DomainName + URLHelper.ResolveUrl(SettingsKeyInfoProvider.GetValue(SiteContext.CurrentSiteName + ".CMSGoPayFailedUrl"));
}
}
}
}