Example #1
0
 /// <summary>
 /// 构造函数
 /// </summary>
 /// <param name="db"></param>
 public DictService(CHISEntitiesSqlServer db
                    , IMemoryCache memoryCache) : base(db)
 {
     _memoryCache = memoryCache;
     dictLib      = InitalDictLib();
     areaLib      = InitalAreaLib();
 }
Example #2
0
 public ChangePayService(CHISEntitiesSqlServer db,
                         DispensingService dispensingSvr,
                         IHostingEnvironment env
                         , CustomerService cusSvr
                         , PointsDetailService pointsService
                         , TreatService treatSvr
                         , AccessService accSvr
                         , DispensingService dispSvr
                         , Codes.Utility.XPay.AliPay aliPay
                         , WeChatService weChatSvr
                         , Code.Managers.IMyLogger logger
                         , IHttpContextAccessor httpContextAccessor
                         ) : base(db)
 {
     _dispensingSvr       = dispensingSvr;
     _env                 = env;
     _cusSvr              = cusSvr;
     _pointsService       = pointsService;
     _treatSvr            = treatSvr;
     _accSvr              = accSvr;
     this._logger         = logger;
     _aliPay              = aliPay;
     _weChatSvr           = weChatSvr;
     _httpContextAccessor = httpContextAccessor;
 }
Example #3
0
 public DispensingService(CHISEntitiesSqlServer db
                          , Services.JKWebNetService jkSvr
                          , IHostingEnvironment env
                          ) : base(db)
 {
     _env   = env;
     _jkSvr = jkSvr;
 }
Example #4
0
 /// <summary>
 /// 构造函数
 /// </summary>
 /// <param name="db"></param>
 public LoginService(CHISEntitiesSqlServer db
                     , CustomerService cusSvr
                     , DoctorService docSvr
                     , WorkStationService staSvr
                     ) : base(db)
 {
     _cusSvr = cusSvr; _docSvr = docSvr; _staSvr = staSvr;
 }
Example #5
0
 public GiftController(GiftService giftService,
                       GiftOrderService giftOrderService,
                       PointsDetailService pointsService,
                       ILogger <GiftController> logger,
                       CHISEntitiesSqlServer db) : base(db)
 {
     _giftService      = giftService;
     _giftOrderService = giftOrderService;
     _pointsService    = pointsService;
     _logger           = logger;
 }
Example #6
0
 /// <summary>
 /// 构造函数
 /// </summary>
 /// <param name="db"></param>
 /// <param name="config"></param>
 /// <param name="logger"></param>
 public NotifyService(CHISEntitiesSqlServer db
                      , IConfiguration config
                      , Services.DrugService drugSvr
                      , Code.Managers.IMyLogger logger
                      , AccessService accSvr
                      ) : base(db)
 {
     _drugSvr = drugSvr;
     _config  = config;
     _logger  = logger;
     _accSvr  = accSvr;
 }
Example #7
0
 public DoctorService(CHISEntitiesSqlServer db
                      , Services.AccessService accSvr) : base(db)
 {
     _accSvr = accSvr;
 }
Example #8
0
 public BaseService(CHISEntitiesSqlServer db)
 {
     this._db = db;
 }
Example #9
0
 public WorkStationService(CHISEntitiesSqlServer db, IHostingEnvironment env
                           , DoctorService docSvr) : base(db)
 {
     this._env = env;
 }
Example #10
0
 public GiftOrderService(CHISEntitiesSqlServer db, IMapper mapper, WeChatService weChatService) : base(db)
 {
     _mapper        = mapper;
     _weChatService = weChatService;
 }
Example #11
0
 public FollowListService(CHISEntitiesSqlServer db) : base(db)
 {
 }
Example #12
0
 public PharmacyService(CHISEntitiesSqlServer db, IMyLogger logger) : base(db)
 {
     _logger = logger;
 }
Example #13
0
 /// <summary>
 /// 构造函数
 /// </summary>
 /// <param name="db"></param>
 public PrescriptionService(CHISEntitiesSqlServer db) : base(db)
 {
 }
Example #14
0
 public RxDrugSaveController(CHISEntitiesSqlServer db, CustomerService cusSvr, RxService rxSvr) : base(db)
 {
     _cusSvr = cusSvr;
     _rxSvr  = rxSvr;
 }
Example #15
0
 public PointsDetailService(CHISEntitiesSqlServer db, IMapper mapper) : base(db)
 {
     _mapper = mapper;
 }
Example #16
0
 public GiftService(CHISEntitiesSqlServer db, IMapper mapper) : base(db)
 {
     _mapper = mapper;
 }
Example #17
0
 public ReservationService(CHISEntitiesSqlServer db
                           , NotifyService notifySvr
                           ) : base(db)
 {
     this._notifySvr = notifySvr;
 }
Example #18
0
        /// <summary>
        /// 更新预支付数据
        /// </summary>
        /// <param name="payOrderId"></param>
        /// <param name="payStatus"></param>
        /// <param name="payTime"></param>
        /// <returns></returns>
        private async Task <CHIS_Charge_PayPre> UpdatePayPreAsync(string payOrderId, string feeTypeCode, string payRmk = null, bool isCash = false, int payStatus = 1, DateTime?payTime = null, CHISEntitiesSqlServer db = null)
        {
            db = db ?? _db;
            if (payOrderId.IsEmpty())
            {
                throw new Exception("更新付款信息没有传入付款单号。");
            }
            if (!FeeTypes.IsValidFeeType(feeTypeCode))
            {
                throw new Exception("传入费用类型错误");
            }
            var finds = db.CHIS_Charge_PayPre.AsNoTracking().Where(u => u.PayOrderId == payOrderId);
            var count = finds.Count();

            if (count == 0)
            {
                throw new Exception("没有找到预付款信息数据");
            }
            if (count > 1)
            {
                throw new Exception("发现多个数据");
            }
            if (payTime == null)
            {
                payTime = DateTime.Now;
            }
            var m = finds.FirstOrDefault();

            if (m == null)
            {
                throw new Exception($"没有找到单号({payOrderId})的预付款信息。");
            }
            if (isCash)
            {
                if (!m.IsAllowedCashPay)
                {
                    throw new Exception("该订单不允许现金支付!");
                }
            }
            m.FeeTypeCode      = feeTypeCode;
            m.PayStatus        = payStatus;
            m.PayedSuccessTime = payTime;
            m.PayRemark        = m.PayRemark + payRmk;
            db.Update(m);
            await db.SaveChangesAsync();

            return(m);
        }
Example #19
0
 public CustomerService(CHISEntitiesSqlServer db
                        , PointsDetailService pointsService) : base(db)
 {
     _pointsService = pointsService;
 }
Example #20
0
 public DrugService(CHISEntitiesSqlServer db) : base(db)
 {
 }
Example #21
0
        public GiftController(GiftOrderService orderService, GiftService giftService, WeChatService weChatService, CHISEntitiesSqlServer db) : base(db)
        {
            _giftService = giftService;

            _orderService = orderService;

            _weChatService = weChatService;
        }