Ejemplo n.º 1
0
 public CompanyService(ContextApp context, IMapper mapper, IAuthService authService, IVkService vkService)
 {
     _context     = context;
     _mapper      = mapper;
     _authService = authService;
     _vkService   = vkService;
 }
Ejemplo n.º 2
0
 public SearchController(IYoutubeService youtubeService, IVkService vkService, IUserPostService userPostService)
 {
     _youtubeService  = youtubeService;
     _userPostService = userPostService;
     _vkService       = vkService;
     // Telegram api (TLSharp) does not work in ASP MVC, but it work through WCF Service
     _telegramService = new TelegramServiceClient();
 }
Ejemplo n.º 3
0
 public UserController(IAuthService authService, IUserService userService,
                       UserLoginDTOValidator userLoginDTOValidator, IVkService vkService)
 {
     _authService           = authService;
     _userService           = userService;
     _vkService             = vkService;
     _userLoginDTOValidator = userLoginDTOValidator;
 }
Ejemplo n.º 4
0
 public AccountService(AccountDataUnitOfWork accountDb, ConnectionsHub hub, IVkService vkService,
                       IFbService fbService, ILogger <AccountService> logger, MediaConverter mediaConverter)
 {
     Db             = accountDb;
     Hub            = hub;
     VkService      = vkService;
     FbService      = fbService;
     Logger         = logger;
     MediaConverter = mediaConverter;
 }
Ejemplo n.º 5
0
 public ExternalAuthService(AuthorizationUnitOfWork db, ConnectionsHub hub, IVkService vkService,
                            IFbService fbService, ILogger <ExternalAuthService> logger, MediaConverter mediaConverter)
 {
     Db             = db;
     Hub            = hub;
     VkService      = vkService;
     FbService      = fbService;
     Logger         = logger;
     MediaConverter = mediaConverter;
 }
Ejemplo n.º 6
0
 public VkUserInfoViewComponent(ApplicationContext context,
                                SignInManager <User> signInManager, UserManager <User> userManager,
                                ITelegramService telegramService,
                                IJsonService jsonService,
                                IVkService vkService)
 {
     _signInManager   = signInManager;
     _userManager     = userManager;
     _context         = context;
     _telegramService = telegramService;
     _jsonService     = jsonService;
     _vkService       = vkService;
 }
Ejemplo n.º 7
0
        public VkWallViewViewComponent(ApplicationContext context,
                                       SignInManager <Models.User> signInManager, UserManager <Models.User> userManager,
                                       ITelegramService telegramService,
                                       IJsonService jsonService,
                                       IVkService vkService,
                                       ITextService textService,
                                       IInstagramService instagramService)
        {
            _signInManager = signInManager;
            _userManager   = userManager;
            _context       = context;

            _instagramService = instagramService;
            _telegramService  = telegramService;
            _textService      = textService;
            _jsonService      = jsonService;
            _vkService        = vkService;
        }
Ejemplo n.º 8
0
        public async Task <ActionResult> WallPost(int groupId)
        {
            if (groupId <= 0)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            VkService = new VkService(VkAccessToken)
            {
                PhotoWorker = new VkWallPhotoWorker(VkAccessToken)
            };
            try
            {
                await VkService.PublishPhoto(groupId, FolderPath);

                return(new HttpStatusCodeResult(HttpStatusCode.OK));
            }
            catch
            {
                return(new HttpStatusCodeResult(HttpStatusCode.InternalServerError));
            }
        }
Ejemplo n.º 9
0
        public MainPresenter(IMain view,
                             IInstagramService instagramService,
                             IMainService mainService,
                             IVkService vkService,
                             IMessageService messegeService)
        {
            _view             = view;
            _instagramService = instagramService;
            _mainService      = mainService;
            _vkService        = vkService;
            _messegeService   = messegeService;

            _view.BLoadContentEvent    += _view_BLoadContent;
            _view.BGetTockenEvent      += _view_BGetTocken;
            _view.BGenerateTockenEvent += _view_BGenerateTocken;
            _view.BPostToVKEvent       += _view_BPostToVKEvent;

            _vkService.AppendProgressMaxValue += _vkService_AppendProgressMaxValue;
            _vkService.AppendProgressMessage  += _vkService_AppendProgressMessage;
            _vkService.AppendProgressValue    += _vkService_AppendProgressValue;
        }
Ejemplo n.º 10
0
        public async Task <ActionResult> Index()
        {
            if (String.IsNullOrWhiteSpace(VkAccessToken))
            {
                return(RedirectToAction("Auth"));
            }
            var model = new MainPageViewModel()
            {
                VkUserId = VkAccessToken
            };

            VkService = new VkService(VkAccessToken);
            try
            {
                var groupsResult = await VkService.GetGroups(model.VkUserId);

                model.UserGroups = groupsResult.Groups;
            }
            catch
            {
                model.UserGroups = null;
            }
            return(View(model));
        }
Ejemplo n.º 11
0
 public DiscordController(IWebhook webhook, IVkService vkService)
 {
     _webhook   = webhook;
     _vkService = vkService;
 }
Ejemplo n.º 12
0
 public HomeController(IVkService vkService)
 {
     VkService = vkService;
 }
Ejemplo n.º 13
0
 public SchedulerJobService(IVkService vkClient, ISecurityUserManager userManager)
 {
     _vkClient    = vkClient;
     _userManager = userManager;
 }
Ejemplo n.º 14
0
 public ProductService(ContextApp context, IMapper mapper, IVkService vkService)
 {
     _context   = context;
     _mapper    = mapper;
     _vkService = vkService;
 }
Ejemplo n.º 15
0
 public VkModelBase()
 {
     VkService = ServiceLocator.Current.GetInstance<IVkService>();
 }
Ejemplo n.º 16
0
 public LikeService(VkContext dbContext, IVkService vkService, ILogger logger)
 {
     _dbContext = dbContext;
     _vkService = vkService;
     _logger    = logger;
 }
Ejemplo n.º 17
0
 public StartupService(VkContext dbContext, IVkService vkService, ILikeService likeService)
 {
     _dbContext   = dbContext;
     _vkService   = vkService;
     _likeService = likeService;
 }
Ejemplo n.º 18
0
 public DataService(IVkService vkService, IFlickrService flickrService)
 {
     _vkService     = vkService;
     _flickrService = flickrService;
 }