Commit 54f9339e04338887d4984368cea786491efa0858

Authored by guzijian
1 parent ecc1fd1f

fix: change sort rule for exception

ruoyi-admin/src/main/java/com/ruoyi/eexception/controller/EquipmentExceptionController.java
@@ -41,7 +41,7 @@ public class EquipmentExceptionController extends BaseController @@ -41,7 +41,7 @@ public class EquipmentExceptionController extends BaseController
41 /** 41 /**
42 * 查询设备异常记录列表 42 * 查询设备异常记录列表
43 */ 43 */
44 - @PreAuthorize("@ss.hasPermi('eexception:eexception:list')") 44 +// @PreAuthorize("@ss.hasPermi('eexception:eexception:list')")
45 @GetMapping("/list") 45 @GetMapping("/list")
46 @ApiOperation("查询设备异常记录列表") 46 @ApiOperation("查询设备异常记录列表")
47 public TableDataInfo list(EquipmentException equipmentException) 47 public TableDataInfo list(EquipmentException equipmentException)
@@ -54,7 +54,7 @@ public class EquipmentExceptionController extends BaseController @@ -54,7 +54,7 @@ public class EquipmentExceptionController extends BaseController
54 /** 54 /**
55 * 导出设备异常记录列表 55 * 导出设备异常记录列表
56 */ 56 */
57 - @PreAuthorize("@ss.hasPermi('eexception:eexception:export')") 57 +// @PreAuthorize("@ss.hasPermi('eexception:eexception:export')")
58 @Log(title = "设备异常记录", businessType = BusinessType.EXPORT) 58 @Log(title = "设备异常记录", businessType = BusinessType.EXPORT)
59 @PostMapping("/export") 59 @PostMapping("/export")
60 @ApiOperation("导出设备异常记录列表") 60 @ApiOperation("导出设备异常记录列表")
@@ -68,7 +68,7 @@ public class EquipmentExceptionController extends BaseController @@ -68,7 +68,7 @@ public class EquipmentExceptionController extends BaseController
68 /** 68 /**
69 * 获取设备异常记录详细信息 69 * 获取设备异常记录详细信息
70 */ 70 */
71 - @PreAuthorize("@ss.hasPermi('eexception:eexception:query')") 71 +// @PreAuthorize("@ss.hasPermi('eexception:eexception:query')")
72 @GetMapping(value = "/{id}") 72 @GetMapping(value = "/{id}")
73 @ApiOperation("获取设备异常记录详细信息") 73 @ApiOperation("获取设备异常记录详细信息")
74 public AjaxResult getInfo(@PathVariable("id") Long id) 74 public AjaxResult getInfo(@PathVariable("id") Long id)
@@ -79,7 +79,7 @@ public class EquipmentExceptionController extends BaseController @@ -79,7 +79,7 @@ public class EquipmentExceptionController extends BaseController
79 /** 79 /**
80 * 新增设备异常记录 80 * 新增设备异常记录
81 */ 81 */
82 - @PreAuthorize("@ss.hasPermi('eexception:eexception:add')") 82 +// @PreAuthorize("@ss.hasPermi('eexception:eexception:add')")
83 @Log(title = "设备异常记录", businessType = BusinessType.INSERT) 83 @Log(title = "设备异常记录", businessType = BusinessType.INSERT)
84 @PostMapping 84 @PostMapping
85 @ApiOperation("新增设备异常记录") 85 @ApiOperation("新增设备异常记录")
@@ -91,7 +91,7 @@ public class EquipmentExceptionController extends BaseController @@ -91,7 +91,7 @@ public class EquipmentExceptionController extends BaseController
91 /** 91 /**
92 * 修改设备异常记录 92 * 修改设备异常记录
93 */ 93 */
94 - @PreAuthorize("@ss.hasPermi('eexception:eexception:edit')") 94 +// @PreAuthorize("@ss.hasPermi('eexception:eexception:edit')")
95 @Log(title = "设备异常记录", businessType = BusinessType.UPDATE) 95 @Log(title = "设备异常记录", businessType = BusinessType.UPDATE)
96 @PutMapping 96 @PutMapping
97 @ApiOperation("修改设备异常记录") 97 @ApiOperation("修改设备异常记录")
@@ -103,7 +103,7 @@ public class EquipmentExceptionController extends BaseController @@ -103,7 +103,7 @@ public class EquipmentExceptionController extends BaseController
103 /** 103 /**
104 * 删除设备异常记录 104 * 删除设备异常记录
105 */ 105 */
106 - @PreAuthorize("@ss.hasPermi('eexception:eexception:remove')") 106 +// @PreAuthorize("@ss.hasPermi('eexception:eexception:remove')")
107 @Log(title = "设备异常记录", businessType = BusinessType.DELETE) 107 @Log(title = "设备异常记录", businessType = BusinessType.DELETE)
108 @DeleteMapping("/{ids}") 108 @DeleteMapping("/{ids}")
109 @ApiOperation("删除设备异常记录") 109 @ApiOperation("删除设备异常记录")
ruoyi-admin/src/main/java/com/ruoyi/equipment/controller/EquipmentController.java
@@ -37,7 +37,7 @@ public class EquipmentController extends BaseController @@ -37,7 +37,7 @@ public class EquipmentController extends BaseController
37 /** 37 /**
38 * 查询设备信息列表 38 * 查询设备信息列表
39 */ 39 */
40 - @PreAuthorize("@ss.hasPermi('equipment:equipment:list')") 40 +// @PreAuthorize("@ss.hasPermi('equipment:equipment:list')")
41 @GetMapping("/list") 41 @GetMapping("/list")
42 public TableDataInfo list(Equipment equipment) 42 public TableDataInfo list(Equipment equipment)
43 { 43 {
@@ -49,7 +49,7 @@ public class EquipmentController extends BaseController @@ -49,7 +49,7 @@ public class EquipmentController extends BaseController
49 /** 49 /**
50 * 导出设备信息列表 50 * 导出设备信息列表
51 */ 51 */
52 - @PreAuthorize("@ss.hasPermi('equipment:equipment:export')") 52 +// @PreAuthorize("@ss.hasPermi('equipment:equipment:export')")
53 @Log(title = "设备信息", businessType = BusinessType.EXPORT) 53 @Log(title = "设备信息", businessType = BusinessType.EXPORT)
54 @PostMapping("/export") 54 @PostMapping("/export")
55 public void export(HttpServletResponse response, Equipment equipment) 55 public void export(HttpServletResponse response, Equipment equipment)
@@ -62,7 +62,7 @@ public class EquipmentController extends BaseController @@ -62,7 +62,7 @@ public class EquipmentController extends BaseController
62 /** 62 /**
63 * 获取设备信息详细信息 63 * 获取设备信息详细信息
64 */ 64 */
65 - @PreAuthorize("@ss.hasPermi('equipment:equipment:query')") 65 +// @PreAuthorize("@ss.hasPermi('equipment:equipment:query')")
66 @GetMapping(value = "/{id}") 66 @GetMapping(value = "/{id}")
67 public AjaxResult getInfo(@PathVariable("id") Long id) 67 public AjaxResult getInfo(@PathVariable("id") Long id)
68 { 68 {
@@ -72,7 +72,7 @@ public class EquipmentController extends BaseController @@ -72,7 +72,7 @@ public class EquipmentController extends BaseController
72 /** 72 /**
73 * 新增设备信息 73 * 新增设备信息
74 */ 74 */
75 - @PreAuthorize("@ss.hasPermi('equipment:equipment:add')") 75 +// @PreAuthorize("@ss.hasPermi('equipment:equipment:add')")
76 @Log(title = "设备信息", businessType = BusinessType.INSERT) 76 @Log(title = "设备信息", businessType = BusinessType.INSERT)
77 @PostMapping 77 @PostMapping
78 public AjaxResult add(@RequestBody Equipment equipment) 78 public AjaxResult add(@RequestBody Equipment equipment)
@@ -83,7 +83,7 @@ public class EquipmentController extends BaseController @@ -83,7 +83,7 @@ public class EquipmentController extends BaseController
83 /** 83 /**
84 * 修改设备信息 84 * 修改设备信息
85 */ 85 */
86 - @PreAuthorize("@ss.hasPermi('equipment:equipment:edit')") 86 +// @PreAuthorize("@ss.hasPermi('equipment:equipment:edit')")
87 @Log(title = "设备信息", businessType = BusinessType.UPDATE) 87 @Log(title = "设备信息", businessType = BusinessType.UPDATE)
88 @PutMapping 88 @PutMapping
89 public AjaxResult edit(@RequestBody Equipment equipment) 89 public AjaxResult edit(@RequestBody Equipment equipment)
@@ -94,7 +94,7 @@ public class EquipmentController extends BaseController @@ -94,7 +94,7 @@ public class EquipmentController extends BaseController
94 /** 94 /**
95 * 删除设备信息 95 * 删除设备信息
96 */ 96 */
97 - @PreAuthorize("@ss.hasPermi('equipment:equipment:remove')") 97 +// @PreAuthorize("@ss.hasPermi('equipment:equipment:remove')")
98 @Log(title = "设备信息", businessType = BusinessType.DELETE) 98 @Log(title = "设备信息", businessType = BusinessType.DELETE)
99 @DeleteMapping("/{ids}") 99 @DeleteMapping("/{ids}")
100 public AjaxResult remove(@PathVariable Long[] ids) 100 public AjaxResult remove(@PathVariable Long[] ids)
ruoyi-admin/src/main/resources/mapper/eexception/EquipmentExceptionMapper.xml
@@ -28,6 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" @@ -28,6 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
28 <if test="image != null and image != ''"> and image = #{image}</if> 28 <if test="image != null and image != ''"> and image = #{image}</if>
29 <if test="status != null "> and status = #{status}</if> 29 <if test="status != null "> and status = #{status}</if>
30 </where> 30 </where>
  31 + order by id desc
31 </select> 32 </select>
32 33
33 <select id="selectEquipmentExceptionById" parameterType="Long" resultMap="EquipmentExceptionResult"> 34 <select id="selectEquipmentExceptionById" parameterType="Long" resultMap="EquipmentExceptionResult">
ruoyi-admin/src/main/resources/mapper/equipment/EquipmentMapper.xml
@@ -35,6 +35,7 @@ PUBLIC &quot;-//mybatis.org//DTD Mapper 3.0//EN&quot; @@ -35,6 +35,7 @@ PUBLIC &quot;-//mybatis.org//DTD Mapper 3.0//EN&quot;
35 <if test="image != null and image != ''"> and image = #{image}</if> 35 <if test="image != null and image != ''"> and image = #{image}</if>
36 <if test="deviceId != null and deviceId != ''"> and device_id = #{deviceId}</if> 36 <if test="deviceId != null and deviceId != ''"> and device_id = #{deviceId}</if>
37 </where> 37 </where>
  38 + order by id desc
38 </select> 39 </select>
39 40
40 <select id="selectEquipmentById" parameterType="Long" resultMap="EquipmentResult"> 41 <select id="selectEquipmentById" parameterType="Long" resultMap="EquipmentResult">
ruoyi-admin/src/main/resources/mapper/in/SignInMapper.xml
@@ -36,6 +36,7 @@ PUBLIC &quot;-//mybatis.org//DTD Mapper 3.0//EN&quot; @@ -36,6 +36,7 @@ PUBLIC &quot;-//mybatis.org//DTD Mapper 3.0//EN&quot;
36 <if test="type != null "> and type = #{type}</if> 36 <if test="type != null "> and type = #{type}</if>
37 <if test="alcoholIntake != null "> and alcohol_intake = #{alcoholIntake}</if> 37 <if test="alcoholIntake != null "> and alcohol_intake = #{alcoholIntake}</if>
38 </where> 38 </where>
  39 + order by id desc
39 </select> 40 </select>
40 41
41 <select id="selectSignInById" parameterType="Long" resultMap="SignInResult"> 42 <select id="selectSignInById" parameterType="Long" resultMap="SignInResult">