Commit e90e6848 authored by 鲍德's avatar 鲍德

目录调整

parent 1058b241
...@@ -30,7 +30,7 @@ import com.ruoyi.common.core.page.TableDataInfo; ...@@ -30,7 +30,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
* @date 2023-11-30 * @date 2023-11-30
*/ */
@RestController @RestController
@RequestMapping("/system/currentProject") @RequestMapping("/risk/currentProject")
public class ProjectUserPostController extends BaseController public class ProjectUserPostController extends BaseController
{ {
@Autowired @Autowired
...@@ -39,7 +39,7 @@ public class ProjectUserPostController extends BaseController ...@@ -39,7 +39,7 @@ public class ProjectUserPostController extends BaseController
/** /**
* 查询项目用户岗位关系列表 * 查询项目用户岗位关系列表
*/ */
@PreAuthorize("@ss.hasPermi('system:currentProject:list')") @PreAuthorize("@ss.hasPermi('risk:currentProject:list')")
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(ProjectUserPost projectUserPost) public TableDataInfo list(ProjectUserPost projectUserPost)
{ {
...@@ -51,7 +51,7 @@ public class ProjectUserPostController extends BaseController ...@@ -51,7 +51,7 @@ public class ProjectUserPostController extends BaseController
/** /**
* 导出项目用户岗位关系列表 * 导出项目用户岗位关系列表
*/ */
@PreAuthorize("@ss.hasPermi('system:currentProject:export')") @PreAuthorize("@ss.hasPermi('risk:currentProject:export')")
@Log(title = "项目用户岗位关系", businessType = BusinessType.EXPORT) @Log(title = "项目用户岗位关系", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, ProjectUserPost projectUserPost) public void export(HttpServletResponse response, ProjectUserPost projectUserPost)
...@@ -64,7 +64,7 @@ public class ProjectUserPostController extends BaseController ...@@ -64,7 +64,7 @@ public class ProjectUserPostController extends BaseController
/** /**
* 获取项目用户岗位关系详细信息 * 获取项目用户岗位关系详细信息
*/ */
@PreAuthorize("@ss.hasPermi('system:currentProject:query')") @PreAuthorize("@ss.hasPermi('risk:currentProject:query')")
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) public AjaxResult getInfo(@PathVariable("id") Long id)
{ {
...@@ -74,7 +74,7 @@ public class ProjectUserPostController extends BaseController ...@@ -74,7 +74,7 @@ public class ProjectUserPostController extends BaseController
/** /**
* 新增项目用户岗位关系 * 新增项目用户岗位关系
*/ */
@PreAuthorize("@ss.hasPermi('system:currentProject:add')") @PreAuthorize("@ss.hasPermi('risk:currentProject:add')")
@Log(title = "项目用户岗位关系", businessType = BusinessType.INSERT) @Log(title = "项目用户岗位关系", businessType = BusinessType.INSERT)
@PostMapping("save") @PostMapping("save")
public AjaxResult add(@RequestBody ProjectUserPost projectUserPost) public AjaxResult add(@RequestBody ProjectUserPost projectUserPost)
...@@ -90,7 +90,7 @@ public class ProjectUserPostController extends BaseController ...@@ -90,7 +90,7 @@ public class ProjectUserPostController extends BaseController
/** /**
* 修改项目用户岗位关系 * 修改项目用户岗位关系
*/ */
@PreAuthorize("@ss.hasPermi('system:currentProject:edit')") @PreAuthorize("@ss.hasPermi('risk:currentProject:edit')")
@Log(title = "项目用户岗位关系", businessType = BusinessType.UPDATE) @Log(title = "项目用户岗位关系", businessType = BusinessType.UPDATE)
@PutMapping @PutMapping
public AjaxResult edit(@RequestBody ProjectUserPost projectUserPost) public AjaxResult edit(@RequestBody ProjectUserPost projectUserPost)
...@@ -101,7 +101,7 @@ public class ProjectUserPostController extends BaseController ...@@ -101,7 +101,7 @@ public class ProjectUserPostController extends BaseController
/** /**
* 删除项目用户岗位关系 * 删除项目用户岗位关系
*/ */
@PreAuthorize("@ss.hasPermi('system:currentProject:remove')") @PreAuthorize("@ss.hasPermi('risk:currentProject:remove')")
@Log(title = "项目用户岗位关系", businessType = BusinessType.DELETE) @Log(title = "项目用户岗位关系", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}") @DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids) public AjaxResult remove(@PathVariable Long[] ids)
......
...@@ -39,4 +39,6 @@ public class ProjectUserPost extends BaseEntityClean ...@@ -39,4 +39,6 @@ public class ProjectUserPost extends BaseEntityClean
@Excel(name = "岗位 id") @Excel(name = "岗位 id")
@ApiModelProperty("岗位 id") @ApiModelProperty("岗位 id")
private Long postId; private Long postId;
private String projectName;
} }
...@@ -9,6 +9,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -9,6 +9,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="projectId" column="project_id" /> <result property="projectId" column="project_id" />
<result property="userId" column="user_id" /> <result property="userId" column="user_id" />
<result property="postId" column="post_id" /> <result property="postId" column="post_id" />
<result property="projectName" column="project_name" />
</resultMap> </resultMap>
<sql id="selectProjectUserPostVo"> <sql id="selectProjectUserPostVo">
...@@ -16,7 +17,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -16,7 +17,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</sql> </sql>
<select id="selectProjectUserPostList" parameterType="com.censoft.censoftrongtong.domain.ProjectUserPost" resultMap="ProjectUserPostResult"> <select id="selectProjectUserPostList" parameterType="com.censoft.censoftrongtong.domain.ProjectUserPost" resultMap="ProjectUserPostResult">
<include refid="selectProjectUserPostVo"/> SELECT
a.id,
project_id,
b.`name` project_name,
user_id,
post_id
FROM
project_user_post a
LEFT JOIN ledger_project b on a.project_id = b.id
<where> <where>
<if test="projectId != null "> and project_id = #{projectId}</if> <if test="projectId != null "> and project_id = #{projectId}</if>
<if test="userId != null "> and user_id = #{userId}</if> <if test="userId != null "> and user_id = #{userId}</if>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment