Commit fd2c7685 by 水库浪子

接口增加权限

1 parent 819b87e4
...@@ -39,7 +39,7 @@ public class WeCustomerController extends BaseController ...@@ -39,7 +39,7 @@ public class WeCustomerController extends BaseController
/** /**
* 查询企业微信客户列表 * 查询企业微信客户列表
*/ */
@PreAuthorize("@ss.hasPermi('wecom:customer:list')") @PreAuthorize("@ss.hasPermi('customerManage:customer:list')")
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(WeCustomer weCustomer) public TableDataInfo list(WeCustomer weCustomer)
{ {
...@@ -48,23 +48,23 @@ public class WeCustomerController extends BaseController ...@@ -48,23 +48,23 @@ public class WeCustomerController extends BaseController
return getDataTable(list); return getDataTable(list);
} }
/** // /**
* 导出企业微信客户列表 // * 导出企业微信客户列表
*/ // */
@PreAuthorize("@ss.hasPermi('wecom:customer:export')") // @PreAuthorize("@ss.hasPermi('wecom:customer:export')")
@Log(title = "企业微信客户", businessType = BusinessType.EXPORT) // @Log(title = "企业微信客户", businessType = BusinessType.EXPORT)
@GetMapping("/export") // @GetMapping("/export")
public AjaxResult export(WeCustomer weCustomer) // public AjaxResult export(WeCustomer weCustomer)
{ // {
List<WeCustomer> list = weCustomerService.selectWeCustomerList(weCustomer); // List<WeCustomer> list = weCustomerService.selectWeCustomerList(weCustomer);
ExcelUtil<WeCustomer> util = new ExcelUtil<WeCustomer>(WeCustomer.class); // ExcelUtil<WeCustomer> util = new ExcelUtil<WeCustomer>(WeCustomer.class);
return util.exportExcel(list, "customer"); // return util.exportExcel(list, "customer");
} // }
/** /**
* 获取企业微信客户详细信息 * 获取企业微信客户详细信息
*/ */
@PreAuthorize("@ss.hasPermi('wecom:customer:query')") @PreAuthorize("@ss.hasPermi('customerManage:customer:view')")
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) public AjaxResult getInfo(@PathVariable("id") Long id)
{ {
...@@ -89,7 +89,7 @@ public class WeCustomerController extends BaseController ...@@ -89,7 +89,7 @@ public class WeCustomerController extends BaseController
* 客户同步接口 * 客户同步接口
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:customer:synchWeCustomer')") @PreAuthorize("@ss.hasPermi('customerManage:customer:sync')")
@Log(title = "企业微信客户同步接口", businessType = BusinessType.DELETE) @Log(title = "企业微信客户同步接口", businessType = BusinessType.DELETE)
@GetMapping("/synchWeCustomer") @GetMapping("/synchWeCustomer")
public AjaxResult synchWeCustomer(){ public AjaxResult synchWeCustomer(){
...@@ -106,7 +106,7 @@ public class WeCustomerController extends BaseController ...@@ -106,7 +106,7 @@ public class WeCustomerController extends BaseController
* @param weMakeCustomerTag * @param weMakeCustomerTag
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:customer:makeLabel')") @PreAuthorize("@ss.hasPermi('customerManage/customer:makeTag')")
@Log(title = "客户打标签", businessType = BusinessType.UPDATE) @Log(title = "客户打标签", businessType = BusinessType.UPDATE)
@PostMapping("/makeLabel") @PostMapping("/makeLabel")
public AjaxResult makeLabel(@RequestBody WeMakeCustomerTag weMakeCustomerTag){ public AjaxResult makeLabel(@RequestBody WeMakeCustomerTag weMakeCustomerTag){
...@@ -121,7 +121,7 @@ public class WeCustomerController extends BaseController ...@@ -121,7 +121,7 @@ public class WeCustomerController extends BaseController
* 移除客户标签 * 移除客户标签
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:customer:removeLabel')") @PreAuthorize("@ss.hasPermi('customerManage:customer:removeTag')")
@Log(title = "移除客户标签", businessType = BusinessType.DELETE) @Log(title = "移除客户标签", businessType = BusinessType.DELETE)
@DeleteMapping("/removeLabel") @DeleteMapping("/removeLabel")
public AjaxResult removeLabel(@RequestBody WeMakeCustomerTag weMakeCustomerTag){ public AjaxResult removeLabel(@RequestBody WeMakeCustomerTag weMakeCustomerTag){
......
...@@ -33,7 +33,7 @@ public class WeDepartmentController extends BaseController ...@@ -33,7 +33,7 @@ public class WeDepartmentController extends BaseController
/** /**
* 查询企业微信组织架构相关列表 * 查询企业微信组织架构相关列表
*/ */
@PreAuthorize("@ss.hasPermi('wecom:department:list')") @PreAuthorize("@ss.hasPermi('contacts:organization:list')")
@GetMapping("/list") @GetMapping("/list")
@ApiOperation("获取部门列表") @ApiOperation("获取部门列表")
public AjaxResult list() public AjaxResult list()
...@@ -47,7 +47,7 @@ public class WeDepartmentController extends BaseController ...@@ -47,7 +47,7 @@ public class WeDepartmentController extends BaseController
/** /**
* 新增企业微信组织架构相关 * 新增企业微信组织架构相关
*/ */
@PreAuthorize("@ss.hasPermi('wecom:department:add')") @PreAuthorize("@ss.hasPermi('contacts:organization:addMember')")
@Log(title = "企业微信组织架构相关", businessType = BusinessType.INSERT) @Log(title = "企业微信组织架构相关", businessType = BusinessType.INSERT)
@PostMapping @PostMapping
@ApiOperation("添加部门") @ApiOperation("添加部门")
...@@ -60,7 +60,7 @@ public class WeDepartmentController extends BaseController ...@@ -60,7 +60,7 @@ public class WeDepartmentController extends BaseController
/** /**
* 修改企业微信组织架构相关 * 修改企业微信组织架构相关
*/ */
@PreAuthorize("@ss.hasPermi('wecom:department:edit')") @PreAuthorize("@ss.hasPermi('contacts:organization:editDep')")
@Log(title = "企业微信组织架构相关", businessType = BusinessType.UPDATE) @Log(title = "企业微信组织架构相关", businessType = BusinessType.UPDATE)
@PutMapping @PutMapping
@ApiOperation("更新部门") @ApiOperation("更新部门")
......
...@@ -32,7 +32,7 @@ public class WeGroupController extends BaseController { ...@@ -32,7 +32,7 @@ public class WeGroupController extends BaseController {
@Autowired @Autowired
private IWeGroupMemberService weGroupMemberService; private IWeGroupMemberService weGroupMemberService;
@PreAuthorize("@ss.hasPermi('wecom:group:list')") @PreAuthorize("@ss.hasPermi('customerManage:group:list')")
@GetMapping({"/list"}) @GetMapping({"/list"})
public TableDataInfo list(WeGroup weGroup) { public TableDataInfo list(WeGroup weGroup) {
startPage(); startPage();
...@@ -40,7 +40,7 @@ public class WeGroupController extends BaseController { ...@@ -40,7 +40,7 @@ public class WeGroupController extends BaseController {
return getDataTable(list); return getDataTable(list);
} }
@PreAuthorize("@ss.hasPermi('wecom:member:list')") @PreAuthorize("@ss.hasPermi('customerManage:group:view')")
@GetMapping({"/members"}) @GetMapping({"/members"})
public TableDataInfo list(WeGroupMember weGroupMember) { public TableDataInfo list(WeGroupMember weGroupMember) {
startPage(); startPage();
...@@ -52,7 +52,7 @@ public class WeGroupController extends BaseController { ...@@ -52,7 +52,7 @@ public class WeGroupController extends BaseController {
* 同步客户群 * 同步客户群
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:group:synchWeGroup')") @PreAuthorize("@ss.hasPermi('customerManage:group:sync')")
@GetMapping({"/synchWeGroup"}) @GetMapping({"/synchWeGroup"})
public AjaxResult synchWeGroup(){ public AjaxResult synchWeGroup(){
......
...@@ -36,7 +36,7 @@ public class WeTagGroupController extends BaseController ...@@ -36,7 +36,7 @@ public class WeTagGroupController extends BaseController
/** /**
* 查询标签组列表 * 查询标签组列表
*/ */
@PreAuthorize("@ss.hasPermi('wecom:group:list')") @PreAuthorize("@ss.hasPermi('customerManage:tag:list')")
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(WeTagGroup weTagGroup) public TableDataInfo list(WeTagGroup weTagGroup)
{ {
...@@ -51,7 +51,7 @@ public class WeTagGroupController extends BaseController ...@@ -51,7 +51,7 @@ public class WeTagGroupController extends BaseController
/** /**
* 新增标签组 * 新增标签组
*/ */
@PreAuthorize("@ss.hasPermi('wecom:group:add')") @PreAuthorize("@ss.hasPermi('customerManage:tag:add')")
@Log(title = "标签组", businessType = BusinessType.INSERT) @Log(title = "标签组", businessType = BusinessType.INSERT)
@PostMapping @PostMapping
public AjaxResult add(@RequestBody WeTagGroup weTagGroup) public AjaxResult add(@RequestBody WeTagGroup weTagGroup)
...@@ -64,7 +64,7 @@ public class WeTagGroupController extends BaseController ...@@ -64,7 +64,7 @@ public class WeTagGroupController extends BaseController
/** /**
* 修改标签组 * 修改标签组
*/ */
@PreAuthorize("@ss.hasPermi('wecom:group:edit')") @PreAuthorize("@ss.hasPermi('customerManage:tag:edit')")
@Log(title = "标签组", businessType = BusinessType.UPDATE) @Log(title = "标签组", businessType = BusinessType.UPDATE)
@PutMapping @PutMapping
public AjaxResult edit(@RequestBody WeTagGroup weTagGroup) public AjaxResult edit(@RequestBody WeTagGroup weTagGroup)
...@@ -76,7 +76,7 @@ public class WeTagGroupController extends BaseController ...@@ -76,7 +76,7 @@ public class WeTagGroupController extends BaseController
/** /**
* 删除标签组 * 删除标签组
*/ */
@PreAuthorize("@ss.hasPermi('wecom:group:remove')") @PreAuthorize("@ss.hasPermi('customerManage:tag:remove')")
@Log(title = "标签组", businessType = BusinessType.DELETE) @Log(title = "标签组", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}") @DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable String[] ids) public AjaxResult remove(@PathVariable String[] ids)
...@@ -89,7 +89,7 @@ public class WeTagGroupController extends BaseController ...@@ -89,7 +89,7 @@ public class WeTagGroupController extends BaseController
* 同步标签 * 同步标签
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:group:synchWeTags')") @PreAuthorize("@ss.hasPermi('customerManage:tag:sync')")
@GetMapping("/synchWeTags") @GetMapping("/synchWeTags")
public AjaxResult synchWeTags(){ public AjaxResult synchWeTags(){
......
...@@ -41,7 +41,7 @@ public class WeUserController extends BaseController { ...@@ -41,7 +41,7 @@ public class WeUserController extends BaseController {
/** /**
* 查询通讯录相关客户列表 * 查询通讯录相关客户列表
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:list')") @PreAuthorize("@ss.hasPermi('contacts:organization:query')")
@GetMapping("/list") @GetMapping("/list")
@ApiOperation("获取通讯录人员列表") @ApiOperation("获取通讯录人员列表")
public TableDataInfo list(WeUser weUser) public TableDataInfo list(WeUser weUser)
...@@ -57,7 +57,7 @@ public class WeUserController extends BaseController { ...@@ -57,7 +57,7 @@ public class WeUserController extends BaseController {
/** /**
* 获取通讯录相关客户详细信息 * 获取通讯录相关客户详细信息
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:query')") @PreAuthorize("@ss.hasPermi('contacts:organization:view')")
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) public AjaxResult getInfo(@PathVariable("id") Long id)
{ {
...@@ -67,7 +67,7 @@ public class WeUserController extends BaseController { ...@@ -67,7 +67,7 @@ public class WeUserController extends BaseController {
/** /**
* 新增通讯录相关客户 * 新增通讯录相关客户
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:add')") @PreAuthorize("@ss.hasPermi('contacts:organization:addMember')")
@Log(title = "通讯录相关客户", businessType = BusinessType.INSERT) @Log(title = "通讯录相关客户", businessType = BusinessType.INSERT)
@PostMapping @PostMapping
@ApiOperation("新增通讯录客户") @ApiOperation("新增通讯录客户")
...@@ -80,7 +80,7 @@ public class WeUserController extends BaseController { ...@@ -80,7 +80,7 @@ public class WeUserController extends BaseController {
/** /**
* 修改通讯录相关客户 * 修改通讯录相关客户
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:edit')") @PreAuthorize("@ss.hasPermi('contacts:organization:edit')")
@Log(title = "更新通讯录客户", businessType = BusinessType.UPDATE) @Log(title = "更新通讯录客户", businessType = BusinessType.UPDATE)
@PutMapping @PutMapping
@ApiOperation("更新通讯录客户") @ApiOperation("更新通讯录客户")
...@@ -96,7 +96,7 @@ public class WeUserController extends BaseController { ...@@ -96,7 +96,7 @@ public class WeUserController extends BaseController {
* @param weUser * @param weUser
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:startOrStop')") @PreAuthorize("@ss.hasPermi('contacts:organization:forbidden')")
@Log(title = "启用禁用用户", businessType = BusinessType.UPDATE) @Log(title = "启用禁用用户", businessType = BusinessType.UPDATE)
@PutMapping("/startOrStop") @PutMapping("/startOrStop")
@ApiOperation("是否启用(1表示启用成员,0表示禁用成员)") @ApiOperation("是否启用(1表示启用成员,0表示禁用成员)")
...@@ -113,7 +113,7 @@ public class WeUserController extends BaseController { ...@@ -113,7 +113,7 @@ public class WeUserController extends BaseController {
* @param weLeaveUserVo * @param weLeaveUserVo
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:leaveUserAllocateList')") @PreAuthorize("@ss.hasPermi('customerManage:dimission:filter')")
@GetMapping({"/leaveUserAllocateList"}) @GetMapping({"/leaveUserAllocateList"})
public TableDataInfo leaveUserAllocateList(WeLeaveUserVo weLeaveUserVo) { public TableDataInfo leaveUserAllocateList(WeLeaveUserVo weLeaveUserVo) {
startPage(); startPage();
...@@ -129,7 +129,7 @@ public class WeUserController extends BaseController { ...@@ -129,7 +129,7 @@ public class WeUserController extends BaseController {
* @param weLeaveUserVo * @param weLeaveUserVo
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:leaveUserNoAllocateList')") @PreAuthorize("@ss.hasPermi('customerManage:dimission:query')")
@GetMapping({"/leaveUserNoAllocateList"}) @GetMapping({"/leaveUserNoAllocateList"})
public TableDataInfo leaveUserNoAllocateList(WeLeaveUserVo weLeaveUserVo) { public TableDataInfo leaveUserNoAllocateList(WeLeaveUserVo weLeaveUserVo) {
startPage(); startPage();
...@@ -145,7 +145,7 @@ public class WeUserController extends BaseController { ...@@ -145,7 +145,7 @@ public class WeUserController extends BaseController {
* @param weLeaveUserInfoAllocateVo * @param weLeaveUserInfoAllocateVo
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:allocateLeaveUserAboutData')") @PreAuthorize("@ss.hasPermi('customerManage:dimission:allocate')")
@PutMapping({"/allocateLeaveUserAboutData"}) @PutMapping({"/allocateLeaveUserAboutData"})
public AjaxResult allocateLeaveUserAboutData(@RequestBody WeLeaveUserInfoAllocateVo weLeaveUserInfoAllocateVo) { public AjaxResult allocateLeaveUserAboutData(@RequestBody WeLeaveUserInfoAllocateVo weLeaveUserInfoAllocateVo) {
...@@ -159,7 +159,7 @@ public class WeUserController extends BaseController { ...@@ -159,7 +159,7 @@ public class WeUserController extends BaseController {
* 同步成员 * 同步成员
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:synchWeUser')") @PreAuthorize("@ss.hasPermi('contacts:organization:sync')")
@GetMapping({"/synchWeUser"}) @GetMapping({"/synchWeUser"})
public AjaxResult synchWeUser(){ public AjaxResult synchWeUser(){
...@@ -174,7 +174,7 @@ public class WeUserController extends BaseController { ...@@ -174,7 +174,7 @@ public class WeUserController extends BaseController {
* 删除用户 * 删除用户
* @return * @return
*/ */
@PreAuthorize("@ss.hasPermi('wecom:user:deleteUser')") @PreAuthorize("@ss.hasPermi('contacts:organization:removeMember')")
@DeleteMapping({"/{ids}"}) @DeleteMapping({"/{ids}"})
public AjaxResult deleteUser(@PathVariable String[] ids){ public AjaxResult deleteUser(@PathVariable String[] ids){
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!