示例#1
0
        private void btnUpdate_Click(object sender, EventArgs e)
        {
            int             selectedrowindex = bunifuCustomDataGrid1.SelectedCells[0].RowIndex;
            DataGridViewRow selectedRow      = bunifuCustomDataGrid1.Rows[selectedrowindex];

            Repair rp = new Repair();

            rp.RepairCode = Convert.ToString(selectedRow.Cells[0].Value);
            rp.ErrorCode  = Convert.ToString(selectedRow.Cells[1].Value);
            rp.JobStatus  = (rbFinished.Checked) ? "Finished" : "Pending";

            RepairController rc = new RepairController();

            if (rc.updateJbStatus(rp))
            {
                MyDialog.Show("Success...!", "Status updated");
            }
            else
            {
                MyDialog.Show("Error...!", "Status not updated");
            }

            checkForErrors(tbxSearchBox.Text, (cmbFilter.SelectedIndex == 0));
        }
示例#2
0
 public repair_details()
 {
     InitializeComponent();
     rc = new RepairController();
 }
示例#3
0
 public add_repair_types()
 {
     InitializeComponent();
     rc = new RepairController();
 }
示例#4
0
 public update_job_status()
 {
     InitializeComponent();
     rc = new RepairController();
 }