public WaterPropertyDTO getWaterPropertyById(int id) { var query = from s in db.Geology_WaterProperties where s.ID == id select s; var item = query.FirstOrDefault(); WaterPropertyDTO res = Mapper.Map <WaterPropertyDTO>(item); return(res); }
public List <WaterPropertyDTO> getWaterPropertyByProject(string project) { List <WaterProperty> pws = getAllByProject <WaterProperty>(project); return(WaterPropertyDTO.transferList(pws)); }