| | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | import com.ruoyi.common.utils.StringUtils; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | * @author ruoyi |
| | | * @date 2023-05-25 |
| | | */ |
| | | @Api(description = "标签分类") |
| | | @RestController |
| | | @RequestMapping("/system/info") |
| | | public class BaseUserInfoController extends BaseController { |
| | |
| | | /** |
| | | * 查询用户列表 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:info:list')") |
| | | @PostMapping("/list") |
| | | @ApiOperation("查询用户列表") |
| | | //@PreAuthorize("@ss.hasPermi('system:info:list')") |
| | | @PostMapping("/list") |
| | | public TableDataInfo list(@RequestBody BaseUserInfo baseUserInfo) { |
| | | startPage(); |
| | | List<BaseUserInfo> list = baseUserInfoService.selectBaseUserInfoList(baseUserInfo); |
| | |
| | | /** |
| | | * 导出用户列表 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:info:export')") |
| | | @Log(title = "用户", businessType = BusinessType.EXPORT) |
| | | @ApiOperation("导出用户列表") |
| | | //@PreAuthorize("@ss.hasPermi('system:info:export')") |
| | | @Log(title = "用户" , businessType = BusinessType.EXPORT) |
| | | @PostMapping("/export") |
| | | public void export(HttpServletResponse response, BaseUserInfo baseUserInfo) { |
| | | List<BaseUserInfo> list = baseUserInfoService.selectBaseUserInfoList(baseUserInfo); |
| | |
| | | /** |
| | | * 获取用户详细信息 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:info:query')") |
| | | @ApiOperation("获取用户详细信息") |
| | | //@PreAuthorize("@ss.hasPermi('system:info:query')") |
| | | @GetMapping(value = "/{userid}") |
| | | public AjaxResult getInfo(@PathVariable("userid") Long userid) { |
| | | return success(baseUserInfoService.selectBaseUserInfoByUserid(userid)); |
| | |
| | | /** |
| | | * 新增用户 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:info:add')") |
| | | @Log(title = "用户", businessType = BusinessType.INSERT) |
| | | @ApiOperation("新增用户") |
| | | //@PreAuthorize("@ss.hasPermi('system:info:add')") |
| | | @Log(title = "用户" , businessType = BusinessType.INSERT) |
| | | @PostMapping("/add") |
| | | public AjaxResult add(@RequestBody BaseUserInfo baseUserInfo) { |
| | | return toAjax(baseUserInfoService.insertBaseUserInfo(baseUserInfo)); |
| | |
| | | /** |
| | | * 修改用户 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:info:edit')") |
| | | @Log(title = "用户", businessType = BusinessType.UPDATE) |
| | | @ApiOperation("修改用户") |
| | | //@PreAuthorize("@ss.hasPermi('system:info:edit')") |
| | | @Log(title = "用户" , businessType = BusinessType.UPDATE) |
| | | @PostMapping("/edit") |
| | | public AjaxResult edit(@RequestBody BaseUserInfo baseUserInfo) { |
| | | return toAjax(baseUserInfoService.updateBaseUserInfo(baseUserInfo)); |
| | |
| | | /** |
| | | * 删除用户 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:info:remove')") |
| | | @Log(title = "用户", businessType = BusinessType.DELETE) |
| | | @ApiOperation("删除用户") |
| | | //@PreAuthorize("@ss.hasPermi('system:info:remove')") |
| | | @Log(title = "用户" , businessType = BusinessType.DELETE) |
| | | @GetMapping("/remove/{userids}") |
| | | public AjaxResult remove(@PathVariable Long[] userids) { |
| | | return toAjax(baseUserInfoService.deleteBaseUserInfoByUserids(userids)); |
| | |
| | | /** |
| | | * 获取人员的联系方式 |
| | | * |
| | | * @param personCode 人员编号 |
| | | * @param noticeWay 通知方式 |
| | | * @param personCode 人员编号 |
| | | * @param noticeWay 通知方式 |
| | | * @return |
| | | */ |
| | | @ApiOperation("获取人员的联系方式") |
| | | @GetMapping("/reportContent") |
| | | public AjaxResult getContact(@RequestParam("personCode") String personCode, @RequestParam("noticeWay") String noticeWay) { |
| | | if (StringUtils.isEmpty(personCode) || StringUtils.isEmpty(noticeWay)) { |