diff --git a/app/hr/templates/hr/applications/view.html b/app/hr/templates/hr/applications/view.html
index 5a8a62a..6089922 100644
--- a/app/hr/templates/hr/applications/view.html
+++ b/app/hr/templates/hr/applications/view.html
@@ -98,7 +98,7 @@
API Keys
| User ID | API Key | Description | Type | Active | Last Updated |
-{% for acc in user.eveaccount_set.all %}
+{% for acc in app.user.eveaccount_set.all %}
| {{ acc.api_user_id }} |
{{ acc.api_key }} |
{{ acc.description }} |
diff --git a/app/sso/templates/sso/lookup/user.html b/app/sso/templates/sso/lookup/user.html
index 55573d1..4c3361a 100644
--- a/app/sso/templates/sso/lookup/user.html
+++ b/app/sso/templates/sso/lookup/user.html
@@ -28,7 +28,6 @@
-{% if is_admin %}
{% if services %}
Service Accounts
@@ -127,6 +126,5 @@
{% endif %}
{% endif %}
-{% endif %}
{% endblock %}
diff --git a/app/sso/templates/sso/profile.html b/app/sso/templates/sso/profile.html
index a739ac3..e9a1d36 100644
--- a/app/sso/templates/sso/profile.html
+++ b/app/sso/templates/sso/profile.html
@@ -14,23 +14,23 @@ function refresh_apikey(key) {
$("#api-status-" + key).html("
");
$("#api-time-" + key).html("
");
$.getJSON("/eve/eveapi/refresh/" + key + "/", function(json) {
- $("#api-time-" + json[0].fields.api_user_id).html("a moment ago");
+ $("#api-time-" + json[0].pk).html("a moment ago");
switch(json[0].fields.api_status) {
case 0:
- $("#api-status-" + json[0].fields.api_user_id).html("Unknown");
+ $("#api-status-" + json[0].pk).html("Unknown");
break;
case 1:
- $("#api-status-" + json[0].fields.api_user_id).html("OK");
+ $("#api-status-" + json[0].pk).html("OK");
break;
case 2:
- $("#api-status-" + json[0].fields.api_user_id).html("Other Error");
+ $("#api-status-" + json[0].pk).html("Other Error");
break;
case 3:
- $("#api-status-" + json[0].fields.api_user_id).html("Account Expired");
+ $("#api-status-" + json[0].pk).html("Account Expired");
break;
default:
- $("#api-status-" + json[0].fields.api_user_id).html("Error");
+ $("#api-status-" + json[0].pk).html("Error");
break;
}
});
diff --git a/app/templates/base.html b/app/templates/base.html
index f8f3b64..2bfd197 100644
--- a/app/templates/base.html
+++ b/app/templates/base.html
@@ -23,8 +23,10 @@
HR
{% endif %}
Characters
- {% if request.user.is_staff %}
+ {% if perms.sso.can_search_users %}
Lookup User
+ {% endif %}
+ {% if request.user.is_staff %}
Admin
{% endif %}
Logout