From eea9ea3094e223d531ec058a1ef6e1656b0a5216 Mon Sep 17 00:00:00 2001 From: username@email.com <yzy2002yzy@163.com> Date: 星期一, 10 三月 2025 09:05:22 +0800 Subject: [PATCH] 送货单逾期不要 就是要订单没有送货的逾期 完成 送货管理下 未送货订单 /Pages/business/OrderSonghuoanchiList.aspx 01 --- CY_ECommercePlatform/CY.BLL/EC/EC_OrderBasicBLL.cs | 141 ++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 140 insertions(+), 1 deletions(-) diff --git a/CY_ECommercePlatform/CY.BLL/EC/EC_OrderBasicBLL.cs b/CY_ECommercePlatform/CY.BLL/EC/EC_OrderBasicBLL.cs index e397294..902ceab 100644 --- a/CY_ECommercePlatform/CY.BLL/EC/EC_OrderBasicBLL.cs +++ b/CY_ECommercePlatform/CY.BLL/EC/EC_OrderBasicBLL.cs @@ -42,10 +42,14 @@ { IEC_OrderBasicDAL _eC_OrderBasicDAL = null; IEC_OrderPrintParameterDAL _eC_OrderPrintParameterDAL = null; + IEC_OrderExtendDAL _eC_OrderExtendDAL = null; + IPay_TradingSingleDAL _pay_TradingSingleDAL = null; public EC_OrderBasicBLL() { _eC_OrderBasicDAL = AbstractFactory.Factory.GetDALByInterfaceName(AbstractFactory.DALInterface.IEC_OrderBasicDAL) as IEC_OrderBasicDAL; _eC_OrderPrintParameterDAL = AbstractFactory.Factory.GetDALByInterfaceName(AbstractFactory.DALInterface.IEC_OrderPrintParameterDAL) as IEC_OrderPrintParameterDAL; + _eC_OrderExtendDAL = AbstractFactory.Factory.GetDALByInterfaceName(AbstractFactory.DALInterface.IEC_OrderExtendDAL) as IEC_OrderExtendDAL; + _pay_TradingSingleDAL = AbstractFactory.Factory.GetDALByInterfaceName(AbstractFactory.DALInterface.IPay_TradingSingleDAL) as IPay_TradingSingleDAL; } /// <summary> @@ -169,6 +173,16 @@ } /// <summary> + /// 淇敼璁㈠崟鐘舵��(闈炴敮浠樼姸鎬佷笖涓嶅彲淇敼涓烘湭鍙楃悊鍜屽凡鍙楃悊) + /// </summary> + /// <param name="orderOperate">璁㈠崟鎿嶄綔</param> + /// <returns></returns> + public bool UpSurplusPrintNum(int? Keyid, int? SurplusPrintNum, string Operator) + { + return _eC_OrderExtendDAL.UpSurplusPrintNumsql(Keyid, SurplusPrintNum, Operator); + } + + /// <summary> /// 鏍规嵁缂栧彿鎵归噺鍒犻櫎鏁版嵁 /// </summary> /// <param name="currentOperator">褰撳墠鎿嶄綔浜�</param> @@ -281,6 +295,18 @@ public bool ReceiveMoneyToAccount(int orderId, OA_FirmAccountRecord firmAccountRecord) { return _eC_OrderBasicDAL.ReceiveMoneyToAccount(orderId, firmAccountRecord); + } + + + /// <summary> + /// 鏀舵(绾夸笅杞处銆佺幇閲�) + /// </summary> + /// <param name="orderId">璁㈠崟缂栧彿</param> + /// <param name="firmAccountRecord">鎿嶄綔璁板綍</param> + /// <returns></returns> + public bool ReceiveMoneyToQueren(int orderId, OA_FirmAccountRecord firmAccountRecord) + { + return _eC_OrderBasicDAL.ReceiveMoneyToQueren(orderId, firmAccountRecord); } /// <summary> @@ -520,6 +546,18 @@ return _eC_OrderBasicDAL.DeleteOutOrder(OrderId); } + + /// <summary> + /// 鍒犻櫎澶栧崗璁㈠崟 + /// </summary> + /// <param name="OrderId"></param> + /// <returns></returns> + public bool UpdateOldOrderSurplusPrintNum(int outOrderId) + { + return _eC_OrderBasicDAL.UpdateOldOrderSurplusPrintNum(outOrderId); + } + + /// <summary> /// 鏍规嵁鏂板璁㈠崟鎿嶄綔锛屽苟淇敼璁㈠崟鐘舵�� /// </summary> @@ -549,7 +587,7 @@ /// <returns></returns> public IEnumerable<EC_OrderBasic> GetModelPageListForPrepayments(Pagination pa, string DeliveryTime, string Province, string City, string County, string BuyerName, string BusinessManagerId, string SellerOrderId, string DocumentName, Guid SellerId) { - string Condition = " and ( ob.[OrderState] ='2' or ob.[OrderState] ='3' and SellerId='"+ SellerId + "' )"; + string Condition = " and ( ob.[OrderState] ='1' or ob.[OrderState] ='2' or ob.[OrderState] ='3' ) and SellerId='" + SellerId + "' "; if (!string.IsNullOrEmpty(DeliveryTime)) { @@ -621,6 +659,100 @@ Condition += " and ob.DocumentName like '%" + DocumentName + "%'"; ; } + + Query query = new Query(); + IList<Criterion> criterias = new List<Criterion>() + { + new Criterion("", Condition), + + new Criterion("orderBy"," [DeliveryTime] DESC ") + }; + query.Criteria = criterias; + return _eC_OrderBasicDAL.SelectModelPage_weiwangong(query, pa); + } + + + + + /// <summary> + /// 鏌ヨ瀹㈡埛棰勪粯娆惧垪琛� + /// </summary> + /// <param name="pa"></param> + /// <returns></returns> + public IEnumerable<EC_OrderBasic> GetModelPageListForSonghuoyanchis(Pagination pa, string DeliveryTime, string Province, string City, string County, string BuyerName, string BusinessManagerId, string SellerOrderId, string DocumentName, Guid SellerId) + { + string Condition = " and ( ob.[OrderState] ='1' or ob.[OrderState] ='2' or ob.[OrderState] ='3' or ob.[OrderState] ='4' ) and SellerId='" + SellerId + "' "; + + if (!string.IsNullOrEmpty(DeliveryTime)) + { + if (DeliveryTime == "鏄庡ぉ") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])=1 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])=1 )"; + } + else if (DeliveryTime == "鍚庡ぉ") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])=2 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])=2 )"; + } + else if (DeliveryTime == "3澶�") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])=3 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])=3 )"; + } + else if (DeliveryTime == "4澶�") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])=4 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])=4 )"; + } + else if (DeliveryTime == "5澶�") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])=5 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])=5) "; + } + else if (DeliveryTime == "6澶�") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])=6 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])=6) "; + } + else if (DeliveryTime == "7澶�") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])=7 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])=7 )"; + } + else if (DeliveryTime == "涓�鍛ㄥ悗") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime]) >7 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])>7 )"; + } + else if (DeliveryTime == "閫炬湡") + { + Condition += " and ( DATEDIFF(DAY,GETDATE(),ob.[DeliveryTime])<=0 or DATEDIFF(DAY,GETDATE(),oe.[DelayTime])<=0 )"; + } + + } + + if (!string.IsNullOrEmpty(Province)) + Condition += string.Format(" and CustomerCommunications.Province='{0}'", Province); + + if (!string.IsNullOrEmpty(City)) + Condition += string.Format(" and CustomerCommunications.City='{0}'", City); + + if (!string.IsNullOrEmpty(County)) + Condition += string.Format(" and CustomerCommunications.County='{0}'", County); + + if (!string.IsNullOrEmpty(BuyerName)) + { + Condition += " and ob.BuyerName like '%" + BuyerName + "%'"; + } + if (!string.IsNullOrEmpty(BusinessManagerId)) + { + Condition += string.Format(" and oe.BusinessManagerId='{0}'", BusinessManagerId); + } + + + + if (!string.IsNullOrEmpty(SellerOrderId)) + { + Condition += " and ob.SellerOrderId like '%" + SellerOrderId + "%'"; ; + } + if (!string.IsNullOrEmpty(DocumentName)) + { + Condition += " and ob.DocumentName like '%" + DocumentName + "%'"; ; + } + Query query = new Query(); IList<Criterion> criterias = new List<Criterion>() @@ -726,6 +858,13 @@ isWin = _eC_OrderPrintParameterDAL.UpdateModel(eC_OrderPrintParameter); + var pay_TradingSingles = _pay_TradingSingleDAL.GetOrderByIds(eC_OrderBasic.Keyid.Value).FirstOrDefault() ; + if (pay_TradingSingles != null) + { + pay_TradingSingles.TradingMoney = eC_OrderBasic.SumPrice.Value; + pay_TradingSingles.PayableMoney = eC_OrderBasic.SumPrice.Value; + isWin = _pay_TradingSingleDAL.UpdateModel(pay_TradingSingles); + } return isWin; } -- Gitblit v1.9.1