企微前后台联调。
This commit is contained in:
@@ -73,8 +73,9 @@ public class QweiDepartmentController {
|
||||
|
||||
@PostMapping("/sync")
|
||||
@Operation(summary = "同步企微部门并入库")
|
||||
public ResponseEntity<Map<String, Object>> sync() {
|
||||
Map<String, Object> result = qweiDepartmentService.syncFromQiWei();
|
||||
public ResponseEntity<Map<String, Object>> sync(
|
||||
@RequestParam(required = false) String tenantId) {
|
||||
Map<String, Object> result = qweiDepartmentService.syncFromQiWei(tenantId);
|
||||
Boolean success = (Boolean) result.get("success");
|
||||
if (success != null && success) {
|
||||
return ResponseEntity.ok(result);
|
||||
|
||||
@@ -74,8 +74,9 @@ public class QweiUserController {
|
||||
|
||||
@PostMapping("/sync")
|
||||
@Operation(summary = "同步企微用户并入库")
|
||||
public ResponseEntity<Map<String, Object>> sync() {
|
||||
Map<String, Object> result = qweiUserService.syncFromQiWei();
|
||||
public ResponseEntity<Map<String, Object>> sync(
|
||||
@RequestParam(required = false) String tenantId) {
|
||||
Map<String, Object> result = qweiUserService.syncFromQiWei(tenantId);
|
||||
Boolean success = (Boolean) result.get("success");
|
||||
if (success != null && success) {
|
||||
return ResponseEntity.ok(result);
|
||||
|
||||
Reference in New Issue
Block a user