diff --git a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/appointmentrecord/controller/AppointmentRecordController.java b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/appointmentrecord/controller/AppointmentRecordController.java index d7da315..8f60bbb 100644 --- a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/appointmentrecord/controller/AppointmentRecordController.java +++ b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/appointmentrecord/controller/AppointmentRecordController.java @@ -116,6 +116,34 @@ public class AppointmentRecordController extends JeecgController> queryPageList2(AppointmentRecord appointmentRecord, + @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, + @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, + HttpServletRequest req) { + //LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); + // 自定义查询规则 + Map customeRuleMap = new HashMap<>(); + // 自定义多选的查询规则为:LIKE_WITH_OR + customeRuleMap.put("status", QueryRuleEnum.LIKE_WITH_OR); + QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(appointmentRecord, req.getParameterMap(),customeRuleMap); + //queryWrapper.eq("affiliated_unit",loginUser.getOrgId()); + Page page = new Page(pageNo, pageSize); + IPage pageList = appointmentRecordService.page(page, queryWrapper); + return Result.OK(pageList); + } + /** * 添加 * diff --git a/jeecgboot-vue3/src/views/appointmentrecord/AppointmentRecord.api.ts b/jeecgboot-vue3/src/views/appointmentrecord/AppointmentRecord.api.ts index 2efa0db..5ed5693 100644 --- a/jeecgboot-vue3/src/views/appointmentrecord/AppointmentRecord.api.ts +++ b/jeecgboot-vue3/src/views/appointmentrecord/AppointmentRecord.api.ts @@ -6,6 +6,7 @@ const { createConfirm } = useMessage(); enum Api { list = '/appointmentrecord/appointmentRecord/list', list1 = '/appointmentrecord/appointmentRecord/list1', + list2 = '/appointmentrecord/appointmentRecord/list2', save='/appointmentrecord/appointmentRecord/add', edit='/appointmentrecord/appointmentRecord/edit', edit1='/appointmentrecord/appointmentRecord/edit1', @@ -53,6 +54,8 @@ export const list = (params) => defHttp.get({ url: Api.list, params }); */ export const list1 = (params) => defHttp.get({ url: Api.list1, params }); +export const list2 = (params) => defHttp.get({ url: Api.list2, params }); + /** * 删除单个 * @param params diff --git a/jeecgboot-vue3/src/views/appointmentrecord/AppointmentRecordList2.vue b/jeecgboot-vue3/src/views/appointmentrecord/AppointmentRecordList2.vue new file mode 100644 index 0000000..a1f800b --- /dev/null +++ b/jeecgboot-vue3/src/views/appointmentrecord/AppointmentRecordList2.vue @@ -0,0 +1,302 @@ + + + + +