Skip to content

Commit

Permalink
fix: display consent page when has multiple identity scopes
Browse files Browse the repository at this point in the history
  • Loading branch information
cowienduckie committed Jan 23, 2024
1 parent c2b7a58 commit 8ea377a
Showing 1 changed file with 30 additions and 29 deletions.
59 changes: 30 additions & 29 deletions src/Identity/IdentityServer/Views/Consent/Index.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -21,39 +21,40 @@

<input type="hidden" asp-for="ReturnUrl" name="ReturnUrl"/>
<input type="hidden" asp-for="ScopesConsented" name="ScopesConsented"/>
<div class="flex flex-column">
@if (Model.IdentityScopes.Any())
{
<div class="panel panel-default consent-buttons">
<div class="panel-heading distance-ul">
<span class="glyphicon glyphicon-user"></span>
<span class="size-text">Personal Information</span>
</div>
<ul class="list-group">
@foreach (var scope in Model.IdentityScopes)
{
<partial name="_ScopeListItem" model="@scope"/>
}
</ul>

@if (Model.IdentityScopes.Any())
{
<div class="panel panel-default consent-buttons">
<div class="panel-heading distance-ul">
<span class="glyphicon glyphicon-user"></span>
<span class="size-text">Personal Information</span>
</div>
<ul class="list-group">
@foreach (var scope in Model.IdentityScopes)
{
<partial name="_ScopeListItem" model="@scope"/>
}
</ul>
}
@if (Model.ResourceScopes.Any())
{
<div class="panel panel-default">
<div class="panel-heading distance-ul">
<span class="glyphicon glyphicon-tasks"></span>
Application Access
</div>
<ul class="list-group">
@foreach (var scope in Model.ResourceScopes)
{
<partial name="_ScopeListItem" model="scope"/>
}

</div>
}
@if (Model.ResourceScopes.Any())
{
<div class="panel panel-default">
<div class="panel-heading distance-ul">
<span class="glyphicon glyphicon-tasks"></span>
Application Access
</ul>
</div>
<ul class="list-group">
@foreach (var scope in Model.ResourceScopes)
{
<partial name="_ScopeListItem" model="scope"/>
}

</ul>
</div>
}
}
</div>

@if (Model.AllowRememberConsent)
{
Expand Down

0 comments on commit 8ea377a

Please sign in to comment.