Commit e26e27bfedcff905879ef37a843cfcd3b011dead
1 parent
f140e57a
fix: 新增修改人
Showing
14 changed files
with
149 additions
and
26 deletions
ruoyi-admin/src/main/java/com/ruoyi/controller/AttendanceController.java
| 1 | package com.ruoyi.controller; | 1 | package com.ruoyi.controller; |
| 2 | 2 | ||
| 3 | +import com.ruoyi.common.annotation.Log; | ||
| 3 | import com.ruoyi.common.core.controller.BaseController; | 4 | import com.ruoyi.common.core.controller.BaseController; |
| 4 | import com.ruoyi.common.core.page.TableDataInfo; | 5 | import com.ruoyi.common.core.page.TableDataInfo; |
| 6 | +import com.ruoyi.common.enums.BusinessType; | ||
| 5 | import com.ruoyi.common.global.Result; | 7 | import com.ruoyi.common.global.Result; |
| 6 | import com.ruoyi.domain.RuleAttendanceMain; | 8 | import com.ruoyi.domain.RuleAttendanceMain; |
| 7 | import com.ruoyi.pojo.dto.SchedulingDto; | 9 | import com.ruoyi.pojo.dto.SchedulingDto; |
| @@ -64,6 +66,7 @@ public class AttendanceController extends BaseController { | @@ -64,6 +66,7 @@ public class AttendanceController extends BaseController { | ||
| 64 | */ | 66 | */ |
| 65 | @ApiOperation("排班设置") | 67 | @ApiOperation("排班设置") |
| 66 | @PostMapping("/saveSchedulingSetting") | 68 | @PostMapping("/saveSchedulingSetting") |
| 69 | + @Log(title = "新增排班设置", businessType = BusinessType.INSERT) | ||
| 67 | public Result<?> saveSchedulingSetting(@RequestBody @Validated SchedulingSettingDto dto) { | 70 | public Result<?> saveSchedulingSetting(@RequestBody @Validated SchedulingSettingDto dto) { |
| 68 | attendanceService.saveSchedulingSetting(dto); | 71 | attendanceService.saveSchedulingSetting(dto); |
| 69 | return Result.OK("新增成功"); | 72 | return Result.OK("新增成功"); |
| @@ -74,6 +77,7 @@ public class AttendanceController extends BaseController { | @@ -74,6 +77,7 @@ public class AttendanceController extends BaseController { | ||
| 74 | */ | 77 | */ |
| 75 | @ApiOperation("排班设置") | 78 | @ApiOperation("排班设置") |
| 76 | @PutMapping("/updateSchedulingSetting") | 79 | @PutMapping("/updateSchedulingSetting") |
| 80 | + @Log(title = "修改排班设置", businessType = BusinessType.UPDATE) | ||
| 77 | public Result<?> updateSchedulingSetting(@RequestBody @Validated SchedulingDto dto) { | 81 | public Result<?> updateSchedulingSetting(@RequestBody @Validated SchedulingDto dto) { |
| 78 | attendanceService.updateSchedulingSetting(dto); | 82 | attendanceService.updateSchedulingSetting(dto); |
| 79 | return Result.OK("新增成功"); | 83 | return Result.OK("新增成功"); |
| @@ -84,6 +88,7 @@ public class AttendanceController extends BaseController { | @@ -84,6 +88,7 @@ public class AttendanceController extends BaseController { | ||
| 84 | */ | 88 | */ |
| 85 | @ApiOperation("排班设置") | 89 | @ApiOperation("排班设置") |
| 86 | @DeleteMapping("/deleteSchedulingSetting/{settingId}") | 90 | @DeleteMapping("/deleteSchedulingSetting/{settingId}") |
| 91 | + @Log(title = "删除排班设置", businessType = BusinessType.DELETE) | ||
| 87 | public Result<?> deleteSchedulingSetting(@PathVariable("settingId") Integer settingId) { | 92 | public Result<?> deleteSchedulingSetting(@PathVariable("settingId") Integer settingId) { |
| 88 | attendanceService.deleteSchedulingSetting(settingId); | 93 | attendanceService.deleteSchedulingSetting(settingId); |
| 89 | return Result.OK("删除成功"); | 94 | return Result.OK("删除成功"); |
| @@ -102,6 +107,7 @@ public class AttendanceController extends BaseController { | @@ -102,6 +107,7 @@ public class AttendanceController extends BaseController { | ||
| 102 | 107 | ||
| 103 | @ApiOperation("修改考情表") | 108 | @ApiOperation("修改考情表") |
| 104 | @PutMapping("/update/attendance") | 109 | @PutMapping("/update/attendance") |
| 110 | + @Log(title = "修改考情表", businessType = BusinessType.UPDATE) | ||
| 105 | public Result<?> updateAttendance(@RequestBody @Validated UpdateAttendanceVo vo) { | 111 | public Result<?> updateAttendance(@RequestBody @Validated UpdateAttendanceVo vo) { |
| 106 | try { | 112 | try { |
| 107 | attendanceService.updateAttendance(vo); | 113 | attendanceService.updateAttendance(vo); |
| @@ -113,6 +119,7 @@ public class AttendanceController extends BaseController { | @@ -113,6 +119,7 @@ public class AttendanceController extends BaseController { | ||
| 113 | 119 | ||
| 114 | @ApiOperation("删除考勤表") | 120 | @ApiOperation("删除考勤表") |
| 115 | @PostMapping("/delete/attendance") | 121 | @PostMapping("/delete/attendance") |
| 122 | + @Log(title = "删除考勤表", businessType = BusinessType.DELETE) | ||
| 116 | public Result<?> deleteAttendance(@RequestBody DeleteAttendanceVo vo) { | 123 | public Result<?> deleteAttendance(@RequestBody DeleteAttendanceVo vo) { |
| 117 | try { | 124 | try { |
| 118 | attendanceService.deleteAttendance(vo); | 125 | attendanceService.deleteAttendance(vo); |
| @@ -127,4 +134,13 @@ public class AttendanceController extends BaseController { | @@ -127,4 +134,13 @@ public class AttendanceController extends BaseController { | ||
| 127 | public Result<?> getPeopleList(@ModelAttribute PeopleRequestVo vo){ | 134 | public Result<?> getPeopleList(@ModelAttribute PeopleRequestVo vo){ |
| 128 | return Result.OK(attendanceService.getPeopleList(vo)); | 135 | return Result.OK(attendanceService.getPeopleList(vo)); |
| 129 | } | 136 | } |
| 137 | + | ||
| 138 | + | ||
| 139 | + @GetMapping("/table/month") | ||
| 140 | + @ApiOperation("获取一个月的table") | ||
| 141 | + public Result<?> getTableMonth(){ | ||
| 142 | + // 修改周期 | ||
| 143 | + return null; | ||
| 144 | + } | ||
| 145 | + | ||
| 130 | } | 146 | } |
ruoyi-admin/src/main/java/com/ruoyi/in/service/impl/SignInServiceImpl.java
| @@ -401,7 +401,7 @@ public class SignInServiceImpl implements ISignInService { | @@ -401,7 +401,7 @@ public class SignInServiceImpl implements ISignInService { | ||
| 401 | Integer count = redisCache.getCacheObject(key); | 401 | Integer count = redisCache.getCacheObject(key); |
| 402 | if (Objects.isNull(count) || count.equals(0)) { | 402 | if (Objects.isNull(count) || count.equals(0)) { |
| 403 | count = 1; | 403 | count = 1; |
| 404 | - redisCache.setCacheMapValue(key, signIn.getJobCode(), count); | 404 | + redisCache.setCacheObject(key, count); |
| 405 | } else { | 405 | } else { |
| 406 | redisCache.setCacheObject(key, ++count); | 406 | redisCache.setCacheObject(key, ++count); |
| 407 | } | 407 | } |
ruoyi-admin/src/main/java/com/ruoyi/num/domain/RuleNum.java
| @@ -6,6 +6,8 @@ import org.apache.commons.lang3.builder.ToStringStyle; | @@ -6,6 +6,8 @@ import org.apache.commons.lang3.builder.ToStringStyle; | ||
| 6 | import com.ruoyi.common.annotation.Excel; | 6 | import com.ruoyi.common.annotation.Excel; |
| 7 | import com.ruoyi.common.core.domain.BaseEntity; | 7 | import com.ruoyi.common.core.domain.BaseEntity; |
| 8 | 8 | ||
| 9 | +import java.util.Date; | ||
| 10 | + | ||
| 9 | /** | 11 | /** |
| 10 | * 班次管理对象 rule_num | 12 | * 班次管理对象 rule_num |
| 11 | * | 13 | * |
| @@ -40,4 +42,12 @@ public class RuleNum extends BaseEntity | @@ -40,4 +42,12 @@ public class RuleNum extends BaseEntity | ||
| 40 | @Excel(name = "星期翻班详情") | 42 | @Excel(name = "星期翻班详情") |
| 41 | private String ruleWeek; | 43 | private String ruleWeek; |
| 42 | 44 | ||
| 45 | + private Date createTime; | ||
| 46 | + | ||
| 47 | + private Date updateTime; | ||
| 48 | + | ||
| 49 | + private String createBy; | ||
| 50 | + | ||
| 51 | + private String updateBy; | ||
| 52 | + | ||
| 43 | } | 53 | } |
ruoyi-admin/src/main/java/com/ruoyi/num/service/impl/RuleNumServiceImpl.java
| @@ -8,6 +8,7 @@ import java.util.stream.Collectors; | @@ -8,6 +8,7 @@ import java.util.stream.Collectors; | ||
| 8 | import java.util.stream.Stream; | 8 | import java.util.stream.Stream; |
| 9 | 9 | ||
| 10 | import cn.hutool.core.bean.BeanUtil; | 10 | import cn.hutool.core.bean.BeanUtil; |
| 11 | +import com.ruoyi.common.utils.DateUtils; | ||
| 11 | import com.ruoyi.common.utils.SecurityUtils; | 12 | import com.ruoyi.common.utils.SecurityUtils; |
| 12 | import com.ruoyi.pojo.dto.RuleNumDto; | 13 | import com.ruoyi.pojo.dto.RuleNumDto; |
| 13 | import com.ruoyi.pojo.vo.RuleNumTemplateVo; | 14 | import com.ruoyi.pojo.vo.RuleNumTemplateVo; |
| @@ -65,6 +66,11 @@ public class RuleNumServiceImpl implements IRuleNumService | @@ -65,6 +66,11 @@ public class RuleNumServiceImpl implements IRuleNumService | ||
| 65 | @Override | 66 | @Override |
| 66 | public int insertRuleNum(RuleNum ruleNum) | 67 | public int insertRuleNum(RuleNum ruleNum) |
| 67 | { | 68 | { |
| 69 | + String username = SecurityUtils.getUsername(); | ||
| 70 | + ruleNum.setCreateBy(username); | ||
| 71 | + ruleNum.setUpdateBy(username); | ||
| 72 | + ruleNum.setCreateTime(DateUtils.getNowDate()); | ||
| 73 | + ruleNum.setUpdateTime(DateUtils.getNowDate()); | ||
| 68 | return ruleNumMapper.insertRuleNum(ruleNum); | 74 | return ruleNumMapper.insertRuleNum(ruleNum); |
| 69 | } | 75 | } |
| 70 | 76 | ||
| @@ -77,6 +83,8 @@ public class RuleNumServiceImpl implements IRuleNumService | @@ -77,6 +83,8 @@ public class RuleNumServiceImpl implements IRuleNumService | ||
| 77 | @Override | 83 | @Override |
| 78 | public int updateRuleNum(RuleNum ruleNum) | 84 | public int updateRuleNum(RuleNum ruleNum) |
| 79 | { | 85 | { |
| 86 | + ruleNum.setUpdateTime(DateUtils.getNowDate()); | ||
| 87 | + ruleNum.setUpdateBy(ruleNum.getUpdateBy()); | ||
| 80 | return ruleNumMapper.updateRuleNum(ruleNum); | 88 | return ruleNumMapper.updateRuleNum(ruleNum); |
| 81 | } | 89 | } |
| 82 | 90 |
ruoyi-admin/src/main/java/com/ruoyi/pojo/vo/SchedulingResponseVo.java
| @@ -4,6 +4,7 @@ import com.ruoyi.domain.RuleNumSetting; | @@ -4,6 +4,7 @@ import com.ruoyi.domain.RuleNumSetting; | ||
| 4 | import io.swagger.annotations.ApiModelProperty; | 4 | import io.swagger.annotations.ApiModelProperty; |
| 5 | import lombok.Data; | 5 | import lombok.Data; |
| 6 | 6 | ||
| 7 | +import java.util.Date; | ||
| 7 | import java.util.List; | 8 | import java.util.List; |
| 8 | 9 | ||
| 9 | /** | 10 | /** |
| @@ -20,4 +21,8 @@ public class SchedulingResponseVo extends RuleNumSetting { | @@ -20,4 +21,8 @@ public class SchedulingResponseVo extends RuleNumSetting { | ||
| 20 | private List<String> ruleList; | 21 | private List<String> ruleList; |
| 21 | @ApiModelProperty("适用人员") | 22 | @ApiModelProperty("适用人员") |
| 22 | private List<String> peopleList; | 23 | private List<String> peopleList; |
| 24 | + private Date createTime; | ||
| 25 | + private Date updateTime; | ||
| 26 | + private String createBy; | ||
| 27 | + private String updateBy; | ||
| 23 | } | 28 | } |
ruoyi-admin/src/main/java/com/ruoyi/pojo/vo/TableMonthResponseVo.java
0 → 100644
| 1 | +package com.ruoyi.pojo.vo; | ||
| 2 | + | ||
| 3 | +import com.ruoyi.domain.RuleAttendanceMain; | ||
| 4 | +import lombok.Data; | ||
| 5 | + | ||
| 6 | +import java.util.List; | ||
| 7 | + | ||
| 8 | +/** | ||
| 9 | + * | ||
| 10 | + * @author 20412 | ||
| 11 | + */ | ||
| 12 | +@Data | ||
| 13 | +public class TableMonthResponseVo { | ||
| 14 | + private String jobCode; | ||
| 15 | + private String name; | ||
| 16 | + private String fleetName; | ||
| 17 | + private String posts; | ||
| 18 | + private List<RuleAttendanceMain> monthList; | ||
| 19 | + private Integer nowMonthDaysCount; | ||
| 20 | +// | ||
| 21 | +// @Data | ||
| 22 | +// public | ||
| 23 | +} |
ruoyi-admin/src/main/java/com/ruoyi/scheduling/domain/RuleScheduling.java
| @@ -91,4 +91,12 @@ public class RuleScheduling extends BaseEntity | @@ -91,4 +91,12 @@ public class RuleScheduling extends BaseEntity | ||
| 91 | @Excel(name = "第二段上下班标识,今天时间还是隔天") | 91 | @Excel(name = "第二段上下班标识,今天时间还是隔天") |
| 92 | private Integer secondSignDayTomorrow; | 92 | private Integer secondSignDayTomorrow; |
| 93 | 93 | ||
| 94 | + private Date updateTime; | ||
| 95 | + | ||
| 96 | + private Date createTime; | ||
| 97 | + | ||
| 98 | + private String updateBy; | ||
| 99 | + | ||
| 100 | + private String createBy; | ||
| 101 | + | ||
| 94 | } | 102 | } |
ruoyi-admin/src/main/java/com/ruoyi/scheduling/service/impl/RuleSchedulingServiceImpl.java
| @@ -7,6 +7,8 @@ import java.util.List; | @@ -7,6 +7,8 @@ import java.util.List; | ||
| 7 | import java.util.stream.Collectors; | 7 | import java.util.stream.Collectors; |
| 8 | 8 | ||
| 9 | import cn.hutool.core.collection.CollectionUtil; | 9 | import cn.hutool.core.collection.CollectionUtil; |
| 10 | +import com.ruoyi.common.utils.DateUtils; | ||
| 11 | +import com.ruoyi.common.utils.SecurityUtils; | ||
| 10 | import com.ruoyi.pojo.dto.RuleSchedulingDto; | 12 | import com.ruoyi.pojo.dto.RuleSchedulingDto; |
| 11 | import com.ruoyi.pojo.vo.RuleSchedulingResponseVo; | 13 | import com.ruoyi.pojo.vo.RuleSchedulingResponseVo; |
| 12 | import com.ruoyi.pojo.vo.RuleSchedulingVo; | 14 | import com.ruoyi.pojo.vo.RuleSchedulingVo; |
| @@ -62,6 +64,12 @@ public class RuleSchedulingServiceImpl implements IRuleSchedulingService { | @@ -62,6 +64,12 @@ public class RuleSchedulingServiceImpl implements IRuleSchedulingService { | ||
| 62 | @Override | 64 | @Override |
| 63 | public int insertRuleScheduling(RuleScheduling ruleScheduling) { | 65 | public int insertRuleScheduling(RuleScheduling ruleScheduling) { |
| 64 | handleNewAddScheduling(ruleScheduling); | 66 | handleNewAddScheduling(ruleScheduling); |
| 67 | + String username = SecurityUtils.getUsername(); | ||
| 68 | + ruleScheduling.setCreateBy(username); | ||
| 69 | + ruleScheduling.setUpdateBy(username); | ||
| 70 | + Date date = DateUtils.getNowDate(); | ||
| 71 | + ruleScheduling.setCreateTime(date); | ||
| 72 | + ruleScheduling.setUpdateTime(date); | ||
| 65 | return ruleSchedulingMapper.insertRuleScheduling(ruleScheduling); | 73 | return ruleSchedulingMapper.insertRuleScheduling(ruleScheduling); |
| 66 | } | 74 | } |
| 67 | 75 | ||
| @@ -85,6 +93,8 @@ public class RuleSchedulingServiceImpl implements IRuleSchedulingService { | @@ -85,6 +93,8 @@ public class RuleSchedulingServiceImpl implements IRuleSchedulingService { | ||
| 85 | @Override | 93 | @Override |
| 86 | public int updateRuleScheduling(RuleScheduling ruleScheduling) { | 94 | public int updateRuleScheduling(RuleScheduling ruleScheduling) { |
| 87 | handleNewAddScheduling(ruleScheduling); | 95 | handleNewAddScheduling(ruleScheduling); |
| 96 | + ruleScheduling.setUpdateTime(DateUtils.getNowDate()); | ||
| 97 | + ruleScheduling.setUpdateBy(SecurityUtils.getUsername()); | ||
| 88 | return ruleSchedulingMapper.updateRuleScheduling(ruleScheduling); | 98 | return ruleSchedulingMapper.updateRuleScheduling(ruleScheduling); |
| 89 | } | 99 | } |
| 90 | 100 |
ruoyi-admin/src/main/resources/application-druid-dev.yml
| @@ -99,9 +99,10 @@ spring: | @@ -99,9 +99,10 @@ spring: | ||
| 99 | # redis 配置 | 99 | # redis 配置 |
| 100 | redis: | 100 | redis: |
| 101 | # 地址 | 101 | # 地址 |
| 102 | - host: 121.41.83.61 | 102 | +# host: 121.41.83.61 |
| 103 | + host: 127.0.0.1 | ||
| 103 | database: 0 | 104 | database: 0 |
| 104 | - password: "guzijian" | 105 | +# password: "guzijian" |
| 105 | port: 6379 | 106 | port: 6379 |
| 106 | # 连接超时时间 | 107 | # 连接超时时间 |
| 107 | timeout: 10s | 108 | timeout: 10s |
ruoyi-admin/src/main/resources/application-druid-prd.yml
| @@ -96,9 +96,10 @@ spring: | @@ -96,9 +96,10 @@ spring: | ||
| 96 | # redis 配置 | 96 | # redis 配置 |
| 97 | redis: | 97 | redis: |
| 98 | # 地址 | 98 | # 地址 |
| 99 | - host: 121.41.83.61 | 99 | +# host: 121.41.83.61 |
| 100 | + host: 127.0.0.1 | ||
| 100 | database: 0 | 101 | database: 0 |
| 101 | - password: "guzijian" | 102 | + password: "@qpgj#redis" |
| 102 | port: 6379 | 103 | port: 6379 |
| 103 | # 连接超时时间 | 104 | # 连接超时时间 |
| 104 | timeout: 10s | 105 | timeout: 10s |
ruoyi-admin/src/main/resources/application.yml
| @@ -71,24 +71,24 @@ spring: | @@ -71,24 +71,24 @@ spring: | ||
| 71 | # 热部署开关 | 71 | # 热部署开关 |
| 72 | enabled: true | 72 | enabled: true |
| 73 | # redis 配置 | 73 | # redis 配置 |
| 74 | - redis: | ||
| 75 | - # 地址 | ||
| 76 | - host: 121.41.83.61 | ||
| 77 | - database: 0 | ||
| 78 | - password: "guzijian" | ||
| 79 | - port: 6379 | ||
| 80 | - # 连接超时时间 | ||
| 81 | - timeout: 10s | ||
| 82 | - lettuce: | ||
| 83 | - pool: | ||
| 84 | - # 连接池中的最小空闲连接 | ||
| 85 | - min-idle: 0 | ||
| 86 | - # 连接池中的最大空闲连接 | ||
| 87 | - max-idle: 8 | ||
| 88 | - # 连接池的最大数据库连接数 | ||
| 89 | - max-active: 8 | ||
| 90 | - # #连接池最大阻塞等待时间(使用负值表示没有限制) | ||
| 91 | - max-wait: -1ms | 74 | +# redis: |
| 75 | +# # 地址 | ||
| 76 | +# host: 127.0.0.1 | ||
| 77 | +# database: 0 | ||
| 78 | +## password: "guzijian" | ||
| 79 | +# port: 6379 | ||
| 80 | +# # 连接超时时间 | ||
| 81 | +# timeout: 10s | ||
| 82 | +# lettuce: | ||
| 83 | +# pool: | ||
| 84 | +# # 连接池中的最小空闲连接 | ||
| 85 | +# min-idle: 0 | ||
| 86 | +# # 连接池中的最大空闲连接 | ||
| 87 | +# max-idle: 8 | ||
| 88 | +# # 连接池的最大数据库连接数 | ||
| 89 | +# max-active: 8 | ||
| 90 | +# # #连接池最大阻塞等待时间(使用负值表示没有限制) | ||
| 91 | +# max-wait: -1ms | ||
| 92 | 92 | ||
| 93 | # token配置 | 93 | # token配置 |
| 94 | token: | 94 | token: |
ruoyi-admin/src/main/resources/mapper/eexception/EquipmentExceptionMapper.xml
| @@ -89,7 +89,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | @@ -89,7 +89,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 89 | <if test="jobCode != null and jobCode != ''"> and driver.job_code = #{jobCode}</if> | 89 | <if test="jobCode != null and jobCode != ''"> and driver.job_code = #{jobCode}</if> |
| 90 | <if test="exType != null "> and ex_type = #{exType}</if> | 90 | <if test="exType != null "> and ex_type = #{exType}</if> |
| 91 | <if test="id != null "> and equipment_exception.id #{id}</if> | 91 | <if test="id != null "> and equipment_exception.id #{id}</if> |
| 92 | - <if test="date != null "> and equipment_exception.create_time like concat(#{date},'%')</if> | 92 | + <if test="date != null "> |
| 93 | + and | ||
| 94 | + equipment_exception.create_time >= CONCAT(#{date}, ' 02:30:00') | ||
| 95 | + and | ||
| 96 | + equipment_exception.create_time <= CONCAT(DATE_ADD(#{date}, INTERVAL 1 DAY), ' 02:30:00') | ||
| 97 | + </if> | ||
| 93 | </where> | 98 | </where> |
| 94 | </select> | 99 | </select> |
| 95 | <select id="selectEquipmentExceptionByDeviceIdStatus" | 100 | <select id="selectEquipmentExceptionByDeviceIdStatus" |
ruoyi-admin/src/main/resources/mapper/num/RuleNumMapper.xml
| @@ -11,6 +11,10 @@ | @@ -11,6 +11,10 @@ | ||
| 11 | <result property="workDay" column="work_day"/> | 11 | <result property="workDay" column="work_day"/> |
| 12 | <result property="freeDay" column="free_day"/> | 12 | <result property="freeDay" column="free_day"/> |
| 13 | <result property="ruleWeek" column="rule_week"/> | 13 | <result property="ruleWeek" column="rule_week"/> |
| 14 | + <result property="createTime" column="create_time" /> | ||
| 15 | + <result property="updateTime" column="update_time" /> | ||
| 16 | + <result property="createBy" column="create_by" /> | ||
| 17 | + <result property="updateBy" column="update_by" /> | ||
| 14 | </resultMap> | 18 | </resultMap> |
| 15 | 19 | ||
| 16 | <resultMap type="com.ruoyi.pojo.dto.RuleNumDto" id="RuleNumDtoResult"> | 20 | <resultMap type="com.ruoyi.pojo.dto.RuleNumDto" id="RuleNumDtoResult"> |
| @@ -21,10 +25,14 @@ | @@ -21,10 +25,14 @@ | ||
| 21 | <result property="freeDay" column="free_day"/> | 25 | <result property="freeDay" column="free_day"/> |
| 22 | <result property="ruleWeek" column="rule_week"/> | 26 | <result property="ruleWeek" column="rule_week"/> |
| 23 | <result property="settingId" column="setting_id"/> | 27 | <result property="settingId" column="setting_id"/> |
| 28 | + <result property="createTime" column="create_time" /> | ||
| 29 | + <result property="updateTime" column="update_time" /> | ||
| 30 | + <result property="createBy" column="create_by" /> | ||
| 31 | + <result property="updateBy" column="update_by" /> | ||
| 24 | </resultMap> | 32 | </resultMap> |
| 25 | 33 | ||
| 26 | <sql id="selectRuleNumVo"> | 34 | <sql id="selectRuleNumVo"> |
| 27 | - select id, rule_dict_name, rule_type, work_day, free_day, rule_week | 35 | + select id, rule_dict_name, rule_type, work_day, free_day, rule_week,update_by,update_time,create_by,create_time |
| 28 | from rule_num | 36 | from rule_num |
| 29 | </sql> | 37 | </sql> |
| 30 | 38 | ||
| @@ -70,6 +78,10 @@ | @@ -70,6 +78,10 @@ | ||
| 70 | <if test="workDay != null">work_day,</if> | 78 | <if test="workDay != null">work_day,</if> |
| 71 | <if test="freeDay != null">free_day,</if> | 79 | <if test="freeDay != null">free_day,</if> |
| 72 | <if test="ruleWeek != null">rule_week,</if> | 80 | <if test="ruleWeek != null">rule_week,</if> |
| 81 | + <if test="createTime != null">create_time,</if> | ||
| 82 | + <if test="updateTime != null">update_time,</if> | ||
| 83 | + <if test="createBy != null">create_by,</if> | ||
| 84 | + <if test="updateBy != null">update_by,</if> | ||
| 73 | </trim> | 85 | </trim> |
| 74 | <trim prefix="values (" suffix=")" suffixOverrides=","> | 86 | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| 75 | <if test="ruleDictName != null">#{ruleDictName},</if> | 87 | <if test="ruleDictName != null">#{ruleDictName},</if> |
| @@ -77,6 +89,10 @@ | @@ -77,6 +89,10 @@ | ||
| 77 | <if test="workDay != null">#{workDay},</if> | 89 | <if test="workDay != null">#{workDay},</if> |
| 78 | <if test="freeDay != null">#{freeDay},</if> | 90 | <if test="freeDay != null">#{freeDay},</if> |
| 79 | <if test="ruleWeek != null">#{ruleWeek},</if> | 91 | <if test="ruleWeek != null">#{ruleWeek},</if> |
| 92 | + <if test="createTime != null">#{createTime},</if> | ||
| 93 | + <if test="updateTime != null">#{updateTime},</if> | ||
| 94 | + <if test="createBy != null">#{createBy},</if> | ||
| 95 | + <if test="updateBy != null">#{updateBy},</if> | ||
| 80 | </trim> | 96 | </trim> |
| 81 | </insert> | 97 | </insert> |
| 82 | 98 | ||
| @@ -88,6 +104,8 @@ | @@ -88,6 +104,8 @@ | ||
| 88 | <if test="workDay != null">work_day = #{workDay},</if> | 104 | <if test="workDay != null">work_day = #{workDay},</if> |
| 89 | <if test="freeDay != null">free_day = #{freeDay},</if> | 105 | <if test="freeDay != null">free_day = #{freeDay},</if> |
| 90 | <if test="ruleWeek != null">rule_week = #{ruleWeek},</if> | 106 | <if test="ruleWeek != null">rule_week = #{ruleWeek},</if> |
| 107 | + <if test="updateBy != null">update_by = #{updateBy},</if> | ||
| 108 | + <if test="updateTime != null">update_time = #{updateTime},</if> | ||
| 91 | </trim> | 109 | </trim> |
| 92 | where id = #{id} | 110 | where id = #{id} |
| 93 | </update> | 111 | </update> |
ruoyi-admin/src/main/resources/mapper/scheduling/RuleSchedulingMapper.xml
| @@ -23,6 +23,10 @@ | @@ -23,6 +23,10 @@ | ||
| 23 | <result property="secondSignDayTomorrow" column="second_sign_day_tomorrow" /> | 23 | <result property="secondSignDayTomorrow" column="second_sign_day_tomorrow" /> |
| 24 | <result property="settingId" column="setting_id" /> | 24 | <result property="settingId" column="setting_id" /> |
| 25 | <result property="sort" column="sort" /> | 25 | <result property="sort" column="sort" /> |
| 26 | + <result property="createTime" column="create_time" /> | ||
| 27 | + <result property="updateTime" column="update_time" /> | ||
| 28 | + <result property="createBy" column="create_by" /> | ||
| 29 | + <result property="updateBy" column="update_by" /> | ||
| 26 | </resultMap> | 30 | </resultMap> |
| 27 | 31 | ||
| 28 | <resultMap type="RuleScheduling" id="RuleSchedulingResult"> | 32 | <resultMap type="RuleScheduling" id="RuleSchedulingResult"> |
| @@ -42,10 +46,14 @@ | @@ -42,10 +46,14 @@ | ||
| 42 | <result property="secondQuittingSignInTime" column="second_quitting_sign_in_time" /> | 46 | <result property="secondQuittingSignInTime" column="second_quitting_sign_in_time" /> |
| 43 | <result property="secondSignInQuittingRange" column="second_sign_in_quitting_range" /> | 47 | <result property="secondSignInQuittingRange" column="second_sign_in_quitting_range" /> |
| 44 | <result property="secondSignDayTomorrow" column="second_sign_day_tomorrow" /> | 48 | <result property="secondSignDayTomorrow" column="second_sign_day_tomorrow" /> |
| 49 | + <result property="createTime" column="create_time" /> | ||
| 50 | + <result property="updateTime" column="update_time" /> | ||
| 51 | + <result property="createBy" column="create_by" /> | ||
| 52 | + <result property="updateBy" column="update_by" /> | ||
| 45 | </resultMap> | 53 | </resultMap> |
| 46 | 54 | ||
| 47 | <sql id="selectRuleSchedulingVo"> | 55 | <sql id="selectRuleSchedulingVo"> |
| 48 | - select id, rule_name, working_hour_plan, working_hour_type, first_work_sign_in_time, first_sign_in_working_range, first_quitting_sign_in_time, first_sign_in_day_tomorrow, first_sign_in_quitting_range, sign_in_time_out_range, second_flag, second_work_sign_in_time, second_sign_in_working_range, second_quitting_sign_in_time, second_sign_in_quitting_range, second_sign_day_tomorrow from rule_scheduling | 56 | + select id, rule_name, working_hour_plan, working_hour_type, first_work_sign_in_time, first_sign_in_working_range, first_quitting_sign_in_time, first_sign_in_day_tomorrow, first_sign_in_quitting_range, sign_in_time_out_range, second_flag, second_work_sign_in_time, second_sign_in_working_range, second_quitting_sign_in_time, second_sign_in_quitting_range, second_sign_day_tomorrow,update_by,update_time,create_by,create_time from rule_scheduling |
| 49 | </sql> | 57 | </sql> |
| 50 | 58 | ||
| 51 | <select id="selectRuleSchedulingList" parameterType="RuleScheduling" resultMap="RuleSchedulingResult"> | 59 | <select id="selectRuleSchedulingList" parameterType="RuleScheduling" resultMap="RuleSchedulingResult"> |
| @@ -110,6 +118,10 @@ | @@ -110,6 +118,10 @@ | ||
| 110 | <if test="secondQuittingSignInTime != null">second_quitting_sign_in_time,</if> | 118 | <if test="secondQuittingSignInTime != null">second_quitting_sign_in_time,</if> |
| 111 | <if test="secondSignInQuittingRange != null">second_sign_in_quitting_range,</if> | 119 | <if test="secondSignInQuittingRange != null">second_sign_in_quitting_range,</if> |
| 112 | <if test="secondSignDayTomorrow != null">second_sign_day_tomorrow,</if> | 120 | <if test="secondSignDayTomorrow != null">second_sign_day_tomorrow,</if> |
| 121 | + <if test="updateTime != null">update_time,</if> | ||
| 122 | + <if test="createTime != null">create_time,</if> | ||
| 123 | + <if test="createBy != null">create_by,</if> | ||
| 124 | + <if test="updateBy != null">update_by,</if> | ||
| 113 | </trim> | 125 | </trim> |
| 114 | <trim prefix="values (" suffix=")" suffixOverrides=","> | 126 | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| 115 | <if test="ruleName != null and ruleName != ''">#{ruleName},</if> | 127 | <if test="ruleName != null and ruleName != ''">#{ruleName},</if> |
| @@ -127,6 +139,10 @@ | @@ -127,6 +139,10 @@ | ||
| 127 | <if test="secondQuittingSignInTime != null">#{secondQuittingSignInTime},</if> | 139 | <if test="secondQuittingSignInTime != null">#{secondQuittingSignInTime},</if> |
| 128 | <if test="secondSignInQuittingRange != null">#{secondSignInQuittingRange},</if> | 140 | <if test="secondSignInQuittingRange != null">#{secondSignInQuittingRange},</if> |
| 129 | <if test="secondSignDayTomorrow != null">#{secondSignDayTomorrow},</if> | 141 | <if test="secondSignDayTomorrow != null">#{secondSignDayTomorrow},</if> |
| 142 | + <if test="updateTime != null">#{updateTime},</if> | ||
| 143 | + <if test="createTime != null">#{createTime},</if> | ||
| 144 | + <if test="createBy != null">#{createBy},</if> | ||
| 145 | + <if test="updateBy != null">#{updateBy},</if> | ||
| 130 | </trim> | 146 | </trim> |
| 131 | </insert> | 147 | </insert> |
| 132 | 148 | ||
| @@ -148,6 +164,8 @@ | @@ -148,6 +164,8 @@ | ||
| 148 | <if test="secondQuittingSignInTime != null">second_quitting_sign_in_time = #{secondQuittingSignInTime},</if> | 164 | <if test="secondQuittingSignInTime != null">second_quitting_sign_in_time = #{secondQuittingSignInTime},</if> |
| 149 | <if test="secondSignInQuittingRange != null">second_sign_in_quitting_range = #{secondSignInQuittingRange},</if> | 165 | <if test="secondSignInQuittingRange != null">second_sign_in_quitting_range = #{secondSignInQuittingRange},</if> |
| 150 | <if test="secondSignDayTomorrow != null">second_sign_day_tomorrow = #{secondSignDayTomorrow},</if> | 166 | <if test="secondSignDayTomorrow != null">second_sign_day_tomorrow = #{secondSignDayTomorrow},</if> |
| 167 | + <if test="updateBy != null">update_by = #{updateBy},</if> | ||
| 168 | + <if test="updateTime != null">update_time = #{updateTime},</if> | ||
| 151 | </trim> | 169 | </trim> |
| 152 | where id = #{id} | 170 | where id = #{id} |
| 153 | </update> | 171 | </update> |