You are here

public function OAuth2ServerScopeUIController::__construct in OAuth2 Server 7

Overrides EntityDefaultUIController::__construct

File

includes/oauth2_server.scope_admin.inc, line 12
Admin UI for scopes.

Class

OAuth2ServerScopeUIController
UI controller.

Code

public function __construct($entity_type, $entity_info) {
  $this->statusKey = 'status';
  $this->entityType = $entity_type;
  $this->entityInfo = $entity_info;

  // Stop the UI from mentioning "OAuth2 scope" everywhere.
  $this->entityInfo['label'] = 'Scope';

  // Replace the server placeholder with the server name, since the path
  // is used for links and redirects.
  $this->path = str_replace('%oauth2_server', arg(4), $this->entityInfo['admin ui']['path']);
}