//晚
        private List <Template_Employment> GetReportStatistiNightData(BaseStudentStasticViewModel baseStudentStasticViewModel)
        {
            List <Template_Employment> template_Students = new List <Template_Employment>();

            var searchresultGao = DbSet.Where(a => a.SchoolCode == baseStudentStasticViewModel.SchoolCode &&
                                              a.CreateDate.Value.ToString("yyyy-MM-dd") == baseStudentStasticViewModel.createdate.Value.ToString("yyyy-MM-dd") &&
                                              a.type == "晚"
                                              )
                                  .GroupBy(m => new { m.SchoolCode, m.type, m.SchoolName })
                                  .Select(a => new Template_Employment
            {
                SchoolName                = a.Key.SchoolName,
                SchoolCode                = a.Key.SchoolCode,
                type                      = a.Key.type,
                ShouldComeSchoolCount     = a.Sum(w => w.ShouldComeSchoolCount),
                ActualComeSchoolCount     = a.Sum(w => w.ActualComeSchoolCount),
                ComeSchoolHotCount        = a.Sum(w => w.ComeSchoolHotCount),
                NotComeSchoolCount        = a.Sum(w => w.NotComeSchoolCount),
                NotComeSchoolByHotCount   = a.Sum(w => w.NotComeSchoolByHotCount),
                NotComeSchoolByOutCount   = a.Sum(w => w.NotComeSchoolByOutCount),
                NotComeSchoolByOtherCount = a.Sum(w => w.NotComeSchoolByOtherCount)
            }
                                          );

            template_Students.AddRange(searchresultGao);

            //早
            return(template_Students);
        }
        public ActionResult <EmployBaseResModel> getEmployBaseTemplate(BaseStudentStasticViewModel baseStudentStasticViewModel)
        {
            EmployBaseResModel employBaseResModel = new EmployBaseResModel();

            employBaseResModel.employComtemlateMiddles = istatisticsService.getBaseComtemplateInfoEmploy(baseStudentStasticViewModel);
            employBaseResModel.IsSuccess                  = true;
            employBaseResModel.baseViewModel.Message      = "查询成功";
            employBaseResModel.baseViewModel.ResponseCode = 200;
            return(Ok(employBaseResModel));
        }
        public ActionResult <StudentBaseResModel> getStudentBaseTemplate(BaseStudentStasticViewModel baseStudentStasticViewModel)
        {
            StudentBaseResModel studentBaseResModel = new StudentBaseResModel();

            studentBaseResModel.studentComtemlateMiddles = istatisticsService.getBaseComtemplateInfo(baseStudentStasticViewModel);
            studentBaseResModel.IsSuccess                  = true;
            studentBaseResModel.baseViewModel.Message      = "查询成功";
            studentBaseResModel.baseViewModel.ResponseCode = 200;
            return(Ok(studentBaseResModel));
        }
        public List <Template_Employment> GetCompTemplateEmploy(BaseStudentStasticViewModel baseStudentStasticViewModel)
        {
            List <Template_Employment> template_Students = new List <Template_Employment>();

            template_Students.AddRange(GetReportStatisticData(baseStudentStasticViewModel));        //到校前初中高中小学
            template_Students.AddRange(GetReportStatisticMorningData(baseStudentStasticViewModel)); //早初中高中小学
            template_Students.AddRange(GetReportStatistiNoonData(baseStudentStasticViewModel));     //午初中高中小学
            template_Students.AddRange(GetReportStatistiNightData(baseStudentStasticViewModel));    //晚高中小学
            return(template_Students);
        }
        public List <EmployComtemlateMiddle> getBaseComtemplateInfoEmploy(BaseStudentStasticViewModel baseStudentStasticViewModel)
        {
            var SearchResult = employComtemplateRepository.GetCompTemplateEmploy(baseStudentStasticViewModel);

            return(_IMapper.Map <List <Template_Employment>, List <EmployComtemlateMiddle> >(SearchResult));
        }