From afc2b4d2800d91c793523d14fbe2d6fbbd319fc0 Mon Sep 17 00:00:00 2001
From: 钟日健 <5689795+arsn@user.noreply.gitee.com>
Date: Fri, 25 Feb 2022 09:02:41 +0800
Subject: [PATCH] 模拟考试开始修改,返回所有题目的所有答题信息
---
src/main/java/org/springblade/modules/system/mapper/UserMapper.xml | 21 ++++++++++++++++++---
1 files changed, 18 insertions(+), 3 deletions(-)
diff --git a/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml b/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml
index 6f0a6ae..85a849c 100644
--- a/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml
+++ b/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml
@@ -568,7 +568,7 @@
from (
select
distinct
- bu.id
+ bu.id,
ifnull(TIMESTAMPDIFF(YEAR, SUBSTRING(bu.cardid, 7, 8), CURDATE()),0) AS age,
bu.is_apply isApply,
bu.is_train isTrain,
@@ -656,7 +656,16 @@
blade_dept bd
on
bu.dept_id = bd.id
- where securitynumber = #{securityNumber}
+ where
+ 1=1
+ <if test="securityNumber!=null and securityNumber!=''">
+ and securitynumber = #{securityNumber}
+ </if>
+ <if test="cardid!=null and cardid!=''">
+ and cardid = #{cardid}
+ </if>
+ and bu.status = 1
+ and bu.is_deleted = 0
</select>
@@ -983,7 +992,12 @@
<if test="user.cardid!=null and user.cardid != ''">
and bu.cardid like concat('%', #{user.cardid},'%')
</if>
- ORDER BY bu.id desc
+ <if test="user.sortName!=null and user.sortName!=''">
+ ORDER BY bu.${user.sortName} ${user.sort},bu.id desc
+ </if>
+ <if test="user.sortName==null or user.sortName==''">
+ ORDER BY bu.id desc
+ </if>
</select>
<!--查询押运人员编码不为null的保安信息-->
@@ -996,6 +1010,7 @@
AND is_deleted = 0
AND `status` = 1
AND equipment_code IS NOT NULL
+ AND equipment_code!=""
</select>
<!--查詢用戶派遣記錄信息-->
--
Gitblit v1.9.3