示例#1
0
 private void Search()
 {
     _projectDataContext  = new ProjectDataContext();
     _agencyRepository    = new AgencyRepository(_projectDataContext);
     dgvDuLieu.DataSource = _agencyRepository.GetAll().OrderBy(_ => _.AgencyName);
     Control();
 }
        public void GetAllAgencies()
        {
            Response <List <Agency> > response = new Response <List <Agency> >();

            agencyRepo.Insert(AGENCY1);
            agencyRepo.Insert(AGENCY2);
            agencyRepo.Insert(AGENCY3);

            response = agencyRepo.GetAll();
            Assert.AreEqual(3, response.Data.Count);
        }
示例#3
0
 public IHttpActionResult GetAll()
 {
     return(Json(_ar.GetAll()));
 }