/// <summary> /// Initializes a new instance of the <see cref="ManagerDashboardHelper"/> class. /// </summary> /// <param name="context">The timesheet context.</param> /// <param name="repositoryAccessors">The instance of repository accessors.</param> /// <param name="userGraphService">The instance of user Graph service to access logged-in user's reportees and manager.</param> /// <param name="managerDashboardMapper">The instance of manager dashboard mapper.</param> public ManagerDashboardHelper(TimesheetContext context, IRepositoryAccessors repositoryAccessors, IUsersService userGraphService, IManagerDashboardMapper managerDashboardMapper) { this.context = context; this.repositoryAccessors = repositoryAccessors; this.userGraphService = userGraphService; this.managerDashboardMapper = managerDashboardMapper; }
/// <summary> /// Initializes a new instance of the <see cref="SendReminderFunction"/> class. /// </summary> /// <param name="messageService">Instance of message service for sending notifications.</param> /// <param name="repositoryAccessors">Instance of repository accessor for fetching information from database.</param> /// <param name="options">Send reminder function options.</param> /// <param name="localizer">Instance of localizer.</param> public SendReminderFunction(IMessageService messageService, IRepositoryAccessors repositoryAccessors, IOptions <FunctionOptions> options, IStringLocalizer <Strings> localizer) { this.messageService = messageService; this.repositoryAccessors = repositoryAccessors; this.manifestId = options?.Value?.ManifestId; this.appBaseUrl = options?.Value?.AppBaseUri; this.localizer = localizer; }
/// <summary> /// Initializes a new instance of the <see cref="MustBeProjectMemberPolicyHandler"/> class. /// </summary> /// <param name="memoryCache">Memory cache instance for caching authorization result.</param> /// <param name="repositoryAccessors">The instance of repository accessors.</param> /// <param name="botOptions">A set of key/value application configuration properties for activity handler.</param> public MustBeProjectMemberPolicyHandler( IMemoryCache memoryCache, IRepositoryAccessors repositoryAccessors, IOptions <BotSettings> botOptions) { this.memoryCache = memoryCache; this.repositoryAccessors = repositoryAccessors; this.botOptions = botOptions; }
/// <summary> /// Initializes a new instance of the <see cref="AppLifecycleHandler"/> class. /// </summary> /// <param name="logger">The logger.</param> /// <param name="adaptiveCardService">Instance of adaptive card service to create and get adaptive cards.</param> /// <param name="repositoryAccessors">The instance of repository accessors.</param> public AppLifecycleHandler( ILogger <AppLifecycleHandler> logger, IAdaptiveCardService adaptiveCardService, IRepositoryAccessors repositoryAccessors) { this.logger = logger; this.adaptiveCardService = adaptiveCardService; this.repositoryAccessors = repositoryAccessors; }
/// <summary> /// Initializes a new instance of the <see cref="TimesheetHelper"/> class. /// </summary> /// <param name="botOptions">A set of key/value application configuration properties.</param> /// <param name="repositoryAccessors">The instance of repository accessors.</param> /// <param name="timesheetMapper">The instance of timesheet mapper.</param> /// <param name="logger">The ILogger object which logs errors and information.</param> public TimesheetHelper( IOptions <BotSettings> botOptions, IRepositoryAccessors repositoryAccessors, ITimesheetMapper timesheetMapper, ILogger <TimesheetHelper> logger) { this.repositoryAccessors = repositoryAccessors; this.timesheetMapper = timesheetMapper; this.logger = logger; this.botOptions = botOptions; }
/// <summary> /// Initializes a new instance of the <see cref="MustBeProjectCreatorPolicyHandler"/> class. /// </summary> /// <param name="memoryCache">Memory cache instance for caching authorization result.</param> /// <param name="repositoryAccessor">Instance of repository accessors for fetching valid projects.</param> /// <param name="botOptions">A set of key/value application configuration properties for caching settings.</param> /// <param name="httpContextAccessor">The instance of HTTP context accessors.</param> public MustBeProjectCreatorPolicyHandler( IMemoryCache memoryCache, IRepositoryAccessors repositoryAccessor, IOptions <BotSettings> botOptions, IHttpContextAccessor httpContextAccessor) { this.memoryCache = memoryCache; this.repositoryAccessor = repositoryAccessor; this.botOptions = botOptions; this.httpContextAccessor = httpContextAccessor; }
/// <summary> /// Initializes a new instance of the <see cref="ProjectHelper"/> class. /// </summary> /// <param name="context">The timesheet database context.</param> /// <param name="repositoryAccessors">The instance of repository accessors.</param> /// <param name="projectMapper">The instance of project model mapper.</param> /// <param name="memberMapper">Instance of member mapper.</param> /// <param name="taskMapper">Instance of task mapper.</param> public ProjectHelper( TimesheetContext context, IRepositoryAccessors repositoryAccessors, IProjectMapper projectMapper, IMemberMapper memberMapper, ITaskMapper taskMapper) { this.context = context; this.repositoryAccessors = repositoryAccessors; this.projectMapper = projectMapper; this.memberMapper = memberMapper; this.taskMapper = taskMapper; }
/// <summary> /// Initializes a new instance of the <see cref="TimesheetController"/> class. /// </summary> /// <param name="logger">The ILogger object which logs errors and information.</param> /// <param name="telemetryClient">The Application Insights telemetry client.</param> /// <param name="timesheetHelper">The instance of timesheet helper.</param> /// <param name="managerDashboardHelper">The instance of manager dashboard helper.</param> /// <param name="repositoryAccessors">Holds the instance of respository accessors for database operations.</param> public TimesheetController( ILogger <TimesheetController> logger, TelemetryClient telemetryClient, ITimesheetHelper timesheetHelper, IManagerDashboardHelper managerDashboardHelper, IRepositoryAccessors repositoryAccessors) : base(telemetryClient) { this.logger = logger; this.timesheetHelper = timesheetHelper; this.managerDashboardHelper = managerDashboardHelper; this.repositoryAccessors = repositoryAccessors; }
/// <summary> /// Initializes a new instance of the <see cref="TimesheetHelper"/> class. /// </summary> /// <param name="botOptions">A set of key/value application configuration properties.</param> /// <param name="repositoryAccessors">The instance of repository accessors.</param> /// <param name="timesheetMapper">The instance of timesheet mapper.</param> /// <param name="logger">The ILogger object which logs errors and information.</param> /// <param name="notificationHelper">Notification helper instance to send notifications to user.</param> /// <param name="adaptiveCardService">Instance of adaptive card service to construct notification cards.</param> public TimesheetHelper( IOptions <BotSettings> botOptions, IRepositoryAccessors repositoryAccessors, ITimesheetMapper timesheetMapper, ILogger <TimesheetHelper> logger, INotificationHelper notificationHelper, IAdaptiveCardService adaptiveCardService) { this.repositoryAccessors = repositoryAccessors; this.timesheetMapper = timesheetMapper; this.logger = logger; this.botOptions = botOptions; this.notificationHelper = notificationHelper; this.adaptiveCardService = adaptiveCardService; }
/// <summary> /// Initializes a new instance of the <see cref="ProjectController"/> class. /// </summary> /// <param name="logger">The ILogger object which logs errors and information.</param> /// <param name="projectHelper">The instance of project helper which helps in managing operations on project entity.</param> /// <param name="userHelper">Instance of user helper.</param> /// <param name="telemetryClient">The Application Insights telemetry client.</param> /// <param name="taskMapper">The instance of task mapper.</param> /// <param name="taskHelper">The instance of task helper.</param> /// <param name="managerDashboardHelper">Holds the instance of manager dashboard helper.</param> /// <param name="repositoryAccessors">Holds the instance of respository accessors for database operations.</param> public ProjectController( ILogger <ProjectController> logger, IProjectHelper projectHelper, IUserHelper userHelper, IManagerDashboardHelper managerDashboardHelper, TelemetryClient telemetryClient, ITaskMapper taskMapper, ITaskHelper taskHelper, IRepositoryAccessors repositoryAccessors) : base(telemetryClient) { this.projectHelper = projectHelper; this.userHelper = userHelper; this.managerDashboardHelper = managerDashboardHelper; this.logger = logger; this.taskMapper = taskMapper; this.taskHelper = taskHelper; this.repositoryAccessors = repositoryAccessors; }
/// <summary> /// Initializes a new instance of the <see cref="ManagerDashboardHelper"/> class. /// </summary> /// <param name="repositoryAccessors">The instance of repository accessors.</param> /// <param name="userGraphService">The instance of user Graph service to access logged-in user's reportees and manager.</param> /// <param name="managerDashboardMapper">The instance of manager dashboard mapper.</param> public ManagerDashboardHelper(IRepositoryAccessors repositoryAccessors, IUsersService userGraphService, IManagerDashboardMapper managerDashboardMapper) { this.repositoryAccessors = repositoryAccessors; this.userGraphService = userGraphService; this.managerDashboardMapper = managerDashboardMapper; }
/// <summary> /// Initializes a new instance of the <see cref="TaskHelper"/> class. /// </summary> /// <param name="repositoryAccessor">The instance of repository accessors to access repositories.</param> /// <param name="logger">Logs errors and information.</param> public TaskHelper(IRepositoryAccessors repositoryAccessor, ILogger <TaskHelper> logger) { this.repositoryAccessor = repositoryAccessor; this.logger = logger; }