Пример #1
0
        private ITemplateMessageSender _templateMessageSender;       //微信模板消息发送服务

        public NotificationJob()
        {
            var container = (ObjectContainer.Current as AutofacObjectContainer).Container;

            _smSender = container.Resolve <ISMSender>();
            _templateMessageSender    = container.Resolve <ITemplateMessageSender>();
            _commandService           = container.Resolve <ICommandService>();
            _notificationQueryService = container.Resolve <INotificationQueryService>();
        }
Пример #2
0
 /// <summary>
 /// IOC 构造函数注入
 /// </summary>
 /// <param name="commandService"></param>
 /// <param name="conferenceQueryService"></param>
 public UserController(ICommandService commandService, ISMSender smSender, IContextService contentService,
                       IUserQueryService userQueryService,
                       IWalletQueryService walletQueryService,
                       ICartQueryService cartQueryService,
                       IStoreQueryService storeQueryService,
                       IStoreOrderQueryService storeOrderQueryService) : base(commandService, contentService)
 {
     _smSender               = smSender;
     _userQueryService       = userQueryService;
     _walletQueryService     = walletQueryService;
     _cartQueryService       = cartQueryService;
     _storeQueryService      = storeQueryService;
     _storeOrderQueryService = storeOrderQueryService;
 }