Beispiel #1
0
        private async void InitializeAppData()
        {
            //Zal.CommandExecutedOffline += OnCommandExecutedOffline;
            await Task.Run(async() => {
                //Zal.LoadOfflineCommands(LoadFromStorage(OFFLINE_COMMANDS_FILE));
                //Zal.LoadDataFrom(await LoadFromStorageAsync(LOCAL_DATA_FILE));
                var a = await LoadFromStorageAsync(LOCAL_DATA_FILE);
                //Zal.LoadDataFrom(a);
                await Zal.Session.TryLoginWithTokenAsync();
                await Zal.StartSynchronizingAsync();
            });

            OnAppReady();
        }
Beispiel #2
0
 private async void LogOutButton_Clicked(object sender, EventArgs args)
 {
     Zal.Logout();
     Navigation.InsertPageBefore(new LoginPage(), Navigation.NavigationStack.First());
     await Navigation.PopToRootAsync();
 }
Beispiel #3
0
        protected override void OnSleep()
        {
            var a = Zal.GetDataJson();

            SaveToStorage(LOCAL_DATA_FILE, a);
        }