Merge remote-tracking branch 'origin/master'

# Conflicts:
#	src/main/java/com/msdw/tms/dao/AchievementManagementDao.java
hehai
jiakun.lin 4 years ago
commit 26b1ac4d40
  1. 2
      src/main/java/com/msdw/tms/api/ProjectRcordControllerApi.java
  2. 4
      src/main/java/com/msdw/tms/controller/ProjectRecordController.java
  3. 6
      src/main/java/com/msdw/tms/dao/AchievementManagementDao.java
  4. 2
      src/main/java/com/msdw/tms/dao/ProjectRecordDao.java
  5. 2
      src/main/java/com/msdw/tms/dao/UserDao.java
  6. 9
      src/main/java/com/msdw/tms/entity/resp/GetByUserRecordResp.java
  7. 2
      src/main/java/com/msdw/tms/service/ProjectRecordService.java
  8. 7
      src/main/java/com/msdw/tms/service/impl/AchievementManagementServiceImpl.java
  9. 4
      src/main/java/com/msdw/tms/service/impl/ProjectRecordServiceImpl.java
  10. 37
      src/main/resources/mapper/tms/AchievementManagementDao.xml
  11. 4
      src/main/resources/mapper/tms/ProjectRecordDao.xml
  12. 2
      src/main/resources/mapper/tms/StudentDao.xml
  13. 4
      src/main/resources/mapper/tms/UserInfoDao.xml

@ -18,7 +18,7 @@ public interface ProjectRcordControllerApi {
Integer recordState,String condition);
@ApiOperation(value = "用户端虚拟仿真实验记录",notes = "用户端虚拟仿真实验记录")
R queryUserRecord(Integer page,Integer size,Integer userId,Integer projectPermissions);
R queryUserRecord(Integer page,Integer size,Integer userId,Integer projectPermissions,Integer systemId);
@ApiOperation(value = "用户端教学实验记录",notes = "用户端教学实验记录")
R getUserExperimentscore(Integer page,Integer size,Integer userid);

@ -63,8 +63,8 @@ public class ProjectRecordController implements ProjectRcordControllerApi {
*/
@Override
@GetMapping("/user/record")
public R queryUserRecord(@RequestParam Integer page,@RequestParam Integer size,@RequestParam Integer userId,@RequestParam Integer projectPermissions){
PageUtils page1 = projectRecordService.queryPage(page,size,userId,projectPermissions);
public R queryUserRecord(@RequestParam Integer page,@RequestParam Integer size,@RequestParam Integer userId,@RequestParam Integer projectPermissions,@RequestParam Integer systemId){
PageUtils page1 = projectRecordService.queryPage(page,size,userId,projectPermissions,systemId);
return R.ok().put("data", page1);
}

@ -16,7 +16,6 @@ import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.poi.ss.formula.functions.T;
import java.util.ArrayList;
import java.util.List;
@Mapper
@ -48,7 +47,7 @@ public interface AchievementManagementDao extends BaseMapper<ExperimentalReportE
AchievementManagementVO queryReport(Integer reportId);
void deleteReport(Integer reportId,Integer recordId);
void deleteReport(Integer reportId);
IPage<AchievementManagementVO> queryEvaluationReport(Page<T> tPage, String searchContant, Integer projectId);
@ -73,7 +72,4 @@ public interface AchievementManagementDao extends BaseMapper<ExperimentalReportE
List<AchievementManagementVO> queryPythonTest(Integer eventId);
void updateSignatrue(Integer isSignature,Integer signatureId,Integer reportId,String comment);
void deleteReportById(Integer projectId);
}

@ -23,7 +23,7 @@ import java.util.List;
@Mapper
public interface ProjectRecordDao extends BaseMapper<ProjectRecordEntity> {
IPage<GetByUserRecordResp> getByUserRecord(Page page, @Param("userId") Integer userId, @Param("projectPermissions") Integer projectPermissions);
IPage<GetByUserRecordResp> getByUserRecord(Page page, @Param("userId") Integer userId, @Param("projectPermissions") Integer projectPermissions,@Param("systemId") Integer systemId);
IPage<ProjectRecordVo> getByUserExperimentRecord(Page page, @Param("pro") ProjectRecordEntity projectRecordEntity);

@ -41,7 +41,7 @@ public interface UserDao extends BaseMapper<UserEntity> {
List<String> findPhoneSetTime(String phone, String checkCode,Integer types);
boolean saveCheckPhoneCode(CheckVo checkVo);
// boolean saveCheckPhoneCode(CheckVo checkVo);
List<Integer> queryPhone(CheckVo checkVo);
}

@ -22,6 +22,15 @@ public class GetByUserRecordResp {
private String submitTime;
private Integer timeSum;
private Integer userId;
private Integer systemId;
public Integer getSystemId() {
return systemId;
}
public void setSystemId(Integer systemId) {
this.systemId = systemId;
}
public String getProjectName() {
return projectName;

@ -17,7 +17,7 @@ import java.util.List;
*/
public interface ProjectRecordService extends IService<ProjectRecordEntity> {
PageUtils queryPage(Integer page, Integer size, Integer userId, Integer projectPermissions);
PageUtils queryPage(Integer page, Integer size, Integer userId, Integer projectPermissions,Integer systemId);
PageUtils queryExperimentPage(Integer page, Integer size, Integer userid);

@ -28,6 +28,7 @@ import org.springframework.transaction.annotation.Transactional;
import javax.servlet.http.HttpServletResponse;
import java.io.InputStream;
import java.util.*;
@Slf4j
@Service
public class AchievementManagementServiceImpl extends ServiceImpl<AchievementManagementDao, ExperimentalReportEntity> implements AchievementManagementService {
@ -179,6 +180,8 @@ public class AchievementManagementServiceImpl extends ServiceImpl<AchievementMan
public R queryEvaluationReport(String searchContant, Integer projectId, Integer page, Integer size) {
Page<T> tPage = new Page<>(page, size);
IPage<AchievementManagementVO> data = achievementManagementDao.queryEvaluationReport(tPage, searchContant, projectId);
PageUtils result = new PageUtils(data);
return R.ok().put("data", result);
@ -213,7 +216,9 @@ public class AchievementManagementServiceImpl extends ServiceImpl<AchievementMan
List<AchievementManagementVO> vo = new ArrayList<>();
List<Integer> educationResult = achievementManagementDao.countEducationProjectId();//获取教学实验的主键id
List<Integer> fictitiousResult = achievementManagementDao.countFictitiousProjectId();//获取教学实验的主键id
if (projectPermissions==null){projectPermissions=-9999;}
if (projectPermissions == null) {
projectPermissions = -9999;
}
if (projectPermissions == 0) {//只查询练习项目
fictitious = achievementManagementDao.queryFictitiousRecord(systemId, searchContant, startingtime, endtime, month, fictitiousResult);
vo = fictitious;

@ -38,7 +38,7 @@ public class ProjectRecordServiceImpl extends ServiceImpl<ProjectRecordDao, Proj
@Override
public PageUtils queryPage(Integer page, Integer size, Integer userId, Integer projectPermissions) {
public PageUtils queryPage(Integer page, Integer size, Integer userId, Integer projectPermissions,Integer systemId) {
/*GetByUserRecordResp projectRecord = new GetByUserRecordResp();
projectRecord.setUserId(userId);*/
@ -46,7 +46,7 @@ public class ProjectRecordServiceImpl extends ServiceImpl<ProjectRecordDao, Proj
//分页对象
Page<T> page1 = new Page<>(page, size);
IPage<GetByUserRecordResp> projectRecordVos = this.baseMapper.getByUserRecord(page1, userId, projectPermissions);
IPage<GetByUserRecordResp> projectRecordVos = this.baseMapper.getByUserRecord(page1, userId, projectPermissions,systemId);
PageUtils questionsPage = new PageUtils(projectRecordVos);

@ -132,7 +132,8 @@
LEFT JOIN hr_project_management AS hpm ON hpm.projectId = tpr.projectId
WHERE reportId = #{reportId}
</select>
<select id="queryEvaluationReport" resultType="com.msdw.tms.entity.vo.AchievementManagementVO">
<!--
SELECT
u.userName,
sch.schoolName,
@ -158,14 +159,46 @@
AND tcr.isdel = 0
AND u.isdel = 0
AND tpr.projectId = #{projectId}
<if test="searchContant!=null and searchContant!=''">AND (sch.schoolName LIKE CONCAT('%',#{searchContant},'%')
<if test="searchContant!=null and searchContant!=''">
AND (sch.schoolName LIKE CONCAT('%',#{searchContant},'%')
OR u.userName LIKE CONCAT('%',#{searchContant},'%') )
</if>
GROUP BY
tcr.reportId
ORDER BY tpr.submitTime DESC
-->
<select id="queryEvaluationReport" resultType="com.msdw.tms.entity.vo.AchievementManagementVO">
SELECT
r.reportId,
re.recordId,
sch.schoolName,
s.workNumber,
u.userName,
re.score,
re.submitTime,
r.eventId
FROM
tms_experimental_report r
INNER JOIN tms_experimental_teaching t ON t.id = r.projectId
INNER JOIN student s ON s.studentId = r.studentId
INNER JOIN school sch ON sch.schoolId = s.schoolId
INNER JOIN hr_user_info u ON u.userId = s.userId
INNER JOIN tms_project_record re ON re.projectId = t.project_id
WHERE
t.id = r.projectId
and r.eventId = re.recordId
AND r.projectId = #{projectId}
AND r.isdel = 0
AND t.is_del = 0
AND u.isdel = 0
<if test="searchContant!=null and searchContant!=''">
AND (sch.schoolName LIKE CONCAT('%',#{searchContant},'%')
OR u.userName LIKE CONCAT('%',#{searchContant},'%') )
</if>
GROUP BY r.reportId DESC
</select>
<select id="queryAchievement" resultType="com.msdw.tms.entity.request.AchievementImportRequest">
SELECT
u.userName,

@ -52,13 +52,15 @@
r.startingTime,
r.submitTime,
r.timeSum,
c.userId
c.userId,
t.systemId
FROM hr_experiment_code c
INNER JOIN hr_project_management t ON t.projectId = c.projectId
INNER JOIN tms_project_record r ON r.recordId = c.recordId
WHERE c.userId = #{userId}
and r.isdel = 0
and projectPermissions = #{projectPermissions}
and t.systemId = #{systemId}
GROUP BY c.recordId desc
</select>

@ -43,7 +43,7 @@
AND u.isdel = 0
AND l.isdel = 0
AND s.isdel = 0
<if test="searchContent!=null">AND (u.userName LIKE CONCAT('%',#{searchContent},'%') OR s.workNumber LIKE CONCAT('%',#{searchContent},'%'))</if>
<if test="searchContent!=null">AND (u.account LIKE CONCAT('%',#{searchContent},'%') OR u.userName LIKE CONCAT('%',#{searchContent},'%') OR s.workNumber LIKE CONCAT('%',#{searchContent},'%'))</if>
ORDER BY
lastLoginTime DESC,studentId DESC
</select>

@ -215,7 +215,7 @@
</update>
<select id="queryPersonalFileES" parameterType="com.msdw.tms.entity.UserPersonalFileEntity"
resultType="hashMap">
resultType="com.msdw.tms.entity.vo.UserProsonalEntityVo">
SELECT
personalFileId,
schoolId,
@ -233,7 +233,7 @@
userId = #{userId}
</select>
<select id="queryPersonalInfo" parameterType="com.msdw.tms.entity.UserInfoEntity"
resultType="hashMap">
resultType="com.msdw.tms.entity.vo.UserProsonalEntityVo">
SELECT
u.userId,
userName,

Loading…
Cancel
Save