/**
  * @param type
  * @param param
  * @return
  */
 public String getDeptOrPerson(String type, String param) {
   List<User> list = new ArrayList<User>();
   User u = new User();
   if (type.equals("first")) {
     // 业务组
     u.setDeptCode("");
     u.setDepartName("请选择业务组");
     list.add(u);
     User user = new User();
     user.setDeptPath(param);
     if (param != null && !param.equals("")) {
       list.addAll(houseAndRoomMapper.selectByFirst(user));
     }
   } else if (type.equals("second")) {
     // 主管
     u.setStaffid("");
     u.setStaffName("请选择主管");
     list.add(u);
     User user = new User();
     user.setDeptPath(param);
     list.addAll(houseAndRoomMapper.selectBySecond(user));
   } else if (type.equals("third")) {
     // 管家
     u.setStaffid("");
     u.setStaffName("请选择管家");
     list.add(u);
     User user = new User();
     user.setDeptPath(param);
     list.addAll(houseAndRoomMapper.selectByThird(user));
   }
   return GeneralUtils.easyUI(list);
 }
 /**
  * 搜索房屋业务处理方法
  *
  * @param house
  * @return
  */
 public String searchHouse(House house) {
   User user = (User) SessionManager.getAttr(SessionManager.USER_KEY);
   if (user.getSetidJobcode() != null && user.getSetidJobcode().equals("专员")) {
     house.setStaffid(user.getStaffid());
   } else if (user.getSetidJobcode() != null && user.getSetidJobcode().equals("主管")) {
     house.setDepartName(user.getDeptCode());
   } else {
     house.setDepartName(user.getDeptCode());
   }
   if (house.getR1() != null && !house.getR1().equals("")) {
     User u = new User();
     u.setStaffid(house.getR1());
     u = houseAndRoomMapper.selectByStaff(u);
     house.setR1(u.getDeptCode());
   }
   return GeneralUtils.easyUI(
       houseAndRoomMapper.countHouse(house), houseAndRoomMapper.searchHouseList(house));
 }