org.jeecg.common.aspect.annotation.AutoLog Java Examples
The following examples show how to use
org.jeecg.common.aspect.annotation.AutoLog.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: SysPositionController.java From jeecg-cloud with Apache License 2.0 | 6 votes |
/** * 分页列表查询 * * @param sysPosition * @param pageNo * @param pageSize * @param req * @return */ @AutoLog(value = "职务表-分页列表查询") @ApiOperation(value = "职务表-分页列表查询", notes = "职务表-分页列表查询") @GetMapping(value = "/list") public Result<IPage<SysPosition>> queryPageList(SysPosition sysPosition, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, HttpServletRequest req) { Result<IPage<SysPosition>> result = new Result<IPage<SysPosition>>(); QueryWrapper<SysPosition> queryWrapper = QueryGenerator.initQueryWrapper(sysPosition, req.getParameterMap()); Page<SysPosition> page = new Page<SysPosition>(pageNo, pageSize); IPage<SysPosition> pageList = sysPositionService.page(page, queryWrapper); result.setSuccess(true); result.setResult(pageList); return result; }
Example #2
Source File: SysPositionController.java From teaching with Apache License 2.0 | 6 votes |
/** * 分页列表查询 * * @param sysPosition * @param pageNo * @param pageSize * @param req * @return */ @AutoLog(value = "职务表-分页列表查询") @ApiOperation(value = "职务表-分页列表查询", notes = "职务表-分页列表查询") @GetMapping(value = "/list") public Result<IPage<SysPosition>> queryPageList(SysPosition sysPosition, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, HttpServletRequest req) { Result<IPage<SysPosition>> result = new Result<IPage<SysPosition>>(); QueryWrapper<SysPosition> queryWrapper = QueryGenerator.initQueryWrapper(sysPosition, req.getParameterMap()); Page<SysPosition> page = new Page<SysPosition>(pageNo, pageSize); IPage<SysPosition> pageList = sysPositionService.page(page, queryWrapper); result.setSuccess(true); result.setResult(pageList); return result; }
Example #3
Source File: TeachingWorkController.java From teaching with Apache License 2.0 | 6 votes |
/** * 分页列表查询 * * @param studentWorkModel * @param pageNo * @param pageSize * @param req * @return */ @AutoLog(value = "作业列表-分页列表查询") @ApiOperation(value="作业列表-分页列表查询", notes="作业列表-分页列表查询") @GetMapping(value = "/list") @PermissionData(pageComponent = "teaching/TeachingWorkList") public Result<?> queryPageList(StudentWorkModel studentWorkModel, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) { // QueryWrapper<TeachingWork> queryWrapper = QueryGenerator.initQueryWrapper(teachingWork, req.getParameterMap()); Page<TeachingWork> page = new Page<TeachingWork>(pageNo, pageSize); QueryWrapper<StudentWorkModel> queryWrapper = new QueryWrapper<>(); queryWrapper.eq(null != studentWorkModel.getUsername(), "teaching_work.create_by", studentWorkModel.getUsername()) .like(null != studentWorkModel.getWorkName(), "work_name", studentWorkModel.getWorkName()) .like(null != studentWorkModel.getRealname(), "realname", studentWorkModel.getRealname()); QueryGenerator.installMplus(queryWrapper, studentWorkModel, req.getParameterMap()); //获取时间参数 Map<String, String[]> param = req.getParameterMap(); String updateTime_begin = param.containsKey("teaching_work.updateTime_begin")?param.get("teaching_work.updateTime_begin")[0]:null; String updateTime_end = param.containsKey("teaching_work.updateTime_end")?param.get("teaching_work.updateTime_end")[0]:null; queryWrapper.ge(null != updateTime_begin, "teaching_work.create_time", updateTime_begin). le(null != updateTime_end, "teaching_work.create_time",updateTime_end); IPage<StudentWorkModel> pageList = teachingWorkService.listWorkModel(new Page<>(pageNo, pageSize), queryWrapper); return Result.ok(pageList); }
Example #4
Source File: SysPositionController.java From jeecg-boot-with-activiti with MIT License | 6 votes |
/** * 编辑 * * @param sysPosition * @return */ @AutoLog(value = "职务表-编辑") @ApiOperation(value = "职务表-编辑", notes = "职务表-编辑") @PutMapping(value = "/edit") public Result<SysPosition> edit(@RequestBody SysPosition sysPosition) { Result<SysPosition> result = new Result<SysPosition>(); SysPosition sysPositionEntity = sysPositionService.getById(sysPosition.getId()); if (sysPositionEntity == null) { result.error500("未找到对应实体"); } else { boolean ok = sysPositionService.updateById(sysPosition); //TODO 返回false说明什么? if (ok) { result.success("修改成功!"); } } return result; }
Example #5
Source File: SysPositionController.java From jeecg-boot-with-activiti with MIT License | 6 votes |
/** * 分页列表查询 * * @param sysPosition * @param pageNo * @param pageSize * @param req * @return */ @AutoLog(value = "职务表-分页列表查询") @ApiOperation(value = "职务表-分页列表查询", notes = "职务表-分页列表查询") @GetMapping(value = "/list") public Result<IPage<SysPosition>> queryPageList(SysPosition sysPosition, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, HttpServletRequest req) { Result<IPage<SysPosition>> result = new Result<IPage<SysPosition>>(); QueryWrapper<SysPosition> queryWrapper = QueryGenerator.initQueryWrapper(sysPosition, req.getParameterMap()); Page<SysPosition> page = new Page<SysPosition>(pageNo, pageSize); IPage<SysPosition> pageList = sysPositionService.page(page, queryWrapper); result.setSuccess(true); result.setResult(pageList); return result; }
Example #6
Source File: SysDataSourceController.java From teaching with Apache License 2.0 | 5 votes |
/** * 分页列表查询 * * @param sysDataSource * @param pageNo * @param pageSize * @param req * @return */ @AutoLog(value = "多数据源管理-分页列表查询") @ApiOperation(value = "多数据源管理-分页列表查询", notes = "多数据源管理-分页列表查询") @GetMapping(value = "/list") public Result<?> queryPageList( SysDataSource sysDataSource, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, HttpServletRequest req ) { QueryWrapper<SysDataSource> queryWrapper = QueryGenerator.initQueryWrapper(sysDataSource, req.getParameterMap()); Page<SysDataSource> page = new Page<>(pageNo, pageSize); IPage<SysDataSource> pageList = sysDataSourceService.page(page, queryWrapper); return Result.ok(pageList); }
Example #7
Source File: TeachingWorkController.java From teaching with Apache License 2.0 | 5 votes |
@AutoLog(value = "学生作业详情") @ApiOperation(value = "") @GetMapping("/studentWorkInfo") public Result<StudentWorkModel> studentWorkInfo(@RequestParam(name = "workId") String workId){ Result<StudentWorkModel> result = new Result<StudentWorkModel>(); StudentWorkModel teachingWork = teachingWorkService.studentWorkInfo(workId); if (teachingWork == null) { result.error500("未找到对作业"); } else { result.setResult(teachingWork); result.setSuccess(true); } return result; }
Example #8
Source File: TeachingWorkController.java From teaching with Apache License 2.0 | 5 votes |
/** * 通过id删除 * * @param id * @return */ @AutoLog(value = "作业列表-通过id删除") @ApiOperation(value="作业列表-通过id删除", notes="作业列表-通过id删除") @DeleteMapping(value = "/delete") public Result<?> delete(@RequestParam(name="id",required=true) String id) { teachingWorkService.delMain(id); return Result.ok("删除成功!"); }
Example #9
Source File: TeachingWorkController.java From teaching with Apache License 2.0 | 5 votes |
/** * 批量删除 * * @param ids * @return */ @AutoLog(value = "作业列表-批量删除") @ApiOperation(value="作业列表-批量删除", notes="作业列表-批量删除") @DeleteMapping(value = "/deleteBatch") public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) { this.teachingWorkService.delBatchMain(Arrays.asList(ids.split(","))); return Result.ok("批量删除成功!"); }
Example #10
Source File: SysDataSourceController.java From teaching with Apache License 2.0 | 5 votes |
/** * 通过id删除 * * @param id * @return */ @AutoLog(value = "多数据源管理-通过id删除") @ApiOperation(value = "多数据源管理-通过id删除", notes = "多数据源管理-通过id删除") @DeleteMapping(value = "/delete") public Result<?> delete(@RequestParam(name = "id") String id) { sysDataSourceService.removeById(id); DataSourceCachePool.removeCacheById(id); return Result.ok("删除成功!"); }
Example #11
Source File: SysCheckRuleController.java From teaching with Apache License 2.0 | 5 votes |
/** * 添加 * * @param sysCheckRule * @return */ @AutoLog(value = "编码校验规则-添加") @ApiOperation(value = "编码校验规则-添加", notes = "编码校验规则-添加") @PostMapping(value = "/add") public Result add(@RequestBody SysCheckRule sysCheckRule) { sysCheckRuleService.save(sysCheckRule); return Result.ok("添加成功!"); }
Example #12
Source File: TeachingCourseUnitController.java From teaching with Apache License 2.0 | 5 votes |
/** * 通过id删除 * * @param id * @return */ @AutoLog(value = "课程单元-通过id删除") @ApiOperation(value="课程单元-通过id删除", notes="课程单元-通过id删除") @DeleteMapping(value = "/delete") public Result<?> delete(@RequestParam(name="id",required=true) String id) { teachingCourseUnitService.removeById(id); return Result.ok("删除成功!"); }
Example #13
Source File: SysDepartRoleController.java From teaching with Apache License 2.0 | 5 votes |
/** * 通过id删除 * * @param id * @return */ @AutoLog(value = "部门角色-通过id删除") @ApiOperation(value="部门角色-通过id删除", notes="部门角色-通过id删除") @DeleteMapping(value = "/delete") public Result<?> delete(@RequestParam(name="id",required=true) String id) { sysDepartRoleService.removeById(id); return Result.ok("删除成功!"); }
Example #14
Source File: TeachingCourseUnitController.java From teaching with Apache License 2.0 | 5 votes |
/** * 通过id查询 * * @param id * @return */ @AutoLog(value = "课程单元-通过id查询") @ApiOperation(value="课程单元-通过id查询", notes="课程单元-通过id查询") @GetMapping(value = "/queryById") public Result<?> queryById(@RequestParam(name="id",required=true) String id) { TeachingCourseUnit teachingCourseUnit = teachingCourseUnitService.getById(id); if(teachingCourseUnit==null) { return Result.error("未找到对应数据"); } return Result.ok(teachingCourseUnit); }
Example #15
Source File: SysDepartRoleController.java From teaching with Apache License 2.0 | 5 votes |
/** * 编辑 * * @param sysDepartRole * @return */ @AutoLog(value = "部门角色-编辑") @ApiOperation(value="部门角色-编辑", notes="部门角色-编辑") @PutMapping(value = "/edit") public Result<?> edit(@RequestBody SysDepartRole sysDepartRole) { sysDepartRoleService.updateById(sysDepartRole); return Result.ok("编辑成功!"); }
Example #16
Source File: SysDataSourceController.java From teaching with Apache License 2.0 | 5 votes |
/** * 批量删除 * * @param ids * @return */ @AutoLog(value = "多数据源管理-批量删除") @ApiOperation(value = "多数据源管理-批量删除", notes = "多数据源管理-批量删除") @DeleteMapping(value = "/deleteBatch") public Result<?> deleteBatch(@RequestParam(name = "ids") String ids) { List<String> idList = Arrays.asList(ids.split(",")); this.sysDataSourceService.removeByIds(idList); idList.forEach(DataSourceCachePool::removeCacheById); return Result.ok("批量删除成功!"); }
Example #17
Source File: SysCheckRuleController.java From teaching with Apache License 2.0 | 5 votes |
/** * 通过id查询 * * @param id * @return */ @AutoLog(value = "编码校验规则-通过id查询") @ApiOperation(value = "编码校验规则-通过id查询", notes = "编码校验规则-通过id查询") @GetMapping(value = "/queryById") public Result queryById(@RequestParam(name = "id", required = true) String id) { SysCheckRule sysCheckRule = sysCheckRuleService.getById(id); return Result.ok(sysCheckRule); }
Example #18
Source File: SysFileController.java From teaching with Apache License 2.0 | 5 votes |
/** * 编辑 * * @param sysFile * @return */ @AutoLog(value = "文件管理-编辑") @ApiOperation(value="文件管理-编辑", notes="文件管理-编辑") @PutMapping(value = "/edit") public Result<?> edit(@RequestBody SysFile sysFile) { sysFileService.updateById(sysFile); return Result.ok("编辑成功!"); }
Example #19
Source File: SysDataSourceController.java From teaching with Apache License 2.0 | 5 votes |
/** * 添加 * * @param sysDataSource * @return */ @AutoLog(value = "多数据源管理-添加") @ApiOperation(value = "多数据源管理-添加", notes = "多数据源管理-添加") @PostMapping(value = "/add") public Result<?> add(@RequestBody SysDataSource sysDataSource) { sysDataSourceService.save(sysDataSource); return Result.ok("添加成功!"); }
Example #20
Source File: SysFileController.java From teaching with Apache License 2.0 | 5 votes |
/** * 批量删除 * * @param ids * @return */ @AutoLog(value = "文件管理-批量删除") @ApiOperation(value="文件管理-批量删除", notes="文件管理-批量删除") @DeleteMapping(value = "/deleteBatch") public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) { this.sysFileService.removeByIds(Arrays.asList(ids.split(","))); return Result.ok("批量删除成功!"); }
Example #21
Source File: SysFillRuleController.java From teaching with Apache License 2.0 | 5 votes |
/** * 编辑 * * @param sysFillRule * @return */ @AutoLog(value = "填值规则-编辑") @ApiOperation(value = "填值规则-编辑", notes = "填值规则-编辑") @PutMapping(value = "/edit") public Result<?> edit(@RequestBody SysFillRule sysFillRule) { sysFillRuleService.updateById(sysFillRule); return Result.ok("编辑成功!"); }
Example #22
Source File: TeachingWorkController.java From teaching with Apache License 2.0 | 5 votes |
/** * 我的作业分页列表查询 * * @param teachingWork * @param pageNo * @param pageSize * @param req * @return */ @AutoLog(value = "我的作业-分页列表查询") @ApiOperation(value = "我的作业-分页列表查询", notes = "我的作业-分页列表查询") @GetMapping(value = "/mine") public Result<?> mine(StudentWorkModel teachingWork, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageSize", defaultValue = "999") Integer pageSize, HttpServletRequest req) { teachingWork.setUserId(getCurrentUser().getId()); Result<IPage<StudentWorkModel>> result = new Result<IPage<StudentWorkModel>>(); QueryWrapper<StudentWorkModel> queryWrapper = QueryGenerator.initQueryWrapper(teachingWork, req.getParameterMap()); // Page<TeachingWork> page = new Page<TeachingWork>(pageNo, pageSize); IPage<StudentWorkModel> pageList = teachingWorkService.listWorkModel(new Page<>(pageNo, pageSize), queryWrapper); return Result.ok(pageList); }
Example #23
Source File: SysFillRuleController.java From teaching with Apache License 2.0 | 5 votes |
/** * 批量删除 * * @param ids * @return */ @AutoLog(value = "填值规则-批量删除") @ApiOperation(value = "填值规则-批量删除", notes = "填值规则-批量删除") @DeleteMapping(value = "/deleteBatch") public Result<?> deleteBatch(@RequestParam(name = "ids", required = true) String ids) { this.sysFillRuleService.removeByIds(Arrays.asList(ids.split(","))); return Result.ok("批量删除成功!"); }
Example #24
Source File: TeachingCourseController.java From teaching with Apache License 2.0 | 5 votes |
/** * 批量删除 * * @param ids * @return */ @AutoLog(value = "课程-批量删除") @ApiOperation(value="课程-批量删除", notes="课程-批量删除") @DeleteMapping(value = "/deleteBatch") public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) { this.teachingCourseService.removeByIds(Arrays.asList(ids.split(","))); return Result.ok("批量删除成功!"); }
Example #25
Source File: TeachingCourseController.java From teaching with Apache License 2.0 | 5 votes |
/** * 通过id删除 * * @param id * @return */ @AutoLog(value = "课程-通过id删除") @ApiOperation(value="课程-通过id删除", notes="课程-通过id删除") @DeleteMapping(value = "/delete") public Result<?> delete(@RequestParam(name="id",required=true) String id) { teachingCourseService.removeById(id); return Result.ok("删除成功!"); }
Example #26
Source File: TeachingCourseController.java From teaching with Apache License 2.0 | 5 votes |
/** * 编辑 * * @param teachingCourse * @return */ @AutoLog(value = "课程-编辑") @ApiOperation(value="课程-编辑", notes="课程-编辑") @PutMapping(value = "/edit") public Result<?> edit(@RequestBody TeachingCourse teachingCourse) { teachingCourseService.updateById(teachingCourse); return Result.ok("编辑成功!"); }
Example #27
Source File: SysDepartPermissionController.java From teaching with Apache License 2.0 | 5 votes |
/** * 编辑 * * @param sysDepartPermission * @return */ @AutoLog(value = "部门权限表-编辑") @ApiOperation(value="部门权限表-编辑", notes="部门权限表-编辑") @PutMapping(value = "/edit") public Result<?> edit(@RequestBody SysDepartPermission sysDepartPermission) { sysDepartPermissionService.updateById(sysDepartPermission); return Result.ok("编辑成功!"); }
Example #28
Source File: TeachingCourseController.java From teaching with Apache License 2.0 | 5 votes |
/** * 分页列表查询 * * @param teachingCourse * @param pageNo * @param pageSize * @param req * @return */ @AutoLog(value = "课程-分页列表查询") @ApiOperation(value="课程-分页列表查询", notes="课程-分页列表查询") @GetMapping(value = "/list") @PermissionData public Result<?> queryPageList(TeachingCourse teachingCourse, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) { QueryWrapper<TeachingCourse> queryWrapper = QueryGenerator.initQueryWrapper(teachingCourse, req.getParameterMap()); Page<TeachingCourse> page = new Page<TeachingCourse>(pageNo, pageSize); IPage<TeachingCourse> pageList = teachingCourseService.page(page, queryWrapper); return Result.ok(pageList); }
Example #29
Source File: QiniuController.java From teaching with Apache License 2.0 | 5 votes |
@AutoLog("获取七牛上传Token") @ApiOperation(value = "获取七牛覆盖Token", notes = "获取七牛覆盖token") @RequestMapping("/getTokenByKey") public Result getQiniuTokenByKey(@RequestParam String key){ Result result = new Result(); result.setCode(200); Auth auth = Auth.create(QiniuConfig.key, QiniuConfig.secret); result.setResult(auth.uploadToken(QiniuConfig.bucket, key, QiniuConfig.expires, null)); return result; }
Example #30
Source File: QiniuController.java From teaching with Apache License 2.0 | 5 votes |
@AutoLog("获取七牛上传Token") @ApiOperation(value = "获取七牛上传Token", notes = "获取七牛上传token") @RequestMapping("/getToken") public Result getQiniuToken(){ Result result = new Result(); result.setCode(200); Auth auth = Auth.create(QiniuConfig.key, QiniuConfig.secret); result.setResult(auth.uploadToken(QiniuConfig.bucket, null, QiniuConfig.expires, null)); return result; }