private void setBtn_Click(object sender, System.EventArgs e) { ContractBO newContract = new ContractBO(); newContract.ContractName = contractNameBx.Text; ContractDAL contractData = new ContractDAL(); int contractID = contractData.insertContract(newContract); RateScheduleBO rateSchedule = new RateScheduleBO(); rateSchedule.ContractID = contractID; rateSchedule.RateScheduleName = contractNameBx.Text; rateSchedule.Coverage.StartDate = System.DateTime.Today; rateSchedule.Coverage.EndDate = System.DateTime.Today; // Add by default to Development rateSchedule.Status = "3"; RateScheduleDAL rateScheduleData = new RateScheduleDAL(); rateScheduleData.insertRateSchedule(rateSchedule); ContractAdded(this, EventArgs.Empty); this.Close(); }
private void setBtn_Click(object sender, System.EventArgs e) { RateScheduleDAL rateScheduleData = new RateScheduleDAL(); RateScheduleBO rateSchedule = new RateScheduleBO(); rateSchedule.ContractID = rmsController.ContractID; rateSchedule.Status = statusTypeCode; rateSchedule.RateScheduleName = rateScheduleNameBx.Text; rateSchedule.Coverage.StartDate = System.DateTime.Today; rateSchedule.Coverage.EndDate = System.DateTime.Today; rateScheduleData.insertRateSchedule(rateSchedule); RateScheduleAdded(this, EventArgs.Empty); this.Close(); }