|
@@ -21,16 +21,6 @@
|
|
|
</div>
|
|
</div>
|
|
|
<fieldset id="passport-twitter-hide-when-disabled" {%if !isTwitterEnabled %}style="display: none;"{% endif %}>
|
|
<fieldset id="passport-twitter-hide-when-disabled" {%if !isTwitterEnabled %}style="display: none;"{% endif %}>
|
|
|
|
|
|
|
|
- <div class="form-group">
|
|
|
|
|
- <label for="settingForm[security:passport-twitter:clientId]" class="col-xs-3 control-label">{{ t("security_setting.OAuth.register", t("security_setting.OAuth.Twitter.name") ) }}</label>
|
|
|
|
|
- <div class="col-xs-6">
|
|
|
|
|
- <ol class="help-block">
|
|
|
|
|
- <li>{{ t("security_setting.OAuth.Twitter.register_1", "https://github.com/settings/developers", "GitHub Developer Settings") }}</li>
|
|
|
|
|
- <li>{{ t("security_setting.OAuth.Twitter.register_2", "https://${growi.host}/passport/twitter/callback", "${growi.host}") }}</li>
|
|
|
|
|
- <li>{{ t("security_setting.OAuth.Twitter.register_3") }}</li>
|
|
|
|
|
- </ol>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
<div class="form-group">
|
|
|
<label for="settingForm[security:passport-twitter:clientId]" class="col-xs-3 control-label">{{ t("security_setting.clientID") }}</label>
|
|
<label for="settingForm[security:passport-twitter:clientId]" class="col-xs-3 control-label">{{ t("security_setting.clientID") }}</label>
|
|
@@ -62,6 +52,19 @@
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
+ <div class="form-group">
|
|
|
|
|
+ <label for="settingForm[security:passport-google:callbackUrl]" class="col-xs-3 control-label">{{ t("security_setting.callback_URL") }}</label>
|
|
|
|
|
+ <div class="col-xs-6">
|
|
|
|
|
+ <input class="form-control" type="text" name="settingForm[security:passport-google:callbackUrl]" value="{{ settingForm['security:passport-google:callbackUrl'] || '' }}">
|
|
|
|
|
+ <p class="help-block">
|
|
|
|
|
+ <small>
|
|
|
|
|
+ {{ t("security_setting.Use env var if empty", "OAUTH_GOOGLE_CALLBACK_URL") }}
|
|
|
|
|
+ </small>
|
|
|
|
|
+ </p>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
</fieldset>
|
|
</fieldset>
|
|
|
|
|
|
|
|
<div class="form-group" id="btn-update">
|
|
<div class="form-group" id="btn-update">
|
|
@@ -73,6 +76,21 @@
|
|
|
|
|
|
|
|
</form>
|
|
</form>
|
|
|
|
|
|
|
|
|
|
+{# Help Section #}
|
|
|
|
|
+<hr>
|
|
|
|
|
+<h4>
|
|
|
|
|
+ <i class="fa fa-question-circle" aria-hidden="true"></i>
|
|
|
|
|
+ <a href="#collapseHelpForGoogleOauth" data-toggle="collapse">How to configure Google OAuth?</a>
|
|
|
|
|
+</h4>
|
|
|
|
|
+<ol id="collapseHelpForGoogleOauth" class="collapse">
|
|
|
|
|
+ <li>{{ t("security_setting.OAuth.Google.register_1", "https://console.cloud.google.com/apis/credentials", "Google Cloud Platform API Manager") }}</li>
|
|
|
|
|
+ <li>{{ t("security_setting.OAuth.Google.register_2") }}</li>
|
|
|
|
|
+ <li>{{ t("security_setting.OAuth.Google.register_3") }}</li>
|
|
|
|
|
+ <li>{{ t("security_setting.OAuth.Google.register_4", "https://${growi.host}/passport/google/callback", "${growi.host}") }}</li>
|
|
|
|
|
+ <li>{{ t("security_setting.OAuth.Google.register_5") }}</li>
|
|
|
|
|
+</ol>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
<script>
|
|
<script>
|
|
|
$('input[name="settingForm[security:passport-twitter:isEnabled]"]').change(function() {
|
|
$('input[name="settingForm[security:passport-twitter:isEnabled]"]').change(function() {
|
|
|
const isEnabled = ($(this).val() === "true");
|
|
const isEnabled = ($(this).val() === "true");
|