/// <summary> /// 删除冲帐记录数据 /// </summary> /// <param name="nId"></param> /// <param name="nOpStaffId"></param> /// <param name="strOpStaffName"></param> /// <param name="strErrText"></param> /// <returns></returns> public bool DeleteContractReverse(long nId, long nOpStaffId, string strOpStaffName, out string strErrText) { try { using (TransactionScope transScope = new TransactionScope(TransactionScopeOption.Required, new TimeSpan(2, 0, 0))) { using (ContractDAO dao = new ContractDAO()) { if (!dao.DeleteContractReverse(nId, nOpStaffId, strOpStaffName, out strErrText)) { return(false); } if (!dao.DeleteContractReverseDetails(nId, nOpStaffId, strOpStaffName, out strErrText)) { return(false); } } transScope.Complete(); } return(true); } catch (Exception e) { strErrText = e.Message; return(false); } }