Exemplo n.º 1
0
        public CatalogDataClient()
        {
            _ConfigFetcher = DependencyService.Get<IConfigFetcher>();

            _ApiServiceUrl = _ConfigFetcher.GetAsync("catalogDataServiceUrl").Result;
            _ApiAppKey = _ConfigFetcher.GetAsync("catalogDataServiceAppKey", true).Result;
        }
Exemplo n.º 2
0
        public CatalogDataClient()
        {
            _ConfigFetcher = DependencyService.Get <IConfigFetcher>();

            _ApiServiceUrl = _ConfigFetcher.GetAsync("catalogDataServiceUrl").Result;
            _ApiAppKey     = _ConfigFetcher.GetAsync("catalogDataServiceAppKey", true).Result;
        }
Exemplo n.º 3
0
 public BaseViewModel(INavigation navigation)
 {
     Navigation            = navigation;
     configFetcher         = DependencyService.Get <IConfigFetcher>();
     authenticationService = DependencyService.Get <IAuthenticationService>();
     //TODO A CHANGER
     UserAccountModel = authenticationService.GetUserAccount().Result;
 }
Exemplo n.º 4
0
        protected ConfigServiceBase(IConfigFetcher configFetcher, IConfigCache configCache, ILogger log)
        {
            this.configFetcher = configFetcher;

            this.configCache = configCache;

            this.log = log;
        }
Exemplo n.º 5
0
 internal AutoPollConfigService(
     IConfigFetcher configFetcher,
     CacheParameters cacheParameters,
     TimeSpan pollingInterval,
     TimeSpan maxInitWaitTime,
     ILogger logger) : this(configFetcher, cacheParameters, pollingInterval, maxInitWaitTime, logger, true)
 {
 }
Exemplo n.º 6
0
 internal AutoPollConfigService(
     IConfigFetcher configFetcher,
     IConfigCache configCache,
     TimeSpan pollingInterval,
     TimeSpan maxInitWaitTime,
     ILoggerFactory loggerFactory) : this(configFetcher, configCache, pollingInterval, maxInitWaitTime, loggerFactory, true)
 {
 }
Exemplo n.º 7
0
        AuthInfo()
        {
            _ConfigFetcher = DependencyService.Get <IConfigFetcher>();

            _Client = new MobileServiceClient(
                _ConfigFetcher.GetAsync("customerDataServiceUrl").Result,
                _ConfigFetcher.GetAsync("customerDataServiceAppKey", true).Result);
        }
Exemplo n.º 8
0
        AuthInfo()
        {
            _ConfigFetcher = DependencyService.Get<IConfigFetcher>();

            _Client = new MobileServiceClient(
                _ConfigFetcher.GetAsync("customerDataServiceUrl").Result,
                _ConfigFetcher.GetAsync("customerDataServiceAppKey", true).Result);
        }
Exemplo n.º 9
0
        private MobileDataSync()
        {
            _ConfigFetcher = DependencyService.Get <IConfigFetcher>();

            var serviceUrl    = _ConfigFetcher.GetAsync("dataServiceUrl").Result;
            var serviceAppKey = _ConfigFetcher.GetAsync("dataServiceAppKey", true).Result;

            _Client = new MobileServiceClient(serviceUrl, serviceAppKey);
        }
Exemplo n.º 10
0
        private MobileDataSync()
        {
            _ConfigFetcher = DependencyService.Get<IConfigFetcher>();

            var serviceUrl = _ConfigFetcher.GetAsync("dataServiceUrl").Result;
            var serviceAppKey = _ConfigFetcher.GetAsync("dataServiceAppKey", true).Result;

            _Client = new MobileServiceClient(serviceUrl, serviceAppKey);
        }
Exemplo n.º 11
0
        protected ConfigServiceBase(IConfigFetcher configFetcher, CacheParameters cacheParameters, ILogger log)
        {
            this.configFetcher = configFetcher;

            this.configCache = cacheParameters.ConfigCache;

            this.cacheKey = cacheParameters.CacheKey;

            this.log = log;
        }
        public AuthenticationService()
        {
            _ConfigFetcher = DependencyService.Get<IConfigFetcher>();

            _Authenticator = DependencyService.Get<IAuthenticator>();

            _ClientId = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationClientId", true).Result;
            _TenantAuthority = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationTenantAuthorityUrl").Result;
            _ReturnUri = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationReturnUri").Result;
            _ResourceUri = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationResourceUri").Result;
        }
Exemplo n.º 13
0
        public AuthenticationService()
        {
            _ConfigFetcher = DependencyService.Get <IConfigFetcher>();

            _Authenticator = DependencyService.Get <IAuthenticator>();

            _ClientId        = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationClientId", true).Result;
            _TenantAuthority = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationTenantAuthorityUrl").Result;
            _ReturnUri       = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationReturnUri").Result;
            _ResourceUri     = _ConfigFetcher.GetAsync("azureActiveDirectoryAuthenticationResourceUri").Result;
        }
Exemplo n.º 14
0
        internal AutoPollConfigService(
            IConfigFetcher configFetcher,
            IConfigCache configCache,
            TimeSpan pollingInterval,
            TimeSpan maxInitWaitTime,
            ILoggerFactory loggerFactory) : base(configFetcher, configCache, loggerFactory.GetLogger(nameof(AutoPollConfigService)))
        {
            this.timer = new Timer(RefreshLogic, "auto", TimeSpan.Zero, pollingInterval);

            this.maxInitWaitExpire = DateTime.UtcNow.Add(maxInitWaitTime);
        }
Exemplo n.º 15
0
        public SplashListViewModel(INavigation navigation = null) : base(navigation)
        {
            _ConfigFetcher = DependencyService.Get <IConfigFetcher>();

            Items = new List <SplashItemViewModel>()
            {
                new SplashItemViewModel()
                {
                    Title = "HOW IT WORKS",
                    Uri   = "https://www.x4ever.club/"
                },

                new SplashItemViewModel()
                {
                    Title = "SUCCESS STORIES",
                    Uri   = "http://blog.organogold.com/category/x4ever/"
                },

                new SplashItemViewModel()
                {
                    Title = "REWARDS",
                    Uri   = "https://www.x4ever.club/rewards/"
                },

                new SplashItemViewModel()
                {
                    Title = "BROCHURE",
                    Uri   = "https://www.x4ever.club/wp-content/uploads/2017/10/X_challenge_brochure_v3.pdf"
                },

                new SplashItemViewModel()
                {
                    Title = "BUY PRODUCT",
                    Uri   = "http://shopog.com/en-us/productcategory.aspx?lnmt=1&pt=0&catid=23"
                },

                new SplashItemViewModel()
                {
                    Title = "COMMUNITY",
                    Uri   = "https://www.facebook.com/X4ever.club/"
                },
            };

            Overview =
                "Xamarin CRM is a demo app whose imagined purpose is to serve the mobile workforce of a " +
                "fictitious company that sells 3D printer hardware and supplies. The app empowers salespeople " +
                "to track their sales performance, manage leads, view their contacts, manage orders, and " +
                "browse a product catalog.";

            ListHeading =
                "The app is built with Xamarin Platform and Xamarin.Forms, and takes advantage of " +
                "several other supporting technologies:";
        }
Exemplo n.º 16
0
        /// <summary>
        /// For test purpose only
        /// </summary>
        /// <param name="configFetcher"></param>
        /// <param name="cacheParameters"></param>
        /// <param name="pollingInterval"></param>
        /// <param name="maxInitWaitTime"></param>
        /// <param name="logger"></param>
        /// <param name="startTimer"></param>
        internal AutoPollConfigService(
            IConfigFetcher configFetcher,
            CacheParameters cacheParameters,
            TimeSpan pollingInterval,
            TimeSpan maxInitWaitTime,
            ILogger logger,
            bool startTimer
            ) : base(configFetcher, cacheParameters, logger)
        {
            if (startTimer)
            {
                this.timer = new Timer(RefreshLogic, "auto", TimeSpan.Zero, pollingInterval);
            }

            this.maxInitWaitExpire = DateTime.UtcNow.Add(maxInitWaitTime);
        }
Exemplo n.º 17
0
 public AppConfiguration()
 {
     AppConfig          = new AppConfig();
     ImageSizes         = new List <ImageSize>();
     _helper            = new Helper();
     _configFetcher     = DependencyService.Get <IConfigFetcher>();
     _secureStorage     = DependencyService.Get <ISecureStorage>();
     _localize          = DependencyService.Get <ILocalize>();
     _deviceProperty    = DependencyService.Get <ISetDeviceProperty>();
     BackgroundColor    = Palette._MainBackground;
     StatusBarColor     = Palette._MainAccent;
     BackgroundImage    = TextResources.icon_background_blur;
     IsFullScreenMode   = true;
     ActivityType       = ActivityType.NONE;
     IsConnected        = false;
     IsAnimationAllowed = true;
     InitialTasks();
 }
Exemplo n.º 18
0
        public AuthenticationService()
        {
            _ConfigFetcher = DependencyService.Get <IConfigFetcher>();

            _Authenticator = DependencyService.Get <IAuthenticator>();
        }
Exemplo n.º 19
0
 internal ManualPollConfigService(IConfigFetcher configFetcher, CacheParameters cacheParameters, ILogger logger)
     : base(configFetcher, cacheParameters, logger)
 {
 }
 internal LazyLoadConfigService(IConfigFetcher configFetcher, IConfigCache configCache, ILoggerFactory loggerFactory, TimeSpan cacheTimeToLive)
     : base(configFetcher, configCache, loggerFactory.GetLogger(nameof(LazyLoadConfigService)))
 {
     this.cacheTimeToLive = cacheTimeToLive;
 }
Exemplo n.º 21
0
 public SplashViewModel(INavigation navigation = null)
     : base(navigation)
 {
     _ConfigFetcher = DependencyService.Get <IConfigFetcher>();
 }
Exemplo n.º 22
0
 internal LazyLoadConfigService(IConfigFetcher configFetcher, CacheParameters cacheParameters, ILogger logger, TimeSpan cacheTimeToLive)
     : base(configFetcher, cacheParameters, logger)
 {
     this.cacheTimeToLive = cacheTimeToLive;
 }
Exemplo n.º 23
0
 public FakeConfigService(IConfigFetcher configFetcher, CacheParameters cacheParameters, ILogger log) : base(configFetcher, cacheParameters, log)
 {
 }
Exemplo n.º 24
0
 public ExternalLoginConfigurationService()
 {
     _configurationService = DependencyService.Get <IConfigFetcher>();
 }
Exemplo n.º 25
0
        public AuthenticationAzureADService()
        {
            _configFetcher = DependencyService.Get <IConfigFetcher>();

            _authenticator = DependencyService.Get <IAuthenticator>();
        }
Exemplo n.º 26
0
        public CustomerDataClient()
        {
            MobileService = AuthInfo.Instance.GetMobileServiceClient();
			_ConfigFetcher = DependencyService.Get<IConfigFetcher>();
        }
 internal ManualPollConfigService(IConfigFetcher configFetcher, IConfigCache configCache, ILoggerFactory loggerFactory)
     : base(configFetcher, configCache, loggerFactory.GetLogger(nameof(ManualPollConfigService)))
 {
 }
Exemplo n.º 28
0
        public AuthenticationService()
        {
            _ConfigFetcher = DependencyService.Get<IConfigFetcher>();

            _Authenticator = DependencyService.Get<IAuthenticator>();
        }
 public IdentityService()
 {
     _userRepository      = DependencyService.Get <IUserProfileRepository>();
     _localStorageService = DependencyService.Get <ILocalStorageService>();
     _configFetcher       = DependencyService.Get <IConfigFetcher>();
 }
Exemplo n.º 30
0
 public SplashPageViewModel(INavigation navigation = null)
     : base(navigation)
 {
     _ConfigFetcher = DependencyService.Get<IConfigFetcher>();
 }