diff options
author | Frederic Guillot <fred@kanboard.net> | 2016-03-26 17:25:54 -0400 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2016-03-26 17:25:54 -0400 |
commit | 4ca716ec47863f3eef6c851de7a4f37650f8ea6e (patch) | |
tree | af7ca983e3cec6300c1689bd76eb99e37fc2f799 /app/Template | |
parent | 820c929ab38273c80d0930e2e6140dd7676ba4df (diff) |
Move avatar actions to controller AvatarFile
Diffstat (limited to 'app/Template')
-rw-r--r-- | app/Template/avatar_file/show.php (renamed from app/Template/user/avatar.php) | 4 | ||||
-rw-r--r-- | app/Template/user/sidebar.php | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/app/Template/user/avatar.php b/app/Template/avatar_file/show.php index c285f44d..266a2ccb 100644 --- a/app/Template/user/avatar.php +++ b/app/Template/avatar_file/show.php @@ -4,14 +4,14 @@ <?= $this->avatar->render($user['id'], $user['username'], $user['name'], $user['email'], $user['avatar_path'], '') ?> -<form method="post" enctype="multipart/form-data" action="<?= $this->url->href('user', 'uploadAvatar', array('user_id' => $user['id'])) ?>"> +<form method="post" enctype="multipart/form-data" action="<?= $this->url->href('AvatarFile', 'upload', array('user_id' => $user['id'])) ?>"> <?= $this->form->csrf() ?> <?= $this->form->label(t('Upload my avatar image'), 'avatar') ?> <?= $this->form->file('avatar') ?> <div class="form-actions"> <?php if (! empty($user['avatar_path'])): ?> - <?= $this->url->link(t('Remove my image'), 'User', 'removeAvatar', array('user_id' => $user['id']), true, 'btn btn-red') ?> + <?= $this->url->link(t('Remove my image'), 'AvatarFile', 'remove', array('user_id' => $user['id']), true, 'btn btn-red') ?> <?php endif ?> <button type="submit" class="btn btn-blue"><?= t('Save') ?></button> <?= t('or') ?> diff --git a/app/Template/user/sidebar.php b/app/Template/user/sidebar.php index ecadc60d..5ea2e355 100644 --- a/app/Template/user/sidebar.php +++ b/app/Template/user/sidebar.php @@ -37,8 +37,8 @@ <li <?= $this->app->checkMenuSelection('user', 'edit') ?>> <?= $this->url->link(t('Edit profile'), 'user', 'edit', array('user_id' => $user['id'])) ?> </li> - <li <?= $this->app->checkMenuSelection('user', 'avatar') ?>> - <?= $this->url->link(t('Avatar'), 'user', 'avatar', array('user_id' => $user['id'])) ?> + <li <?= $this->app->checkMenuSelection('AvatarFile') ?>> + <?= $this->url->link(t('Avatar'), 'AvatarFile', 'show', array('user_id' => $user['id'])) ?> </li> <?php endif ?> |