Apply group weight system to API token modifications
This commit is contained in:
@@ -90,12 +90,14 @@ The Sentri gnomes';
|
||||
$this->apiOutput(200, ['success' => 'User created successfully. mail has been sent']);
|
||||
}
|
||||
|
||||
private function getUserGroupWeight()
|
||||
public function getUserGroupWeight($user_group_uuid = false)
|
||||
{
|
||||
require_once 'API_usergroups.php';
|
||||
|
||||
$API_usergroups = new API_usergroups();
|
||||
$_GET['builder'] = [1 => ['where' => [0 => 'user_group_uuid', 1 => $this->data['user_group_uuid']]]];
|
||||
|
||||
$uuid = $user_group_uuid ?: $this->data['user_group_uuid'];
|
||||
$_GET['builder'] = [1 => ['where' => [0 => 'user_group_uuid', 1 => $uuid]]];
|
||||
|
||||
return $API_usergroups->getUserGroup()[0]['user_group_weight'];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user