From 9b9d823f30f7f7744f412df8ca4c52d7be3c9977 Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Fri, 29 Jan 2016 23:59:58 -0500 Subject: Move Gitlab and Github authentication to external plugins --- app/Template/auth/index.php | 13 ------------- app/Template/config/integrations.php | 12 ------------ app/Template/user/authentication.php | 6 ------ app/Template/user/create_remote.php | 9 +-------- app/Template/user/external.php | 34 +--------------------------------- 5 files changed, 2 insertions(+), 72 deletions(-) (limited to 'app/Template') diff --git a/app/Template/auth/index.php b/app/Template/auth/index.php index 99444d37..41441e69 100644 --- a/app/Template/auth/index.php +++ b/app/Template/auth/index.php @@ -39,17 +39,4 @@ hook->render('template:auth:login-form:after') ?> - - - - - \ No newline at end of file diff --git a/app/Template/config/integrations.php b/app/Template/config/integrations.php index ef490cdf..ced051f7 100644 --- a/app/Template/config/integrations.php +++ b/app/Template/config/integrations.php @@ -6,18 +6,6 @@ form->csrf() ?> hook->render('template:config:integrations', array('values' => $values)) ?> -

-
-
-

url->doc(t('Help on Github authentication'), 'github-authentication') ?>

-
- -

 

-
-
-

url->doc(t('Help on Gitlab authentication'), 'gitlab-authentication') ?>

-
-

 

form->checkbox('integration_gravatar', t('Enable Gravatar images'), 1, $values['integration_gravatar'] == 1) ?> diff --git a/app/Template/user/authentication.php b/app/Template/user/authentication.php index 1f2d2a69..0c08f3fb 100644 --- a/app/Template/user/authentication.php +++ b/app/Template/user/authentication.php @@ -10,12 +10,6 @@ hook->render('template:user:authentication:form', array('values' => $values, 'errors' => $errors, 'user' => $user)) ?> - form->label(t('Github Id'), 'github_id') ?> - form->text('github_id', $values, $errors) ?> - - form->label(t('Gitlab Id'), 'gitlab_id') ?> - form->text('gitlab_id', $values, $errors) ?> - form->checkbox('is_ldap_user', t('Remote user'), 1, isset($values['is_ldap_user']) && $values['is_ldap_user'] == 1) ?> form->checkbox('disable_login_form', t('Disallow login form'), 1, isset($values['disable_login_form']) && $values['disable_login_form'] == 1) ?> diff --git a/app/Template/user/create_remote.php b/app/Template/user/create_remote.php index 1cc560cd..7399a010 100644 --- a/app/Template/user/create_remote.php +++ b/app/Template/user/create_remote.php @@ -20,14 +20,7 @@ form->label(t('Email'), 'email') ?> form->email('email', $values, $errors) ?> - form->label(t('Google Id'), 'google_id') ?> - form->text('google_id', $values, $errors) ?> - - form->label(t('Github Id'), 'github_id') ?> - form->text('github_id', $values, $errors) ?> - - form->label(t('Gitlab Id'), 'gitlab_id') ?> - form->text('gitlab_id', $values, $errors) ?> + hook->render('template:user:create-remote:form', array('values' => $values, 'errors' => $errors)) ?>
diff --git a/app/Template/user/external.php b/app/Template/user/external.php index 8c9a0259..22c25af2 100644 --- a/app/Template/user/external.php +++ b/app/Template/user/external.php @@ -4,39 +4,7 @@ hook->render('template:user:external', array('user' => $user)) ?> - -

- -

- user->isCurrentUser($user['id'])): ?> - - url->link(t('Link my Github Account'), 'oauth', 'github', array(), true) ?> - - url->link(t('Unlink my Github Account'), 'oauth', 'unlink', array('backend' => 'Github'), true) ?> - - - - -

- - - -

 

- -

- user->isCurrentUser($user['id'])): ?> - - url->link(t('Link my Gitlab Account'), 'oauth', 'gitlab', array(), true) ?> - - url->link(t('Unlink my Gitlab Account'), 'oauth', 'unlink', array('backend' => 'Gitlab'), true) ?> - - - - -

- - - +

-- cgit v1.2.3