Esempio n. 1
0
 public static IAdvanceParking GetFactory()
 {
     if (factory == null)
     {
         Type type = Type.GetType("Common." + SystemDefaultConfig.DatabaseProvider + "Repository.WeiXin.AdvanceParkingDAL,Common." + SystemDefaultConfig.DatabaseProvider + "Repository", true);
         factory = (IAdvanceParking)Activator.CreateInstance(type);
     }
     return(factory);
 }
Esempio n. 2
0
        public static bool Add(AdvanceParking model)
        {
            if (model == null)
            {
                throw new ArgumentNullException("model");
            }
            IAdvanceParking factory = AdvanceParkingFactory.GetFactory();

            return(factory.Add(model));
        }
Esempio n. 3
0
        public static bool PaySuccess(decimal orderId, string serialNumber, DateTime payTime)
        {
            IAdvanceParking factory = AdvanceParkingFactory.GetFactory();
            AdvanceParking  model   = factory.QueryByOrderId(orderId);

            if (model.OrderState != 0)
            {
                throw new MyException("支付状态不正确");
            }

            return(factory.PaySuccess(orderId, serialNumber, payTime));
        }
Esempio n. 4
0
        public static List <AdvanceParking> QueryPage(string companyId, string plateNo, DateTime?start, DateTime?end, int pageIndex, int pageSize, out int recordTotalCount)
        {
            IAdvanceParking factory = AdvanceParkingFactory.GetFactory();

            return(factory.QueryPage(companyId, plateNo, start, end, pageIndex, pageSize, out recordTotalCount));
        }
Esempio n. 5
0
        public static bool UpdatePrepayIdById(string prepayId, decimal orderId)
        {
            IAdvanceParking factory = AdvanceParkingFactory.GetFactory();

            return(factory.UpdatePrepayIdById(prepayId, orderId));
        }
Esempio n. 6
0
        public static AdvanceParking QueryByOrderId(decimal orderId)
        {
            IAdvanceParking factory = AdvanceParkingFactory.GetFactory();

            return(factory.QueryByOrderId(orderId));
        }