public OfferedClass() { SectionClass = new Section(); SubjectClass = new Subject(); EmployeeClass = new Dll.Employee.Employee(); }
public void PersonMapTest() { var p = new Employee.Employee(); dynamic item = new ExpandoObject(); item.Id = 9; //String p.PersonClass.DataMapper.Map(_ => _.BirthCountry, "Philippines"); Debug.WriteLine("Birth Country " + p.PersonClass.BirthCountry); Assert.AreEqual("Philippines", p.PersonClass.BirthCountry); //int p.PersonClass.DataMapper.Map(_ => _.Id, 9); Debug.WriteLine("Id " + p.PersonClass.Id); Assert.AreEqual(9, p.PersonClass.Id); //Date Time p.PersonClass.DataMapper.Map(_ => _.BirthDate, DateTime.Today); Debug.WriteLine("BirthDate " + p.PersonClass.BirthDate); Assert.AreEqual(DateTime.Today, p.PersonClass.BirthDate); //int var myId = (int)item.Id; p.PersonClass.DataMapper.Map(_ => _.Id, myId); Debug.WriteLine("Id " + p.PersonClass.Id); Assert.AreEqual(9, p.PersonClass.Id); }
private void loginbtn_Click(object sender, RoutedEventArgs e) { string tx = passtxtbox.Text; if (tx.Length >= 8) { this.id = this.idtxtbox.Text; this.password = this.passtxtbox.Text; this.result = this.l.IsLogInValid(id, password); if (result == 1) { this.Hide(); Admin.Admin a = new Admin.Admin(); a.Show(); } else if (result == 2) { this.Hide(); Employee.Employee ee = new Employee.Employee(); ee.Show(); } else if (result == 0) { MessageBox.Show("Invalid ID or Password"); } else { } } else { MessageBox.Show("Wrong Password"); } }
public void PersonMapSameObjectTest() { var p = new Employee.Employee(); var q = p.PersonClass.DataMapper.Item(); Assert.AreSame(p.PersonClass, q); }
public PayrollEmployee() { DataMapper = new PayrollEmployeeDataMapper(this); EmployeeClass = new Employee.Employee(); PositionClass = new Position(); TaxClass = new Tax(); Deductions = new PayrollEmployeeDeductionCollection(this); }
public HolidayRequest(Employee.Employee requester, Employee.Employee manager, TimeInterval timeInterval) { Requester = requester; Manager = manager; TimeInterval = timeInterval; }