/// <summary> /// 读取指定组织部门的员工记录 /// </summary> /// <param name="nOrganId"></param> /// <param name="nOpStaffId"></param> /// <param name="strOpStaffName"></param> /// <param name="strErrText"></param> /// <returns></returns> public List <Staff> LoadStaffsByOrganId(long nOrganId, long nOpStaffId, string strOpStaffName, out string strErrText) { try { List <Staff> dataResult = null; strErrText = String.Empty; using (TransactionScope transScope = new TransactionScope(TransactionScopeOption.Required, new TimeSpan(2, 0, 0))) { using (StaffDAO dao = new StaffDAO()) { dataResult = dao.LoadStaffsByOrganId(nOrganId, nOpStaffId, strOpStaffName, out strErrText); } transScope.Complete(); } return(dataResult); } catch (Exception e) { strErrText = e.Message; return(null); } }