예제 #1
0
        public DashboardHistoryModule(IDashboardDataService dashboardDataService)
        {
            this._dashboardDataService     = dashboardDataService;
            Post["/api/dashboardActivity"] = _ =>
            {
                var x = this.Request.Body.AsString();
                var dashboardExecution = JsonConvert.DeserializeObject <DashboardExecution>(x);
                var scriptQuery        = this.Bind <ScriptQuery>();


                if (dashboardExecution == null)
                {
                    return(HttpStatusCode.BadRequest);
                }
                dashboardExecution.ExecutionTime = DateTime.UtcNow;
                _dashboardDataService.GetInsertDetails(dashboardExecution);
                return(HttpStatusCode.OK);
            };

            Get["/api/dashboardActivity"] = p =>
            {
                var getData = _dashboardDataService.GetDashboardDetails();
                return(Negotiate
                       .WithContentType("aplication/json")
                       .WithModel(getData));
            };
        }
 public DashboardController(IDashboardDataService dashboardDataService,
                            IUserService userService,
                            ISubscriptionExpireNotification notificationNotification)
 {
     _service     = dashboardDataService;
     _userService = userService;
     _notificationNotification = notificationNotification;
 }
예제 #3
0
        public DashboardApiController(IDashboardDataService dashboardDataService)
        {
            if (dashboardDataService == null)
            {
                throw new ArgumentNullException(nameof(dashboardDataService));
            }

            _dashboardDataService = dashboardDataService;
        }
예제 #4
0
 public StatsController(IDashboardDataService dataService)
 {
     _service = dataService;
 }
 public DashboardActivityEndpoint(IDashboardDataService dashboardDataService)
 {
     GetDashboardActivities();
 }
예제 #6
0
 public DashboardService(IDashboardDataService dashboardDataService, ILocalizationService localizationService)
 {
     _dashboardDataService = dashboardDataService;
     _localizationService  = localizationService;
 }
예제 #7
0
 public Dashboard(IDashboardDataService dashboardDataService, IMasterScheduleDataService masterScheduleDataService, ILogger <DashboardViewModel> logger)
 {
     _dashboardDataService      = dashboardDataService;
     _masterScheduleDataService = masterScheduleDataService;
     _logger = logger;
 }