Exemple #1
0
        private void ButtonMenuAllPeople_Click(object sender, RoutedEventArgs e)
        {
            MenuPage.Content = allPeoplePageView;
            lblTitle.Content = "REFERENCES";

            ButtonMenuAllPeople.Background = Brushes.MediumSeaGreen;
            refIcon.Foreground             = Brushes.White;
            refLable.Foreground            = Brushes.White;

            ButtonMenuPeopleIn.Background = null;
            historyIcon.Foreground        = Brushes.MediumSeaGreen;
            historyLable.Foreground       = Brushes.MediumSeaGreen;

            ButtonMenuHome.Background = null;
            homeIcon.Foreground       = Brushes.MediumSeaGreen;
            homeLable.Foreground      = Brushes.MediumSeaGreen;

            ButtonMenuReaders.Background = null;
            readerIcon.Foreground        = Brushes.MediumSeaGreen;
            readerLable.Foreground       = Brushes.MediumSeaGreen;

            ButtonMenuCameras.Background = null;
            cameraIcon.Foreground        = Brushes.MediumSeaGreen;
            cameraLable.Foreground       = Brushes.MediumSeaGreen;

            ButtonMenuAdmins.Background = null;
            adminIcon.Foreground        = Brushes.MediumSeaGreen;
            adminLable.Foreground       = Brushes.MediumSeaGreen;

            ButtonMenuActivityLogs.Background = null;
            logsIcon.Foreground  = Brushes.MediumSeaGreen;
            logsLable.Foreground = Brushes.MediumSeaGreen;

            allPeoplePageView.LoadPersonsData().ConfigureAwait(false);
        }
Exemple #2
0
        public async void DeleteRefPerson(string id, AllPeoplePageView allPeoplePageView)
        {
            ProgressDialogController controller = await this.ShowProgressAsync("Please wait...", "");

            controller.SetIndeterminate();
            controller.SetCancelable(false);

            controller.SetMessage("Deleting database record");
            await Task.Run(() => Models.Dynamodb.DeleteItem(id, Models.MyAWSConfigs.RefPersonsDBTableName));

            controller.SetMessage("Deleting image");
            await Task.Run(() => Models.S3Bucket.DeleteFile(id, Models.MyAWSConfigs.RefImagesBucketName));

            await controller.CloseAsync();

            allPeoplePageView.LoadPersonsData().ConfigureAwait(false);

            notifyIcon.Visible = true;
            notifyIcon.ShowBalloonTip(1000, "Deleted", "Person deleted Successfully", System.Windows.Forms.ToolTipIcon.Info);
        }