]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/profilesettings.php
Merge branch 'master' into 0.9.x
[quix0rs-gnu-social.git] / actions / profilesettings.php
index 28b1d20f34125fab3b39b60281de0b08458dfeb2..8f55a471890931df2fd174bd9c85abd50537d8dc 100644 (file)
@@ -452,4 +452,33 @@ class ProfilesettingsAction extends AccountSettingsAction
             return $other->id != $user->id;
         }
     }
+
+    function showAside() {
+        $user = common_current_user();
+
+        $this->elementStart('div', array('id' => 'aside_primary',
+                                         'class' => 'aside'));
+        if ($user->hasRight(Right::BACKUPACCOUNT)) {
+            $this->elementStart('li');
+            $this->element('a',
+                           array('href' => common_local_url('backupaccount')),
+                           _('Backup account'));
+            $this->elementEnd('li');
+        }
+        if ($user->hasRight(Right::DELETEACCOUNT)) {
+            $this->elementStart('li');
+            $this->element('a',
+                           array('href' => common_local_url('deleteaccount')),
+                           _('Delete account'));
+            $this->elementEnd('li');
+        }
+        if ($user->hasRight(Right::RESTOREACCOUNT)) {
+            $this->elementStart('li');
+            $this->element('a',
+                           array('href' => common_local_url('restoreaccount')),
+                           _('Restore account'));
+            $this->elementEnd('li');
+        }
+        $this->elementEnd('div');
+    }
 }