public NewDepartmentModal()
        {
            InitializeComponent();

            DataContext = new DepartmentViewControl();

            departmentControl = new DepartmentControl();
            companyControl    = new CompanyControl();
        }
        private void btnAddDpt_Click(object sender, RoutedEventArgs e)
        {
            var success = DepartmentControl.AddDepartment();

            if (success != null)
            {
                UpdateBindings();
                MessageBox.Show("Database updated!", "info");
            }
        }
Esempio n. 3
0
        public DepartmentRegisterView()
        {
            InitializeComponent();

            departmentControl     = new DepartmentControl();
            companyControl        = new CompanyControl();
            departmentViewControl = new DepartmentViewControl();

            DataContext = departmentViewControl;
        }
        private void btnEditDpt_Click(object sender, RoutedEventArgs e)
        {
            if (DepartmentsListView.SelectedItems.Count < 1)
            {
                return;
            }

            DepartmentControl.UpdateDepartment();
            UpdateBindings();
            MessageBox.Show("Database updated!", "info");
        }
        private void DepartmentsListView_SelectionChanged(object sender,
                                                          System.Windows.Controls.SelectionChangedEventArgs e)
        {
            if (e.AddedItems.Count != 0)
            {
                if (CompanyListView.SelectedItems.Count > 0)
                {
                    CompanyListView.SelectedIndex = -1;
                }

                DepartmentControl.SetDepartment(e.AddedItems[0] as Department);
            }
        }
Esempio n. 6
0
        public EmployeeReportView()
        {
            InitializeComponent();

            employeeControl   = new EmployeeControl();
            companyControl    = new CompanyControl();
            departmentControl = new DepartmentControl();
            officeControl     = new OfficeControl();

            fillGriddEmployee();
            fillCBCompany();
            fillCBDepartment();
            fillCBOffice();
        }
Esempio n. 7
0
        public RecessRegisterView()
        {
            InitializeComponent();

            recessControl     = new RecessControl();
            companyControl    = new CompanyControl();
            departmentControl = new DepartmentControl();
            recessViewControl = new RecessViewControl();

            DataContext = recessViewControl;

            fillCBCompany();
            fillCBDepartment();
        }
        public ExportTaxFilesModal()
        {
            InitializeComponent();

            DateTime firstDayOfMonth = new DateTime(DateTime.Now.Date.Year, DateTime.Now.Date.Month, 1);
            DateTime lastDayOfMonth  = firstDayOfMonth.AddMonths(1).AddDays(-1);

            DPStartDate.SelectedDate = firstDayOfMonth;
            DPEndDate.SelectedDate   = lastDayOfMonth;

            companyControl       = new CompanyControl();
            departmentControl    = new DepartmentControl();
            exportTaxFileControl = new ExportTaxFileControl();

            fillCBCompany();
            fillCBDepartment();
        }
Esempio n. 9
0
        public DailyPointView()
        {
            InitializeComponent();

            DPDate.SelectedDate = DateTime.Now.Date;

            markingControl        = new MarkingControl();
            companyControl        = new CompanyControl();
            departmentControl     = new DepartmentControl();
            officeControl         = new OfficeControl();
            dailyPointViewControl = new DailyPointViewControl();

            fillGriddDailyMarking();
            fillCBCompany();
            fillCBDepartment();
            fillCBOffice();

            DataContext = dailyPointViewControl;
        }
        public EmployeeRegisterView()
        {
            InitializeComponent();

            employeeControl          = new EmployeeControl();
            companyControl           = new CompanyControl();
            scheduleControl          = new ScheduleControl();
            departmentControl        = new DepartmentControl();
            officeControl            = new OfficeControl();
            resignationReasonControl = new ResignationReasonControl();
            employeeViewControl      = new EmployeeViewControl();

            DataContext = employeeViewControl;

            fillCBCompany();
            fillCBSchedule();
            fillCBDepartment();
            fillCBOffice();
            fillCBRReasons();
            fillImageControl();
        }
        public MarkingCardView()
        {
            InitializeComponent();

            DateTime firstDayOfMonth = new DateTime(DateTime.Now.Date.Year, DateTime.Now.Date.Month, 1);
            DateTime lastDayOfMonth = firstDayOfMonth.AddMonths(1).AddDays(-1);

            DPStartDate.SelectedDate = firstDayOfMonth;
            DPEndDate.SelectedDate = lastDayOfMonth;

            markingControl = new MarkingControl();
            companyControl = new CompanyControl();
            departmentControl = new DepartmentControl();
            officeControl = new OfficeControl();
            employeeControl = new EmployeeControl();
            markingCardViewControl = new MarkingCardViewControl();

            fillCBCompany();
            fillCBDepartment();
            fillCBOffice();

            DataContext = markingCardViewControl;
        }