update
This commit is contained in:
@@ -8,6 +8,7 @@ use App\Controller\AbstractController;
|
||||
use App\Middleware\AuthMiddleware;
|
||||
use App\Middleware\PermissionMiddleware;
|
||||
use App\Model\Company;
|
||||
use App\Service\OperationLogService;
|
||||
use App\Model\Platform;
|
||||
use App\Model\Store;
|
||||
use App\Model\User;
|
||||
@@ -238,6 +239,16 @@ class DataScopeController extends AbstractController
|
||||
// 重建 bitmap 并更新 Swoole\Table
|
||||
$this->scopeTableManager->rebuildUserScope($id);
|
||||
|
||||
OperationLogService::log(
|
||||
user_id: OperationLogService::getCurrentUserId() ?? 0,
|
||||
action: 'scope.update',
|
||||
target_type: 'user',
|
||||
target_id: $id,
|
||||
description: "更新用户 #{$id} 数据权限",
|
||||
detail: ['scopes' => $scopes],
|
||||
ip: OperationLogService::getRequestIp(),
|
||||
);
|
||||
|
||||
return [
|
||||
'code' => 0,
|
||||
'message' => '数据权限更新成功',
|
||||
|
||||
Reference in New Issue
Block a user