From 58ef729eb70edded95d6e491b2864e3b88e53db4 Mon Sep 17 00:00:00 2001 From: dao Date: Wed, 31 Jul 2024 09:38:08 +0800 Subject: [PATCH] =?UTF-8?q?=E6=95=99=E5=AE=A4=E4=BD=BF=E7=94=A8=E7=8E=87?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../EducationalAdministration/ClassInfo/ClassInfoService.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassInfo/ClassInfoService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassInfo/ClassInfoService.cs index 2d314eb67..0ff603e67 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassInfo/ClassInfoService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassInfo/ClassInfoService.cs @@ -371,7 +371,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration strSql.Append(@"select b.classroomname,b.classroombuildingname,usecount,usecount as rate from "); //教室使用频率去掉班级查询条件 //strSql.Append(@"(select teachclassno,classroomno,count(1) as usecount from ArrangeLessonTerm t where 1=1 "); - strSql.Append(@"(select classroomno,count(1) as usecount from ArrangeLessonTerm t where 1=1 "); + strSql.Append(@"(select classroomno,count(1) as usecount from ( "); + strSql.Append(@"select classroomno,count(1) as usecount from ArrangeLessonTerm t where CheckMark=1 "); if (!queryParam["StartTime"].IsEmpty()) { strSql.Append(" and t.LessonDate >= '" + queryParam["StartTime"] + "' "); @@ -382,6 +383,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } //教室使用频率去掉班级查询条件 //strSql.Append(@" group by teachclassno,classroomno) a "); + strSql.Append(@" group by classroomno,LessonTime,LessonDate) x "); strSql.Append(@" group by classroomno) a "); strSql.Append(@"left join "); strSql.Append(@"(select r.classroomno,r.classroomname,b.classroombuildingno,b.classroombuildingname from CLASSROOMINFO r ");