1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798 |
- <?php
- if (!defined('GNUSOCIAL')) { exit(1); }
- class GroupmembersAction extends GroupAction
- {
- var $page = null;
- function isReadOnly($args)
- {
- return true;
- }
- function title()
- {
- if ($this->page == 1) {
-
-
- return sprintf(_('%s group members'),
- $this->group->nickname);
- } else {
-
-
- return sprintf(_('%1$s group members, page %2$d'),
- $this->group->nickname,
- $this->page);
- }
- }
- protected function handle()
- {
- parent::handle();
- $this->showPage();
- }
- function showPageNotice()
- {
- $this->element('p', 'instructions',
-
- _('A list of the users in this group.'));
- }
- function showContent()
- {
- $offset = ($this->page-1) * PROFILES_PER_PAGE;
- $limit = PROFILES_PER_PAGE + 1;
- $cnt = 0;
- $members = $this->group->getMembers($offset, $limit);
- if ($members) {
- $member_list = new GroupMemberList($members, $this->group, $this);
- $cnt = $member_list->show();
- }
- $this->pagination($this->page > 1, $cnt > PROFILES_PER_PAGE,
- $this->page, 'groupmembers',
- array('nickname' => $this->group->nickname));
- }
- }
|