Exemple #1
0
        /// <summary>
        /// 根据条件查询移库记录
        /// </summary>
        /// <param name="strStartTime"></param>
        /// <param name="strEndTime"></param>
        /// <param name="strCustomerName"></param>
        /// <param name="strMoveWarehouseBillNo"></param>
        /// <param name="strGoodsNo"></param>
        /// <param name="strWarehouse"></param>
        /// <param name="nOpStaffId"></param>
        /// <param name="strOpStaffName"></param>
        /// <param name="strErrText"></param>
        /// <returns></returns>
        public List<MoveWarehouseBillGoods> LoadMoveWarehouseBillGoodsByConditions(string strStartTime, string strEndTime, string strCustomerName, string strMoveWarehouseBillNo, string strGoodsNo, string strWarehouse, long nOpStaffId, string strOpStaffName, out string strErrText)
        {
            try
            {
                List<MoveWarehouseBillGoods> ret = null;

                using (TransactionScope transScope = new TransactionScope(TransactionScopeOption.Required, new TimeSpan(2, 0, 0)))
                {
                    using (StockDAO dao = new StockDAO())
                    {
                        ret = dao.LoadMoveWarehouseBillGoodsByConditions(strStartTime, strEndTime, strCustomerName, strMoveWarehouseBillNo, strGoodsNo, strWarehouse, nOpStaffId, strOpStaffName, out strErrText);
                        if (ret == null)
                            return null;
                    }
                    transScope.Complete();
                }
                return ret;
            }
            catch (Exception e)
            {
                strErrText = e.Message;
                return null;
            }
        }