mirror of
https://github.com/google/nomulus.git
synced 2025-06-04 03:27:27 +02:00
Only show OT&E admin actions when not in production environment
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=237061813
This commit is contained in:
parent
6b9b60d38c
commit
90e298fb39
10 changed files with 38 additions and 19 deletions
|
@ -35,6 +35,7 @@ import com.google.template.soy.data.SoyMapData;
|
|||
import com.google.template.soy.shared.SoyCssRenamingMap;
|
||||
import com.google.template.soy.tofu.SoyTofu;
|
||||
import google.registry.config.RegistryConfig.Config;
|
||||
import google.registry.config.RegistryEnvironment;
|
||||
import google.registry.request.Action;
|
||||
import google.registry.request.Parameter;
|
||||
import google.registry.request.Response;
|
||||
|
@ -76,6 +77,7 @@ public final class ConsoleUiAction implements Runnable {
|
|||
@Inject UserService userService;
|
||||
@Inject XsrfTokenManager xsrfTokenManager;
|
||||
@Inject AuthResult authResult;
|
||||
@Inject RegistryEnvironment environment;
|
||||
@Inject @Config("logoFilename") String logoFilename;
|
||||
@Inject @Config("productName") String productName;
|
||||
@Inject @Config("integrationEmail") String integrationEmail;
|
||||
|
@ -133,6 +135,7 @@ public final class ConsoleUiAction implements Runnable {
|
|||
data.put("xsrfToken", xsrfTokenManager.generateToken(user.getEmail()));
|
||||
ImmutableSetMultimap<String, Role> roleMap = registrarAccessor.getAllClientIdWithRoles();
|
||||
data.put("allClientIds", roleMap.keySet());
|
||||
data.put("environment", environment.toString());
|
||||
// We set the initual value to the value that will show if guessClientId throws.
|
||||
String clientId = "<null>";
|
||||
try {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue