Browse Source

个人打卡模块完成

ry
loser 1 year ago
parent
commit
ccce96d45e
  1. 13
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/CheckController.java
  2. 2
      ruoyi-admin/src/main/resources/templates/index-topnav.html
  3. 2
      ruoyi-admin/src/main/resources/templates/index.html
  4. 2
      ruoyi-admin/src/main/resources/templates/login.html
  5. 24
      ruoyi-admin/src/main/resources/templates/patient/patientManage/patientManage.html
  6. 4
      ruoyi-system/src/main/java/com/ruoyi/system/domain/Check.java
  7. 8
      ruoyi-system/src/main/java/com/ruoyi/system/mapper/CheckMapper.java
  8. 7
      ruoyi-system/src/main/java/com/ruoyi/system/service/ICheckService.java
  9. 12
      ruoyi-system/src/main/java/com/ruoyi/system/service/impl/CheckServiceImpl.java
  10. 2
      ruoyi-system/src/main/resources/mapper/CheckManageMapper.xml
  11. 34
      ruoyi-system/src/main/resources/mapper/CheckMapper.xml

13
ruoyi-admin/src/main/java/com/ruoyi/web/controller/CheckController.java

@ -43,19 +43,6 @@ public class CheckController extends BaseController
}
/**
* 查询个人打卡列表
*/
@RequiresPermissions("individual:check:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(Check check)
{
startPage();
List<Check> list = checkService.selectCheckList(check);
return getDataTable(list);
}
/**
* 新增个人打卡
*/
@GetMapping("/add")

2
ruoyi-admin/src/main/resources/templates/index-topnav.html

@ -246,7 +246,7 @@
</div>
<!-- 右侧栏 -->
<ul class="nav navbar-top-links navbar-right welcome-message">
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="如何防疫" href="#" target="_blank"><i class="fa fa-question-circle"></i>如何防疫?</a></li>
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="如何防疫" href="https://baijiahao.baidu.com/s?id=1725567014249963256&wfr=spider&for=pc" target="_blank"><i class="fa fa-question-circle"></i>如何防疫?</a></li>
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="锁定屏幕" href="#" id="lockScreen"><i class="fa fa-lock"></i> 锁屏</a></li>
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="全屏显示" href="#" id="fullScreen"><i class="fa fa-arrows-alt"></i> 全屏</a></li>

2
ruoyi-admin/src/main/resources/templates/index.html

@ -193,7 +193,7 @@
</a>
</div>
<ul class="nav navbar-top-links navbar-right welcome-message">
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="如何防疫" href="#" target="_blank"><i class="fa fa-question-circle"></i>如何防疫</a></li>
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="如何防疫" href="https://baijiahao.baidu.com/s?id=1725567014249963256&wfr=spider&for=pc" target="_blank"><i class="fa fa-question-circle"></i>如何防疫</a></li>
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="锁定屏幕" href="#" id="lockScreen"><i class="fa fa-lock"></i> 锁屏</a></li>
<li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="全屏显示" href="#" id="fullScreen"><i class="fa fa-arrows-alt"></i> 全屏</a></li>
<li class="dropdown user-menu">

2
ruoyi-admin/src/main/resources/templates/login.html

@ -29,7 +29,7 @@
<h1><img alt="[ 若依 ]" src="../static/ruoyi.png" th:src="@{/ruoyi.png}"></h1>
</div>
<div class="m-b"></div>
<h4>欢迎使用 <strong>可视化医院管理系统</strong></h4>
<h4>欢迎使用 <strong>可视化管理系统</strong></h4>
<strong th:if="${isAllowRegister}">还没有账号? <a th:href="@{/register}">立即注册&raquo;</a></strong>
</div>
</div>

24
ruoyi-admin/src/main/resources/templates/patient/patientManage/patientManage.html

@ -39,22 +39,6 @@
<input type="text" class="time-input" placeholder="请选择感染时间" name="diagnosedTime"/>
</li>
<li>
<label>确诊状态:</label>
<input type="text" name="isDiagnosed"/>
</li>
<li>
<label>治愈状态:</label>
<input type="text" name="isCure"/>
</li>
<li>
<label>密接状态:</label>
<input type="text" name="isTouch"/>
</li>
<li>
<label>死亡状态:</label>
<input type="text" name="isDead"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
@ -140,6 +124,14 @@
field: 'isDiagnosed',
title: '确诊状态'
},
{
visible: editFlag == 'hidden' ? false : true,
title: '确诊状态',
align: 'center',
formatter: function (value, row, index) {
return statusTools(row);
}
},
{
field: 'isCure',
title: '治愈状态'

4
ruoyi-system/src/main/java/com/ruoyi/system/domain/Check.java

@ -7,6 +7,7 @@ import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.apache.ibatis.annotations.Param;
import javax.validation.constraints.Size;
@ -70,7 +71,7 @@ public class Check extends BaseEntity
this.checkName = checkName;
}
@Xss(message = "用户昵称不能包含脚本字符")
@Size(min = 0, max = 30, message = "用户昵称长度不能超过30个字符")
@Size(min = 2, max = 30, message = "不能为空,用户昵称长度不能超过30个字符")
public String getCheckName()
{
return checkName;
@ -125,7 +126,6 @@ public class Check extends BaseEntity
{
this.checkDatetime = checkDatetime;
}
public Date getCheckDatetime()
{
return checkDatetime;

8
ruoyi-system/src/main/java/com/ruoyi/system/mapper/CheckMapper.java

@ -13,14 +13,6 @@ public interface CheckMapper
{
/**
* 查询个人打卡列表
*
* @param check 个人打卡
* @return 个人打卡集合
*/
public List<Check> selectCheckList(Check check);
/**
* 新增个人打卡
*
* @param check 个人打卡

7
ruoyi-system/src/main/java/com/ruoyi/system/service/ICheckService.java

@ -11,13 +11,6 @@ import com.ruoyi.system.domain.Check;
*/
public interface ICheckService
{
/**
* 查询个人打卡列表
*
* @param check 个人打卡
* @return 个人打卡集合
*/
public List<Check> selectCheckList(Check check);
/**
* 新增个人打卡

12
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/CheckServiceImpl.java

@ -19,18 +19,6 @@ public class CheckServiceImpl implements ICheckService {
@Autowired
private CheckMapper checkMapper;
/**
* 查询个人打卡列表
*
* @param check 个人打卡
* @return 个人打卡
*/
@Override
public List<Check> selectCheckList(Check check) {
return checkMapper.selectCheckList(check);
}
/**
* 新增个人打卡
*

2
ruoyi-system/src/main/resources/mapper/CheckManageMapper.xml

@ -49,7 +49,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
insert into check_manage
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="checkName != null">check_name,</if>
<if test="checkAge != null">check_age,</if>
<if test="checkAge != null">check_age,</if>
<if test="checkSex != null">check_sex,</if>
<if test="patientPhone != null">patient_phone,</if>
<if test="isDiagnosed != null">is_diagnosed,</if>

34
ruoyi-system/src/main/resources/mapper/CheckMapper.xml

@ -16,29 +16,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="currentPosition" column="current_position" />
</resultMap>
<sql id="selectCheckVo">
select check_id, check_name, temperature, state, is_high, is_touch, description, check_datetime, current_position from check
</sql>
<select id="selectCheckList" parameterType="Check" resultMap="CheckResult">
<include refid="selectCheckVo"/>
<where>
<if test="checkName != null and checkName != ''"> and check_name like concat('%', #{checkName}, '%')</if>
<if test="temperature != null and temperature != ''"> and temperature = #{temperature}</if>
<if test="state != null and state != ''"> and state like concat('%', #{state}, '%')</if>
<if test="isHigh != null "> and is_high = #{isHigh}</if>
<if test="isTouch != null "> and is_touch = #{isTouch}</if>
<if test="description != null and description != ''"> and description like concat('%', #{description}, '%')</if>
<if test="checkDatetime != null "> and check_datetime = #{checkDatetime}</if>
<if test="currentPosition != null and currentPosition != ''"> and current_position = #{currentPosition}</if>
</where>
</select>
<insert id="insertCheck" parameterType="Check" useGeneratedKeys="true" keyProperty="checkId">
insert into check(
<if test="checkId != null and checkId != ''">check_id,</if>
insert into individual_check
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="checkName != null and checkName != ''">check_name,</if>
<if test="temperature != null and temperature != ''">temperature,</if>
<if test="state != null and state != ''">state,</if>
@ -46,9 +26,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="isHigh != null ">is_high,</if>
<if test="isTouch != null ">is_touch,</if>
<if test="currentPosition != null and currentPosition != ''">current_position,</if>
<if test="checkDatetime != null and checkDatetime != ''">check_datetime</if>
)values(
<if test="checkId != null and checkId != ''">#{checkId},</if>
<if test="checkDatetime != null ">check_datetime,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="checkName != null and checkName != ''">#{checkName},</if>
<if test="temperature != null and temperature != ''">#{temperature},</if>
<if test="state != null and state != ''">#{state},</if>
@ -56,8 +36,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="isHigh != null and isHigh != ''">#{isHigh},</if>
<if test="isTouch != null and isTouch != ''">#{isTouch},</if>
<if test="currentPosition != null and currentPosition != ''">#{currentPosition},</if>
<if test="checkDatetime != null and checkDatetime != ''">#{check_datetime}</if>
)
<if test="checkDatetime != null ">#{checkDatetime},</if>
</trim>
</insert>

Loading…
Cancel
Save