| | |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.BasePageDTO; |
| | | import com.ycl.api.BasePageVO; |
| | | import com.ycl.api.CommonResult; |
| | |
| | | |
| | | @ApiOperation("添加部门") |
| | | @PostMapping(value = "/create") |
| | | @LogSave(operationType = "部门管理",contain = "添加部门") |
| | | public CommonResult<Void> create(@Validated @RequestBody DepartVO.AddDepartVO addDepartVO) { |
| | | departService.create(addDepartVO); |
| | | return CommonResult.success(null); |
| | |
| | | |
| | | @ApiOperation("编辑部门") |
| | | @PostMapping(value = "/update") |
| | | @LogSave(operationType = "部门管理",contain = "编辑部门") |
| | | public CommonResult<Void> create(@Validated @RequestBody DepartVO.UpdateDepartVO params) { |
| | | departService.update(params); |
| | | return CommonResult.success(null); |
| | |
| | | |
| | | @ApiOperation("删除") |
| | | @PostMapping(value = "/delete") |
| | | @LogSave(operationType = "部门管理",contain = "删除部门") |
| | | public CommonResult<Void> delete(@Validated @RequestBody DepartVO.IdDepartVO params) { |
| | | departService.delete(params.getId()); |
| | | return CommonResult.success(null); |
| | |
| | | **/ |
| | | @ApiOperation("批处理-删除") |
| | | @PostMapping(value = "/batch_deletion") |
| | | @LogSave(operationType = "部门管理",contain = "批量删除部门") |
| | | public CommonResult delete(@RequestParam List<Long> ids) { |
| | | if (ids.isEmpty()) { |
| | | return CommonResult.failed("bad request parameter"); |
| | |
| | | |
| | | @ApiOperation("详情") |
| | | @PostMapping(value = "/detail") |
| | | @LogSave(operationType = "部门管理",contain = "查看部门") |
| | | public CommonResult<UmsDepart> detail(@Validated @RequestBody DepartVO.IdDepartVO params) { |
| | | UmsDepart sccgDepart = departService.loadDepartById(params.getId()); |
| | | return CommonResult.success(sccgDepart); |
| | |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.controller.BaseController; |
| | | import com.ycl.dto.UmsAdminLoginParam; |
| | |
| | | @ApiOperation(value = "用户注册") |
| | | @RequestMapping(value = "/register", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "用户管理",contain = "添加用户") |
| | | public CommonResult<UmsAdmin> register(@Validated @RequestBody UmsAdminParam umsAdminParam) { |
| | | UmsAdmin umsAdmin = adminService.register(umsAdminParam); |
| | | if (umsAdmin == null) { |
| | |
| | | @ApiOperation("修改指定用户信息") |
| | | @RequestMapping(value = "/update/{id}", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "用户管理",contain = "修改用户") |
| | | public CommonResult update(@PathVariable Long id, @RequestBody UmsAdmin admin) { |
| | | boolean success = adminService.update(id, admin); |
| | | if (success) { |
| | |
| | | @ApiOperation("修改指定用户密码") |
| | | @RequestMapping(value = "/updatePassword", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "用户管理",contain = "修改用户密码") |
| | | public CommonResult updatePassword(@Validated @RequestBody UpdateAdminPasswordParam updatePasswordParam) { |
| | | int status = adminService.updatePassword(updatePasswordParam); |
| | | if (status > 0) { |
| | |
| | | @ApiOperation("删除指定用户信息") |
| | | @RequestMapping(value = "/delete/{id}", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "用户管理",contain = "删除用户") |
| | | public CommonResult delete(@PathVariable Long id) { |
| | | boolean success = adminService.delete(id); |
| | | if (success) { |
| | |
| | | @ApiOperation("修改帐号状态") |
| | | @RequestMapping(value = "/updateStatus/{id}", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "用户管理",contain = "用户账号启用/禁用") |
| | | public CommonResult updateStatus(@PathVariable Long id, @RequestParam(value = "status") Integer status) { |
| | | UmsAdmin umsAdmin = new UmsAdmin(); |
| | | umsAdmin.setStatus(status); |
| | |
| | | @ApiImplicitParam(name = "ids", value = "用户Ids",required = true, dataType = "Array") |
| | | }) |
| | | @ResponseBody |
| | | @LogSave(operationType = "用户管理",contain = "批量删除用户") |
| | | public CommonResult deleteBatch(@RequestParam("ids") List<Long> ids) { |
| | | boolean success = adminService.deleteBatch(ids); |
| | | if (success) { |
| | |
| | | @ApiImplicitParam(name = "status", value = "状态0->禁用;1->启用",required = true, dataType = "Integer") |
| | | }) |
| | | @ResponseBody |
| | | @LogSave(operationType = "用户管理",contain = "用户账号批量启用/禁用") |
| | | public CommonResult updateStatusBatch(@RequestParam("ids") List<Long> ids, @RequestParam(value = "status") Integer status) { |
| | | boolean success = adminService.updateStatusBatch(ids, status); |
| | | if (success) { |
| | |
| | | package com.ycl.controller.user; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonPage; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.entity.user.UmsMenu; |
| | |
| | | @ApiOperation("添加角色") |
| | | @RequestMapping(value = "/create", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "角色管理",contain = "新建角色") |
| | | public CommonResult create(@RequestBody UmsRole role) { |
| | | boolean success = roleService.create(role); |
| | | if (success) { |
| | |
| | | @ApiOperation("批量删除角色") |
| | | @RequestMapping(value = "/delete", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "角色管理",contain = "批量删除角色") |
| | | public CommonResult delete(@RequestParam("ids") List<Long> ids) { |
| | | boolean success = roleService.delete(ids); |
| | | if (success) { |
| | |
| | | @ApiOperation("给角色分配菜单") |
| | | @RequestMapping(value = "/allocMenu", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "角色管理",contain = "权限设置") |
| | | public CommonResult allocMenu(@RequestParam Long roleId, @RequestParam List<Long> menuIds) { |
| | | int count = roleService.allocMenu(roleId, menuIds); |
| | | return CommonResult.success(count); |
| | |
| | | @ApiImplicitParam(name = "status", value = "状态0->禁用;1->启用",required = true, dataType = "Integer") |
| | | }) |
| | | @ResponseBody |
| | | @LogSave(operationType = "角色管理",contain = "批量启用/禁用角色") |
| | | public CommonResult updateStatusBatch(@RequestParam("ids") List<Long> ids, @RequestParam(value = "status") Integer status) { |
| | | boolean success = roleService.updateStatusBatch(ids, status); |
| | | if (success) { |
| | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.controller.BaseController; |
| | | import com.ycl.entity.carManage.CarEnforcecar; |
| | |
| | | |
| | | @ApiOperation("添加执法车") |
| | | @PostMapping("/addition_enforce") |
| | | @LogSave(operationType = "车俩管理",contain = "添加执法车") |
| | | public CommonResult addEnforceCar(@RequestBody CarEnforcecar carEnforcecar) { |
| | | return CommonResult.success(iCarEnforcecarService.save(carEnforcecar)); |
| | | } |
| | | |
| | | @ApiOperation("添加渣土车") |
| | | @PostMapping("/addition_slag") |
| | | @LogSave(operationType = "车俩管理",contain = "添加渣土车") |
| | | public CommonResult addSlagCar(@RequestBody CarSlagcar carSlagcar) { |
| | | return CommonResult.success(iCarSlagcarService.save(carSlagcar)); |
| | | } |
| | | |
| | | @ApiOperation("删除执法车") |
| | | @DeleteMapping("/deletion_enforce") |
| | | @LogSave(operationType = "车俩管理",contain = "删除执法车") |
| | | public CommonResult deleteEnforceCar(@RequestParam Integer id) { |
| | | return CommonResult.success(iCarEnforcecarService.removeById(id)); |
| | | } |
| | | |
| | | @ApiOperation("删除渣土车") |
| | | @DeleteMapping("/deletion_slag") |
| | | @LogSave(operationType = "车俩管理",contain = "删除渣土车") |
| | | public CommonResult deleteSlagCar(@RequestParam Integer id) { |
| | | return CommonResult.success(iCarSlagcarService.removeById(id)); |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.common.constant.BaseCaseStatus; |
| | | import com.ycl.common.util.UtilNumber; |
| | |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "type", value = "1 违规,2 违建", dataType = "Integer") |
| | | }) |
| | | @LogSave(operationType = "事项处置管理",contain = "删除案件") |
| | | public CommonResult removeCase(@RequestParam Integer id, @RequestParam Integer type) { |
| | | Integer violationType = 1; |
| | | Integer illegalBuildingType = 2; |
| | |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "type", value = "1 违规,2 违建", dataType = "Integer") |
| | | }) |
| | | @LogSave(operationType = "事项处置管理",contain = "批量删除案件") |
| | | public CommonResult removeCases(@RequestParam List<Long> ids, @RequestParam Integer type) { |
| | | Integer violationType = 1; |
| | | Integer illegalBuildingType = 2; |
| | |
| | | **/ |
| | | @ApiOperation(value = "添加违规案件") |
| | | @PostMapping("/addition_violation") |
| | | @LogSave(operationType = "事项处置管理",contain = "新增违建案件") |
| | | public CommonResult addViolationCase(@RequestBody @Validated ViolationParam violationParam) { |
| | | Integer violation = 1; |
| | | Integer resource = 2; |
| | |
| | | **/ |
| | | @ApiOperation(value = "添加违建案件") |
| | | @PostMapping("/addition_illegal_building") |
| | | @LogSave(operationType = "事项处置管理",contain = "新增违规案件") |
| | | public CommonResult addIllegalBuildingCase(@RequestBody @Validated IllegalBuildingParam illegalBuildingParam) { |
| | | Integer illegalBuilding = 2; |
| | | Integer resource = 2; |
| | |
| | | |
| | | @ApiOperation(value = "结案") |
| | | @PutMapping("/end_case") |
| | | @LogSave(operationType = "事项处置管理",contain = "案件结案") |
| | | public CommonResult endCase(@RequestParam Long caseId, @RequestParam String result) { |
| | | baseCaseService.endCase(caseId, result); |
| | | return CommonResult.success("end case success~!"); |
| | |
| | | package com.ycl.controller.caseHandler; |
| | | |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.bo.AdminUserDetails; |
| | | import com.ycl.dto.caseHandler.ChechParam; |
| | |
| | | @ApiOperation(value = "审核") |
| | | @RequestMapping(value = "/check", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "审核管理",contain = "案件审核") |
| | | public CommonResult check(@Validated @RequestBody ChechParam chechParam) { |
| | | AdminUserDetails user = (AdminUserDetails) SecurityContextHolder.getContext().getAuthentication().getPrincipal(); |
| | | chechParam.setCurrentUser(user.getUserId()); |
| | |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.bo.AdminUserDetails; |
| | | import com.ycl.common.constant.BaseCaseStatus; |
| | |
| | | @ApiOperation(value = "调度") |
| | | @RequestMapping(value = "/dispatch", method = RequestMethod.POST) |
| | | @ResponseBody |
| | | @LogSave(operationType = "事项处置管理",contain = "案件调度") |
| | | public CommonResult<DispatchInfo> dispatch(@Validated @RequestBody DispatchInfoParam dispatchInfoParam) { |
| | | AdminUserDetails user = (AdminUserDetails) SecurityContextHolder.getContext().getAuthentication().getPrincipal(); |
| | | dispatchInfoParam.setCreateUser(user.getUserId()); |
| | |
| | | |
| | | @ApiOperation(value = "上传违规/违建处置结果") |
| | | @PostMapping("/addition_dispose_result") |
| | | @LogSave(operationType = "事项处置管理",contain = "案件上传处置结果") |
| | | public CommonResult searchDisposeList(@RequestParam Long caseId, |
| | | @RequestParam Integer type, |
| | | @RequestBody UploadDisposingResultParam uploadDisposingResultParam) { |
| | |
| | | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.controller.BaseController; |
| | | import com.ycl.entity.dict.DataDictionary; |
| | |
| | | **/ |
| | | @ApiOperation(value = "删除违建类型") |
| | | @DeleteMapping("/delete") |
| | | @LogSave(operationType = "运营基础设置",contain = "删除违建事项") |
| | | public CommonResult removeIllegalBuilding(@RequestParam Integer id) { |
| | | return CommonResult.success(iDataDictionaryService.removeById(id)); |
| | | } |
| | |
| | | * @Description batch delete illegal building |
| | | * @Param [ids] |
| | | **/ |
| | | @ApiOperation(value = "批量删除违规类型") |
| | | @ApiOperation(value = "批量删除违建类型") |
| | | @DeleteMapping("/batch_delete") |
| | | @LogSave(operationType = "运营基础设置",contain = "批量删除违建事项") |
| | | public CommonResult removeIllegalBuildings(@RequestParam String[] ids) { |
| | | return CommonResult.success(iDataDictionaryService.removeBatchByIds(Arrays.asList(ids))); |
| | | } |
| | |
| | | **/ |
| | | @ApiOperation(value = "添加所属类型/类别") |
| | | @PostMapping("/addition/type") |
| | | @LogSave(operationType = "运营基础设置",contain = "添加违建事项") |
| | | public CommonResult addIllegalBuildingTypeFirst(@RequestBody @Validated DataDictionary dataDictionary) { |
| | | return CommonResult.success(iDataDictionaryService.save(dataDictionary)); |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ycl.annotation.LogSave; |
| | | import com.ycl.api.CommonResult; |
| | | import com.ycl.controller.BaseController; |
| | | import com.ycl.entity.dict.DataDictionary; |
| | |
| | | **/ |
| | | @ApiOperation(value = "删除违规类型") |
| | | @DeleteMapping("/delete") |
| | | @LogSave(operationType = "运营基础设置",contain = "删除违规事项") |
| | | public CommonResult removeViolation(@RequestParam Integer id) { |
| | | return CommonResult.success(iDataDictionaryService.removeById(id)); |
| | | } |
| | |
| | | **/ |
| | | @ApiOperation(value = "批量删除违规类型") |
| | | @DeleteMapping("/batch_delete") |
| | | @LogSave(operationType = "运营基础设置",contain = "批量删除违规事项") |
| | | public CommonResult removeViolations(@RequestParam String[] ids) { |
| | | return CommonResult.success(iDataDictionaryService.removeBatchByIds(Arrays.asList(ids))); |
| | | } |
| | |
| | | **/ |
| | | @ApiOperation(value = "添加所属类型/大类/小类/案由") |
| | | @PostMapping("/addition/type") |
| | | @LogSave(operationType = "运营基础设置",contain = "添加违规事项") |
| | | public CommonResult addViolationType(@RequestBody @Validated DataDictionary dataDictionary) { |
| | | return CommonResult.success(iDataDictionaryService.save(dataDictionary)); |
| | | } |