时间:2022-07-29 09:24:33 | 栏目:JAVA代码 | 点击:次
@ApiOperation("分页查询") @GetMapping(value = "/list") public ActionResult<Map<String, Object>> list(@RequestParam Map<String, Object> params) { List<String> list = Arrays.asList(new String[]{"create_time"}); return new ActionResult(StatusCode.SUCCESS, iUmsMemberService.selectPage(new Query<>(params), new EntityWrapper<UmsMember>().eq("deleted", 0).orderDesc(list))); }
等同于
SELECT id AS id,member_level_id AS memberLevelId,username, FROM ums_member WHERE (deleted = 0) ORDER BY create_time DESC LIMIT 0,5
/** * 查询sql * @param sql * @return */ Object aa(@Param(value = "sql") String sql);
<select id="aa" resultType="Object"> ${sql} </select>