2016-03-25 00:16:27 +00:00
|
|
|
<div id="yield">
|
|
|
|
<div class="centerContent">
|
|
|
|
<header class="page-header" role="banner">
|
2018-03-04 02:25:42 +00:00
|
|
|
<h1>{ t('.title') }</h1>
|
2016-03-25 00:16:27 +00:00
|
|
|
</header>
|
|
|
|
|
|
|
|
<main role="main">
|
|
|
|
<p class="h4">
|
2018-03-04 02:25:42 +00:00
|
|
|
{ raw t('.prompt', client_name: "<strong class=\"text-info\">#{ @pre_auth.client.name }</strong>") }
|
2016-03-25 00:16:27 +00:00
|
|
|
</p>
|
|
|
|
|
2018-03-04 02:25:42 +00:00
|
|
|
{ if @pre_auth.scopes.count > 0 }
|
2016-03-25 00:16:27 +00:00
|
|
|
<div id="oauth-permissions">
|
2018-03-04 02:25:42 +00:00
|
|
|
<p>{ t('.able_to') }:</p>
|
2016-03-25 00:16:27 +00:00
|
|
|
|
|
|
|
<ul class="text-info">
|
2018-03-04 02:25:42 +00:00
|
|
|
{ @pre_auth.scopes.each do |scope| }
|
|
|
|
<li>{ t scope, scope: [:doorkeeper, :scopes] }</li>
|
|
|
|
{ end }
|
2016-03-25 00:16:27 +00:00
|
|
|
</ul>
|
|
|
|
</div>
|
2018-03-04 02:25:42 +00:00
|
|
|
{ end }
|
2016-03-25 00:16:27 +00:00
|
|
|
|
|
|
|
<div class="actions">
|
|
|
|
<div class="inline-button button-margin-top">
|
2018-03-04 02:25:42 +00:00
|
|
|
{ form_tag oauth_authorization_path, method: :post do }
|
|
|
|
{ hidden_field_tag :client_id, @pre_auth.client.uid }
|
|
|
|
{ hidden_field_tag :redirect_uri, @pre_auth.redirect_uri }
|
|
|
|
{ hidden_field_tag :state, @pre_auth.state }
|
|
|
|
{ hidden_field_tag :response_type, @pre_auth.response_type }
|
|
|
|
{ hidden_field_tag :scope, @pre_auth.scope }
|
|
|
|
{ submit_tag t('doorkeeper.authorizations.buttons.authorize'), class: "button" }
|
|
|
|
{ end }
|
2016-03-25 00:16:27 +00:00
|
|
|
</div>
|
|
|
|
<div class="inline-button button-margin-top">
|
2018-03-04 02:25:42 +00:00
|
|
|
{ form_tag oauth_authorization_path, method: :delete do }
|
|
|
|
{ hidden_field_tag :client_id, @pre_auth.client.uid }
|
|
|
|
{ hidden_field_tag :redirect_uri, @pre_auth.redirect_uri }
|
|
|
|
{ hidden_field_tag :state, @pre_auth.state }
|
|
|
|
{ hidden_field_tag :response_type, @pre_auth.response_type }
|
|
|
|
{ hidden_field_tag :scope, @pre_auth.scope }
|
|
|
|
{ submit_tag t('doorkeeper.authorizations.buttons.deny'), class: "button red-button" }
|
|
|
|
{ end }
|
2016-03-25 00:16:27 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</main>
|
|
|
|
</div>
|
|
|
|
</div>
|