private void bNewAppointment_Click(object sender, EventArgs e)
        {
            AddAppointment addAppointment = new AddAppointment(selectedContractId);
            var            result         = addAppointment.ShowDialog();

            if (result == DialogResult.OK)
            {
                ContractRepository    repo = new ContractRepository();
                AppointmentRepository appointmentRepository = new AppointmentRepository();
                radGridView3.DataSource = appointmentRepository.getAppointmentByContractId(selectedContractId).ToList();
                radGridView1.DataSource = repo.getContractsByCustomerId(customerId).ToList();
            }
        }
 private void bNewAppointment_Click(object sender, EventArgs e)
 {
     AddAppointment addAppointment = new AddAppointment(selectedContractId);
     var result = addAppointment.ShowDialog();
     if (result == DialogResult.OK)
     {
         ContractRepository repo = new ContractRepository();
         AppointmentRepository appointmentRepository = new AppointmentRepository();
         radGridView3.DataSource = appointmentRepository.getAppointmentByContractId(selectedContractId).ToList();
         radGridView1.DataSource = repo.getContractsByCustomerId(customerId).ToList();
     }
 }