Exemplo n.º 1
0
        public static CobrandSettings CreateCobrandSettings(string cobrandSettingsXml)
        {
            CobrandSettings cobrandSettings = new CobrandSettings();

            if (!string.IsNullOrEmpty(cobrandSettingsXml))
            {
                cobrandSettings = MyProsperity.Framework.Xml.SerializationHelper.Deserialize <CobrandSettings>(cobrandSettingsXml);
            }

            if (cobrandSettings != null)
            {
                foreach (MobilePlatformType platformType in Enum.GetValues(typeof(MobilePlatformType)))
                {
                    if (cobrandSettings.MobileApps.All(a => a.Platform != platformType))
                    {
                        cobrandSettings.MobileApps.Add(new MobileAppSettings(platformType));
                    }
                }
            }

            return(cobrandSettings);
        }
Exemplo n.º 2
0
 public void UpdateCobrandSettingsXmlFromCobrandSettings()
 {
     CobrandSettingsXml = CobrandSettings.GetCobrandSettingsXml();
     _CobrandSettings   = null;
 }