Merge remote-tracking branch 'origin/master'

This commit is contained in:
flower 2019-01-28 23:04:56 +08:00
commit 89479763d5
2 changed files with 5 additions and 4 deletions

View File

@ -12,6 +12,7 @@ import me.chanjar.weixin.cp.api.WxCpService;
import me.chanjar.weixin.cp.api.WxCpUserService; import me.chanjar.weixin.cp.api.WxCpUserService;
import me.chanjar.weixin.cp.bean.WxCpDepart; import me.chanjar.weixin.cp.bean.WxCpDepart;
import me.chanjar.weixin.cp.bean.WxCpUser; import me.chanjar.weixin.cp.bean.WxCpUser;
import org.apache.ibatis.annotations.Delete;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
@ -139,12 +140,12 @@ public class WxUserController {
} }
@Log(title = "批量删除成员", businessType = BusinessType.DELETE) @Log(title = "批量删除成员", businessType = BusinessType.DELETE)
@GetMapping("/deleteByIds") @PostMapping("/deleteByIds")
public AjaxResult delete(@RequestBody String[] ids) { public AjaxResult delete(@RequestBody String[] ids) {
try { try {
WxCpUserService userService = WxCpConfiguration.getCpService( 999999 ).getUserService(); WxCpUserService userService = WxCpConfiguration.getCpService( 999999 ).getUserService();
userService.delete( ids ); userService.delete( ids );
return AjaxResult.success( "批量删除成员" ); return AjaxResult.success( "批量删除成员成功" );
} catch (WxErrorException e) { } catch (WxErrorException e) {
return AjaxResult.error( "删除成员出错,错误码【" + e.getError().getErrorCode() + "】,原因:" + ErrorCodeText.errorMsg( e.getError().getErrorCode() ) ); return AjaxResult.error( "删除成员出错,错误码【" + e.getError().getErrorCode() + "】,原因:" + ErrorCodeText.errorMsg( e.getError().getErrorCode() ) );
} }

View File

@ -18,12 +18,12 @@ public class ErrorController {
@GetMapping(value = "/404") @GetMapping(value = "/404")
public String error404() { public String error404() {
return "error"; return "err";
} }
@GetMapping(value = "/500") @GetMapping(value = "/500")
public String error500() { public String error500() {
return "error"; return "err";
} }
} }