/// <summary> /// 生存返还卡片押金订单 /// </summary> /// <param name="card"></param> /// <param name="operatorId"></param> /// <returns></returns> public static ParkOrder MarkUserCardDepositRefundOrder(BaseCard card, string operatorId, DbOperator dbOperator) { ParkOrder order = GetUserCardDepositRefundOrder(card, operatorId); IParkOrder factory = ParkOrderFactory.GetFactory(); return(factory.Add(order, dbOperator)); }
/// <summary> /// 生存VIP卡续期订单 /// </summary> /// <param name="grantId"></param> /// <param name="originalStartDate"></param> /// <param name="originalEndDate"></param> /// <param name="newStartDate"></param> /// <param name="newEndDate"></param> /// <param name="renewalMonth"></param> /// <param name="operatorId"></param> /// <param name="dbOperator"></param> /// <returns></returns> public static ParkOrder AddVipCardOrder(string parkingId, string grantId, DateTime originalStartDate, DateTime originalEndDate, DateTime newStartDate, DateTime newEndDate, int renewalMonth, string operatorId, DbOperator dbOperator) { ParkOrder order = GenerateVipCardOrderModel(parkingId, grantId, originalStartDate, originalEndDate, newEndDate, newEndDate, renewalMonth, operatorId); IParkOrder factory = ParkOrderFactory.GetFactory(); return(factory.Add(order, dbOperator)); }
public static ParkOrder AddMonthlyRentOrderCS(string parkingId, string carTypeId, string grantId, DateTime originalStartDate, DateTime originalEndDate, DateTime newStartDate, DateTime newEndDate, int renewalMonth, int pkLotQuantit, string operatorId, decimal Amount, DbOperator dbOperator) { ParkOrder order = GenerateMonthCardOrderModelCS(parkingId, carTypeId, grantId, originalEndDate, originalEndDate, newStartDate, newEndDate, renewalMonth, pkLotQuantit, Amount, operatorId); IParkOrder factory = ParkOrderFactory.GetFactory(); return(factory.Add(order, dbOperator)); }
/// <summary> /// 生存储值卡续费订单 /// </summary> /// <param name="rechargeMoney"></param> /// <param name="card"></param> /// <param name="operatorId"></param> /// <param name="dbOperator"></param> /// <returns></returns> public static ParkOrder AddStoredValueCarOrder(string parkingId, decimal rechargeMoney, BaseCard card, string operatorId, DbOperator dbOperator) { ParkOrder order = GenerateStoredValueCarOrderModel(parkingId, rechargeMoney, card, operatorId); IParkOrder factory = ParkOrderFactory.GetFactory(); return(factory.Add(order, dbOperator)); }
/// <summary> /// 生存商家充值订单 /// </summary> /// <param name="seller">商家信息</param> /// <param name="chargeBalance">充值金额</param> /// <param name="operatorId">操作者编号</param> /// <param name="dbOperator"></param> /// <returns></returns> public static ParkOrder MarkSellerChargeOrder(ParkSeller seller, decimal chargeBalance, string operatorId, OrderSource orderSource, OrderPayWay payWay, DbOperator dbOperator) { ParkOrder order = GetSellerChargeOrder(seller, chargeBalance, operatorId, orderSource, payWay); IParkOrder factory = ParkOrderFactory.GetFactory(); return(factory.Add(order, dbOperator)); }
/// <summary> /// 生存中央缴费订单 /// </summary> /// <param name="parkingId">车场编号</param> /// <param name="ioRecordId">记录编号</param> /// <param name="amount">订单金额</param> /// <param name="payAmount">已付金额</param> /// <param name="discountAmount">优惠金额</param> /// <param name="carderateIds">优免券编号</param> /// <param name="feeRuleId">收费规则编号</param> /// <param name="cashTime">结余时间</param> /// <param name="cashMoney">结余金额</param> /// <param name="operatorId">操作员编号</param> /// <returns></returns> public static ParkOrder AddCentralFeeOrder(string parkingId, string ioRecordId, decimal amount, decimal payAmount, decimal discountAmount, List <string> carderateIds, string feeRuleId, DateTime cashTime, decimal cashMoney, string operatorId, DbOperator dbOperator) { ParkOrder order = GenerateCentralFeeOrderModel(parkingId, ioRecordId, amount, payAmount, discountAmount, carderateIds, feeRuleId, cashTime, cashMoney, operatorId); IParkOrder factory = ParkOrderFactory.GetFactory(); return(factory.Add(order, dbOperator)); }
/// <summary> /// 过期转临停订单处理 /// </summary> /// <param name="ioRecordIds"></param> /// <param name="operatorId"></param> /// <param name="dbOperator"></param> /// <returns></returns> public static bool AddExpiredToProStopOrder(List <string> ioRecordIds, string operatorId, DbOperator dbOperator) { if (ioRecordIds.Count == 0) { return(false); } IParkOrder factory = ParkOrderFactory.GetFactory(); List <ParkOrder> orders = factory.QueryByIORecordIds(ioRecordIds); if (orders.Count == 0) { return(true); } bool result = factory.UpdateOrderStatusByIORecordIds(ioRecordIds, -1, dbOperator); if (!result) { return(false); } foreach (var item in orders) { item.OrderNo = IdGenerator.Instance.GetId().ToString(); item.TagID = item.RecordID; item.Status = 1; item.OrderSource = OrderSource.ManageOffice; item.OrderTime = DateTime.Now; item.UserID = operatorId; item.Amount = item.Amount; item.PayAmount = item.PayAmount; item.OldMoney = item.OldMoney; item.NewMoney = item.NewMoney; item.PayWay = OrderPayWay.Cash; item.Remark = "过期转临停关联订单记录:" + item.RecordID; item.PayTime = DateTime.Now; item.CashTime = item.PayTime; item.CashMoney = item.CashMoney; item.PayTime = DateTime.Now; ParkOrder order = factory.Add(item, dbOperator); if (order == null) { return(false); } } return(true); }