案例,bug

This commit is contained in:
yang
2024-10-09 18:52:23 +08:00
parent 39e336d044
commit 25d8594a2b

View File

@@ -44,6 +44,7 @@ import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import java.lang.reflect.Array;
import java.time.LocalDateTime;
import java.time.YearMonth;
import java.time.format.DateTimeFormatter;
import java.time.temporal.TemporalAdjusters;
import java.util.*;
@@ -1203,15 +1204,15 @@ public class CasesServiceImpl implements ICasesService {
}
//获取案例当月排名
// String sql =
// "SELECT bc.id,bcmt.major_id,bc.views - COALESCE(bc.last_month_views, 0) AS increment\n" +
// "FROM boe_cases bc\n" +
// "JOIN boe_cases_major_type bcmt ON bcmt.case_id = bc.id and bc.deleted=0 and file_path is not null and file_path!='' and bc.views - COALESCE(bc.last_month_views, 0)!=0";
String sql =
"SELECT bc.id,bcmt.major_id,bc.views AS increment\n" +
"FROM boe_cases bc\n" +
"JOIN boe_cases_major_type bcmt ON bcmt.case_id = bc.id and bc.deleted=0 and file_path is not null and file_path!='' and bc.views !=0 and bc.views is not null";
"SELECT bc.id,bcmt.major_id,bc.views - COALESCE(bc.last_month_views, 0) AS increment\n" +
"FROM boe_cases bc\n" +
"JOIN boe_cases_major_type bcmt ON bcmt.case_id = bc.id and bc.deleted=0 and file_path is not null and file_path!='' and bc.views - COALESCE(bc.last_month_views, 0)!=0";
// String sql =
// "SELECT bc.id,bcmt.major_id,bc.views AS increment\n" +
// "FROM boe_cases bc\n" +
// "JOIN boe_cases_major_type bcmt ON bcmt.case_id = bc.id and bc.deleted=0 and file_path is not null and file_path!='' and bc.views !=0 and bc.views is not null";
List<Object> caseListOfObject = casesDao.sqlFindList(sql);