Example #1
0
        public ITextFileResultModel GetSpentTimeVsTenantTasksCsv(IGroupedTasksCsvRequest <string> tasksInfoRequest)
        {
            var result = GetGroupedTasksCsv(tasksInfoRequest,
                                            Constants.ChartName.SpentTimeVsTenantTasks, new TenantTaskSpentTimeChartCsvProfile(translationService), false, true);

            return(result);
        }
Example #2
0
        public ITextFileResultModel GetUnprocessedVsProcessedDataCsv(IGroupedTasksCsvRequest <string> tasksInfoRequest)
        {
            var result = GetGroupedTasksCsv(tasksInfoRequest,
                                            Constants.ChartName.UnprocessedVsProcessed, new UnprocessedVsProcessedChartCsvProfile(translationService), true);

            return(result);
        }
Example #3
0
        public ITextFileResultModel GetFacilityTasksVsTenantTasksCsv(IGroupedTasksCsvRequest <JobTypeEnum> csvChartRequest)
        {
            var result = GetGroupedTasksCsv(csvChartRequest,
                                            Constants.ChartName.FacilityTasksVsTenantTasks, new SeparationBetweenFacilityTasksVsTenantTasksChartCsvProfile(translationService), true, true);

            return(result);
        }
Example #4
0
        public ITextFileResultModel GetCompletedVsOverdueTasksCsv(IGroupedTasksCsvRequest <string> csvChartRequest)
        {
            var result = GetGroupedTasksCsv(csvChartRequest,
                                            Constants.ChartName.CompletedVsOverdueTasks, new CompletedToOverdueTaskChartCsvProfile(translationService), false);

            return(result);
        }
Example #5
0
        public ITextFileResultModel GetSpentTimeVsFacilityTasksCsv(IGroupedTasksCsvRequest <string> csvChartRequest)
        {
            var result = GetGroupedTasksCsv(csvChartRequest,
                                            Constants.ChartName.SpentTimeVsFacilityTasks, new SeparationBetweenSpentTimeVsFacilityTasksChartCsvProfile(translationService), true, true);

            return(result);
        }
Example #6
0
        public ITextFileResultModel GetGroupedTasksCsv <T>(
            IGroupedTasksCsvRequest <T> csvChartRequest, string chartName, CsvClassMap <TaskInfo> csvProfile, bool showLastCompletedOrCanceledStatus, bool onlyWithTime = false)
        {
            IEnumerable <IDayAssign> dayAssigns   = dayAssignService.GetByIds(csvChartRequest.GroupedTasksIds.SelectMany(g => g.Value));
            IEnumerable <TaskInfo>   taskInfoList = tasksInfoBuilder.GetTaskInfoList(dayAssigns, showLastCompletedOrCanceledStatus, onlyWithTime);
            string fileName = GetChartCsvFileName(chartName, csvChartRequest.RangeDateString);
            var    result   = GetCsvTextFileResult(taskInfoList, csvProfile, fileName);

            return(result);
        }