/// <summary>获取所有部门</summary> /// <returns>部门List</returns> public List <DepartmentModel> GetAllList() { List <DepartmentModel> depList = new List <DepartmentModel>(); depList = DepartmentPersistence.GetAllList(); return(depList); }
public async void GetMustMatch() { var domainmodels = GetDepartmentDomainModels(); var persistence = new DepartmentPersistence(_contextFactoryMock.Object, _mapper); var getdepts = await persistence.GetAllAsync(); getdepts.Should().BeEquivalentTo(domainmodels); }
public getSingleDept GetProg(string id) { DepartmentPersistence de = new DepartmentPersistence(); getSingleDept dept = de.oneProgID(id); if (dept == null) { throw new HttpResponseException(new HttpResponseMessage(HttpStatusCode.NotFound)); } return(dept); }
public List <getAllDepts> GetEnt(string id) { DepartmentPersistence de = new DepartmentPersistence(); List <getAllDepts> dept = de.OneEntName(id); if (dept == null) { throw new HttpResponseException(new HttpResponseMessage(HttpStatusCode.NotFound)); } return(dept); }
public ArrayList Get() { DepartmentPersistence de = new DepartmentPersistence(); return(de.allDepts()); }