1
This commit is contained in:
parent
c02b4143b8
commit
d0b3090ce5
@ -85,7 +85,7 @@ public interface DlDriveSchoolStudentMapper extends BaseMapper<DlDriveSchoolStud
|
|||||||
* @param endTime 截止时间
|
* @param endTime 截止时间
|
||||||
* @return java.util.List<cn.iocoder.yudao.module.base.vo.DlDriveSchoolStudentVO>
|
* @return java.util.List<cn.iocoder.yudao.module.base.vo.DlDriveSchoolStudentVO>
|
||||||
**/
|
**/
|
||||||
IPage<DlDriveSchoolStudentVO> selectTrainStudent(@Param("coachId")Long coachId, @Param("startTime") String startTime, @Param("endTime")String endTime, Page<DlDriveSchoolStudent> page);
|
IPage<DlDriveSchoolStudentVO> selectTrainStudent(@Param("coachId")Long coachId, @Param("startTime") String startTime, @Param("endTime")String endTime,@Param("searchValue")String searchValue, Page<DlDriveSchoolStudent> page);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
@ -54,5 +54,5 @@ public interface DriveSchoolCarMapper extends BaseMapper<DriveSchoolCar>
|
|||||||
* @param endTime 截止时间
|
* @param endTime 截止时间
|
||||||
* @return java.util.List<cn.iocoder.yudao.module.base.vo.DriveSchoolCar>
|
* @return java.util.List<cn.iocoder.yudao.module.base.vo.DriveSchoolCar>
|
||||||
**/
|
**/
|
||||||
IPage<DriveSchoolCar> selectTrainCar(@Param("coachId")Long coachId, @Param("startTime") String startTime, @Param("endTime")String endTime, Page<DriveSchoolCar> page);
|
IPage<DriveSchoolCar> selectTrainCar(@Param("coachId")Long coachId, @Param("startTime") String startTime, @Param("endTime")String endTime,@Param("searchValue")String searchValue, Page<DriveSchoolCar> page);
|
||||||
}
|
}
|
||||||
|
@ -94,6 +94,7 @@ public class TrainController {
|
|||||||
public CommonResult<IPage<?>> indexGetTrainList(@RequestParam(value = "type") String type,
|
public CommonResult<IPage<?>> indexGetTrainList(@RequestParam(value = "type") String type,
|
||||||
@RequestParam(value = "timeType") String timeType,
|
@RequestParam(value = "timeType") String timeType,
|
||||||
@RequestParam(value = "coachId",required = false) Long coachId,
|
@RequestParam(value = "coachId",required = false) Long coachId,
|
||||||
|
@RequestParam(value = "searchValue",required = false) String searchValue,
|
||||||
@RequestParam(value = "startTime",required = false) String startTime,
|
@RequestParam(value = "startTime",required = false) String startTime,
|
||||||
@RequestParam(value = "endTime",required = false) String endTime,
|
@RequestParam(value = "endTime",required = false) String endTime,
|
||||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
@ -119,7 +120,7 @@ public class TrainController {
|
|||||||
}
|
}
|
||||||
if("student".equals(type)){
|
if("student".equals(type)){
|
||||||
Page<DlDriveSchoolStudent> page = new Page<>(pageNo,pageSize);
|
Page<DlDriveSchoolStudent> page = new Page<>(pageNo,pageSize);
|
||||||
IPage<DlDriveSchoolStudentVO> studentPage = studentMapper.selectTrainStudent(coachId,startTimeStr,endTimeStr,page);
|
IPage<DlDriveSchoolStudentVO> studentPage = studentMapper.selectTrainStudent(coachId,startTimeStr,endTimeStr,searchValue,page);
|
||||||
studentPage.getRecords().forEach(item->{
|
studentPage.getRecords().forEach(item->{
|
||||||
//查每个学生的当前所处的科目
|
//查每个学生的当前所处的科目
|
||||||
item.setProcess(processService.selectByUserId(item.getUserId(),item.getCoachId()));
|
item.setProcess(processService.selectByUserId(item.getUserId(),item.getCoachId()));
|
||||||
@ -128,7 +129,7 @@ public class TrainController {
|
|||||||
}else{
|
}else{
|
||||||
//训练车辆
|
//训练车辆
|
||||||
Page<DriveSchoolCar> page = new Page<>(pageNo,pageSize);
|
Page<DriveSchoolCar> page = new Page<>(pageNo,pageSize);
|
||||||
return success(carMapper.selectTrainCar(coachId,startTimeStr,endTimeStr,page));
|
return success(carMapper.selectTrainCar(coachId,startTimeStr,endTimeStr,searchValue,page));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -135,6 +135,9 @@
|
|||||||
<if test="coachId != null and coachId != ''">
|
<if test="coachId != null and coachId != ''">
|
||||||
AND dst.coach_id = #{coachId}
|
AND dst.coach_id = #{coachId}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="searchValue != null and searchValue != ''">
|
||||||
|
AND dss.name LIKE CONCAT('%',#{searchValue},'%')
|
||||||
|
</if>
|
||||||
<if test="startTime!=null and startTime!=''">
|
<if test="startTime!=null and startTime!=''">
|
||||||
AND dst.create_time >= #{startTime}
|
AND dst.create_time >= #{startTime}
|
||||||
</if>
|
</if>
|
||||||
|
@ -43,6 +43,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="entity.brand != null and entity.brand != ''"> and brand = #{entity.brand}</if>
|
<if test="entity.brand != null and entity.brand != ''"> and brand = #{entity.brand}</if>
|
||||||
<if test="entity.carModel != null and entity.carModel != ''"> and car_model = #{entity.carModel}</if>
|
<if test="entity.carModel != null and entity.carModel != ''"> and car_model = #{entity.carModel}</if>
|
||||||
<if test="entity.carNo != null and entity.carNo != ''"> and car_no = #{entity.carNo}</if>
|
<if test="entity.carNo != null and entity.carNo != ''"> and car_no = #{entity.carNo}</if>
|
||||||
|
<if test="entity.carNo != null and entity.carNo != ''"> and car_no = #{entity.carNo}</if>
|
||||||
<if test="entity.carPhoto != null and vcarPhoto != ''"> and car_photo = #{entity.carPhoto}</if>
|
<if test="entity.carPhoto != null and vcarPhoto != ''"> and car_photo = #{entity.carPhoto}</if>
|
||||||
<if test="entity.carRegisterDate != null "> and car_register_date = #{entity.carRegisterDate}</if>
|
<if test="entity.carRegisterDate != null "> and car_register_date = #{entity.carRegisterDate}</if>
|
||||||
<if test="entity.inspectionDate != null "> and inspection_date = #{entity.inspectionDate}</if>
|
<if test="entity.inspectionDate != null "> and inspection_date = #{entity.inspectionDate}</if>
|
||||||
@ -110,6 +111,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="coachId != null and coachId != ''">
|
<if test="coachId != null and coachId != ''">
|
||||||
AND dst.coach_id = #{coachId}
|
AND dst.coach_id = #{coachId}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="searchValue != null and searchValue != ''">
|
||||||
|
AND dsc.car_no LIKE CONCAT('%',#{searchValue},'%')
|
||||||
|
</if>
|
||||||
<if test="startTime!=null and startTime!=''">
|
<if test="startTime!=null and startTime!=''">
|
||||||
AND dst.create_time >= #{startTime}
|
AND dst.create_time >= #{startTime}
|
||||||
</if>
|
</if>
|
||||||
|
Loading…
Reference in New Issue
Block a user