Beispiel #1
0
 private void clear()
 {
     StoreNameTextBox.Clear();
     PickupTimeDateTimePicker.ResetText();
     CoversNumeric.Value = 0;
     CustomerNameTextBox.Clear();
     MemberNumberTextBox.Clear();
     CommentsTextBox.Clear();
     RespondCheckBox.Checked         = false;
     PaymentRequiredCheckBox.Checked = false;
 }
Beispiel #2
0
        public CheckInPage(string path)
        {
            InitializeComponent();
            SourceControlIntegration.BusyInProcessWhileDownloading = false;
            mPath = path;
            lblAnalyzedPath.Content = mPath;

            Init();

            SetCheckinGridView();
            CheckInFilesGrid.btnRefresh.AddHandler(Button.ClickEvent, new RoutedEventHandler(RefreshGrid));
            CheckInFilesGrid.AddToolbarTool("@CheckAllColumn_16x16.png", "Select All", new RoutedEventHandler(SelectAll));
            CheckInFilesGrid.AddToolbarTool("@UnCheckAllColumn_16x16.png", "Un-Select All", new RoutedEventHandler(UnSelectAll));
            CheckInFilesGrid.RowDoubleClick += CheckInFilesGrid_grdMain_MouseDoubleClick;
            CommentsTextBox.Focus();
        }
        public CheckInPage(string path)
        {
            InitializeComponent();
            SourceControlIntegration.BusyInProcessWhileDownloading = false;
            mPath = path;
            lblAnalyzedPath.Content = mPath;
            if (WorkSpace.Instance.Solution.SourceControl.GetSourceControlType == SourceControlBase.eSourceControlType.GIT)
            {
                xSourceControlBranchPanel.Visibility = Visibility.Visible;
                xSourceControlBranchLabel.Content    = WorkSpace.Instance.Solution.SourceControl.SourceControlBranch;
            }
            else
            {
                xSourceControlBranchPanel.Visibility = Visibility.Collapsed;
            }
            Init();

            SetCheckinGridView();
            CheckInFilesGrid.btnRefresh.AddHandler(Button.ClickEvent, new RoutedEventHandler(RefreshGrid));
            CheckInFilesGrid.AddToolbarTool("@CheckAllColumn_16x16.png", "Select All", new RoutedEventHandler(SelectAll));
            CheckInFilesGrid.AddToolbarTool("@UnCheckAllColumn_16x16.png", "Un-Select All", new RoutedEventHandler(UnSelectAll));
            CheckInFilesGrid.RowDoubleClick += CheckInFilesGrid_grdMain_MouseDoubleClick;
            CommentsTextBox.Focus();
        }
Beispiel #4
0
        private bool isFormValid()
        {
            if (FullNameTextBox.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Full Name is required");
                FullNameTextBox.Focus();
                return(false);
            }

            if (DateOfBirthDateTimePicker.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Date of Birth is required");
                DateOfBirthDateTimePicker.Focus();
                return(false);
            }

            if (CNICTextBox.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("CNIC is required");
                FullNameTextBox.Focus();
                return(false);
            }

            if ((MobileTextBox.Text.Trim() == string.Empty) && (TelephoneTextBox.Text.Trim() == string.Empty))
            {
                SMSMessageBox.ShowErrorMessage("Mobile or Telephone number is required");
                MobileTextBox.Focus();
                return(false);
            }

            if (GenderComboBox.SelectedIndex == -1)
            {
                SMSMessageBox.ShowErrorMessage("Gender is required");
                return(false);
            }

            if (EmploymentDateDateTimePicker.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Employment Date is required");
                EmploymentDateDateTimePicker.Focus();
                return(false);
            }

            if (AddressLineTextBox.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Address Line is required");
                AddressLineTextBox.Focus();
                return(false);
            }

            if (CityComboBox.SelectedIndex == -1)
            {
                SMSMessageBox.ShowErrorMessage("City is required");
                return(false);
            }

            if (DistrictComboBox.SelectedIndex == -1)
            {
                SMSMessageBox.ShowErrorMessage("District is required");
                return(false);
            }

            if (PostralCodeTextBox.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Postral code is required");
                PostralCodeTextBox.Focus();
                return(false);
            }

            if (JobTitleComboBox.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Job Title is required");
                JobTitleComboBox.Focus();
                return(false);
            }

            if (CurrentSalaryTextBox.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Current Salary is required");
                CurrentSalaryTextBox.Focus();
                return(false);
            }
            else
            {
                if (Convert.ToDecimal(CurrentSalaryTextBox.Text.Trim()) < 1)
                {
                    SMSMessageBox.ShowErrorMessage("Current Salary can not be zero or less than zero");
                    CurrentSalaryTextBox.Focus();
                    return(false);
                }
            }

            if (StartingSalaryTextBox.Text.Trim() == string.Empty)
            {
                SMSMessageBox.ShowErrorMessage("Starting Salary is required");
                StartingSalaryTextBox.Focus();
                return(false);
            }
            else
            {
                if (Convert.ToDecimal(StartingSalaryTextBox.Text.Trim()) < 1)
                {
                    SMSMessageBox.ShowErrorMessage("Starting Salary can not be zero or less than zero");
                    StartingSalaryTextBox.Focus();
                    return(false);
                }
            }

            if (HasLeftComboBox.Text == "Yes")
            {
                if (DateLeftDateTimePicker.Text.Trim() == string.Empty)
                {
                    SMSMessageBox.ShowErrorMessage("Date Left is required");
                    DateLeftDateTimePicker.Focus();
                    return(false);
                }

                if (ReasonLeftComboBox.Text.Trim() == string.Empty)
                {
                    SMSMessageBox.ShowErrorMessage("Leaving reason is required");
                    ReasonLeftComboBox.Focus();
                    return(false);
                }

                if (CommentsTextBox.Text.Trim() == string.Empty)
                {
                    SMSMessageBox.ShowErrorMessage("Leaving Comments are required");
                    CommentsTextBox.Focus();
                    return(false);
                }
            }
            return(true);
        }