diff options
author | Frédéric Guillot <fred@kanboard.net> | 2014-06-30 21:52:02 -0300 |
---|---|---|
committer | Frédéric Guillot <fred@kanboard.net> | 2014-06-30 21:52:02 -0300 |
commit | 06d0b7048ebcdfdf6e24eec3ac7dc8fb0327dd6f (patch) | |
tree | eb006b4c560781186f1debd2437c02edf6008878 /app/Templates/user_edit.php | |
parent | f70ac7d65fa0e7f1e6a9559242d9c141ba5c9eb3 (diff) |
Merge pull-request: Github authentication #162
Diffstat (limited to 'app/Templates/user_edit.php')
-rw-r--r-- | app/Templates/user_edit.php | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/app/Templates/user_edit.php b/app/Templates/user_edit.php index 6b83f748..8fba922f 100644 --- a/app/Templates/user_edit.php +++ b/app/Templates/user_edit.php @@ -48,14 +48,27 @@ <?= Helper\form_checkbox('is_admin', t('Administrator'), 1, isset($values['is_admin']) && $values['is_admin'] == 1 ? true : false) ?><br/> <?php endif ?> + <ul> <?php if (GOOGLE_AUTH && Helper\is_current_user($values['id'])): ?> + <li> <?php if (empty($values['google_id'])): ?> <a href="?controller=user&action=google<?= Helper\param_csrf() ?>"><?= t('Link my Google Account') ?></a> <?php else: ?> <a href="?controller=user&action=unlinkGoogle<?= Helper\param_csrf() ?>"><?= t('Unlink my Google Account') ?></a> <?php endif ?> + </li> <?php endif ?> + <?php if (GITHUB_AUTH && Helper\is_current_user($values['id'])): ?> + <li> + <?php if (empty($values['github_id'])): ?> + <a href="?controller=user&action=gitHub<?= Helper\param_csrf() ?>"><?= t('Link my GitHub Account') ?></a> + <?php else: ?> + <a href="?controller=user&action=unlinkGitHub<?= Helper\param_csrf() ?>"><?= t('Unlink my GitHub Account') ?></a> + <?php endif ?> + </li> + <?php endif ?> + </ul> </div> <div class="form-actions"> |