Skip to content

Commit

Permalink
Merge branch 'biocore:master' into japanese_locale
Browse files Browse the repository at this point in the history
  • Loading branch information
ayobi authored Mar 27, 2024
2 parents e2e675c + 621691c commit da2cbcd
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 5 deletions.
17 changes: 15 additions & 2 deletions microsetta_interface/implementation.py
Original file line number Diff line number Diff line change
Expand Up @@ -2782,8 +2782,21 @@ def get_interactive_account_search(email_query):
if do_return:
return email_diagnostics

accounts = [{"email": acct['email'], "account_id": acct['id']}
for acct in email_diagnostics['accounts']]
accounts = []
for acct in email_diagnostics['accounts']:
if acct['auth_issuer'] is None and acct['auth_sub'] is None:
authrocket_status = "Missing"
elif acct['auth_issuer'] is None or acct['auth_sub'] is None:
authrocket_status = "Faulty - Contact Admin"
else:
authrocket_status = "Authenticated"
acct_diag = {
"email": acct['email'],
"account_id": acct['id'],
"authrocket_status": authrocket_status
}
accounts.append(acct_diag)

return _render_with_defaults('admin_home.jinja2',
accounts=accounts)

Expand Down
10 changes: 8 additions & 2 deletions microsetta_interface/templates/admin_home.jinja2
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,24 @@
<div class="col-sm">
<i>{{ _('Account ID') }}</i>
</div>
<div class="col-sm">
<i>{{ _('AuthRocket Status') }}</i>
</div>
</div>
{% for account in accounts %}
<div class="container list-group-item {{loop.cycle('odd', 'even') }}">
<div class="row">
<div class="col-sm">
<div class="col-sm" style="word-wrap: break-word; overflow: hidden;">
<a href="/accounts/{{account.account_id |e}}">
{{ account.email |e}}
</a>
</div>
<div class="col-sm">
<div class="col-sm" style="word-wrap: break-word; overflow: hidden;">
{{ account.account_id|e }}
</div>
<div class="col-sm">
{{ account.authrocket_status|e }}
</div>
</div>
</div>
{% endfor %}
Expand Down
16 changes: 15 additions & 1 deletion microsetta_interface/templates/new_results_page.jinja2
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,11 @@
width: 30%;
margin: 20px;
}
@media (max-width: 575.98px) {
div.diversity-compare {
width: 90%;
}
}
.diversity-category {
color: #006a96;
}
Expand Down Expand Up @@ -116,6 +121,11 @@
border-color: #006a96;
width: 70%;
}
@media (max-width: 575.98px) {
div.how_you_compare_section {
width: 100%;
}
}
div.how_you_compare_section h3 {
color: #006a96;
font-weight: lighter;
Expand Down Expand Up @@ -147,7 +157,11 @@
width: 35%;
box-shadow: 0 4px 8px 0 rgb(0 0 0 / 20%), 0 6px 20px 0 rgb(0 0 0 / 19%);
}
@media (max-width: 575.98px) {
div.your_sample_diversity_inset {
width: 100%;
}
}
.scatter-bg {
background-image: url('/static/img/scatter.png');
background: url('/static/img/scatter.png');
Expand Down

0 comments on commit da2cbcd

Please sign in to comment.