Ejemplo n.º 1
0
        public DashboardAppServiceTest()
        {
            RegisterInstance(dashboardProvider.Object);
            dashboardAppService = Resolve <IDashboardAppService>();

            dashboardProvider
            .Setup(e => e.GetDashboardAsync(It.IsAny <string>(), It.IsAny <string>()))
            .Returns(System.Threading.Tasks.Task.FromResult(new Microsoft.PowerBI.Api.V2.Models.Dashboard()
            {
                DisplayName = string.Empty, EmbedUrl = string.Empty
            }));

            // Arrange
            UsingDbContext(context =>
            {
                // var data = A.ListOf<ProjectDetail>(5);
                List <CROPS.Reports.Dashboard> data = new List <CROPS.Reports.Dashboard>
                {
                    new CROPS.Reports.Dashboard {
                        Id = "0a0c9cbe-b819-4e7c-9172-8b2b0f176f99", DashboardId = "0a0c9cbe-b819-4e7c-9172-8b2b0f176f99", WorkspaceId = "010fd0a9-c71f-4799-be61-308cf64ef731", IsActive = true, Name = "Dashboard 1"
                    },
                    new CROPS.Reports.Dashboard {
                        Id = Guid.NewGuid().ToString(), IsActive = true, Name = "Dashboard 0"
                    },
                    new CROPS.Reports.Dashboard {
                        Id = Guid.NewGuid().ToString(), IsActive = true, Name = "Dashboard 2"
                    },
                    new CROPS.Reports.Dashboard {
                        Id = Guid.NewGuid().ToString(), IsActive = true, Name = "Dashboard 3"
                    },
                    new CROPS.Reports.Dashboard {
                        Id = Guid.NewGuid().ToString(), IsActive = true, Name = "Dashboard 4"
                    }
                };
                context.Dashboard.AddRange(data);
            });
        }
Ejemplo n.º 2
0
 public DashboardController(IDashboardAppService dashboardAppService, IDespesaAppService despesaAppService)
     : base()
 {
     this._dashboardAppService = dashboardAppService;
     this._despesaAppService   = despesaAppService;
 }
 public DashboardController(IDashboardAppService reportAppService, ICommonConfiguration commonConfiguration) : base(commonConfiguration)
 {
     _dashboardAppService = reportAppService;
 }
Ejemplo n.º 4
0
 public DashboardController(IDashboardAppService dashboardAppService)
 {
     _dashboardAppService = dashboardAppService;
 }
 public DashboardController(INotificationHandler <DomainNotification> notification,
                            IDashboardAppService dashboardAppService)
     : base(notification)
 {
     _dashboardService = dashboardAppService;
 }
Ejemplo n.º 6
0
 public HomeController(IDashboardAppService dashboardappservice)
 {
     _svcDashboard = dashboardappservice;
    
 }
Ejemplo n.º 7
0
 public CountersWidgetViewComponent(IDashboardAppService dashboardAppService)
 {
     _dashboardAppService = dashboardAppService;
 }
Ejemplo n.º 8
0
 public DashboardController(IDashboardAppService dashboardService, IMapper mapper, IOptionsSnapshot <RootConfigurations> rootConfiguration) : base(rootConfiguration)
 {
     _dashboardService = dashboardService;
     _mapper           = mapper;
 }