Renders user list.

@ManagerRoute("/user")
@Method({ "GET" })
@Template
324195
public function indexAction()
    {
        $allowed_users = array();
        $users = $this->getDoctrine()->getManager()->createQuery('SELECT r FROM FOMUserBundle:User r')->getResult();

        // ACL access check
        foreach ($users as $index => $user) {
            if ($this->isGranted('VIEW', $user)) {
                $allowed_users[] = $user;
            }
        }

        $oid = new ObjectIdentity('class', 'FOM\UserBundle\Entity\User');

        return array(
            'users'             => $allowed_users,
            'create_permission' => $this->isGranted('CREATE', $oid)
        );
    }
662650
public function render()
    {
        $tpl = eZTemplate::factory();
        $ini = eZINI::instance( 'rest.ini' );

        $nodeViewData = eZNodeviewfunctions::generateNodeViewData( $tpl, $this->content->main_node, $this->content->main_node->attribute( 'object' ), $this->content->activeLanguage, 'rest', 0 );

        $tpl->setVariable( 'module_result', $nodeViewData );

        $routingInfos = $this->controller->getRouter()->getRoutingInformation();
        $templateName = $ini->variable( $routingInfos->controllerClass . '_'. $routingInfos->action . '_OutputSettings', 'Template' );

        return $tpl->fetch( 'design:' . $templateName );
    }
90885
def render(self, context):
        
        user = self._get_value(self.user_key, context)
        feature = self._get_value(self.feature, context)

        if feature is None:
            return ''

        allowed = show_feature(user, feature)
        return self.nodelist.render(context) if allowed else ''
519871
public function render()
    {
        $sModulesDir = \OxidEsales\Eshop\Core\Registry::getConfig()->getModulesDir();

        $oModuleList = oxNew(\OxidEsales\Eshop\Core\Module\ModuleList::class);
        $aModules = $oModuleList->getModulesFromDir($sModulesDir);

        parent::render();

        // assign our list
        $this->_aViewData['mylist'] = $aModules;

        return 'module_list.tpl';
    }
1049873
def list_managers_view(request):
    '''  '''
    managerset = Manager.objects.filter(active=True)
    return render_to_response('list_managers.html', {
        'page_name': "Managers",
        'managerset': managerset,
        }, context_instance=RequestContext(request))
623094
def users(options = {})
      batches = Enumerator.new do |y|
        options = options.merge(group_name: @name)
        resp = @client.get_group(options)
        resp.each_page do |page|
          batch = []
          page.data.users.each do |u|
            batch << User.new(
              name: u.user_name,
              data: u,
              client: @client
            )
          end
          y.yield(batch)
        end
      end
      User::Collection.new(batches)
    end
1227349
def list_users
      r = execute(make_xml('UserListingRequest'))
      arr = []
      if r.success
        r.res.elements.each('UserListingResponse/UserSummary') do |summary|
          arr << UserSummary.parse(summary)
        end
      end
      arr
    end
407795
def list_users(self, user=None):
    '''
    ''' 
    from expfactory.database.models import Participant
    participants = Participant.query.all()
    users = []
    for user in participants:
        users.append(self.print_user(user))
    return users
202145
function getUsers(){
    console.log('getUsers called');
    grout.Users.get().then(function(app){
      console.log('apps list loaded:', app);
      document.getElementById("output").innerHTML = JSON.stringify(app);
    }, function(err){
      console.error('Error getting users:', err);
    });
  }
1100003
public function index()
    {
        $this->loadModel('User.Users');
        $users = $this->Users->find()->contain(['Roles']);

        if (!empty($this->request->query['filter'])) {
            $this->Users->search($this->request->query['filter'], $users);
        }

        $this->title(__d('user', 'Users List'));
        $this->set('users', $this->paginate($users));
        $this->Breadcrumb->push('/admin/user/manage');
    }
185761
public function index()
    {
        $this->defaultData();
        $userLangService = $this->getServiceLocator()->get(UserLanguageServiceInterface::class);
        $this->setData('user-data-lang-enabled', $userLangService->isDataLanguageEnabled());
        $this->setView('user/list.tpl');
    }
445666
public function render()
    {
        parent::render();

        $soxId = $this->getEditObjectId();

        // all usergroups
        $oGroups = oxNew(\OxidEsales\Eshop\Core\Model\ListModel::class);
        $oGroups->init('oxgroups');
        $oGroups->selectString("select * from " . getViewName("oxgroups", $this->_iEditLang));

        $oRoot = new stdClass();
        $oRoot->oxgroups__oxid = new \OxidEsales\Eshop\Core\Field("");
        $oRoot->oxgroups__oxtitle = new \OxidEsales\Eshop\Core\Field("-- ");
        // rebuild list as we need the "no value" entry at the first position
        $aNewList = [];
        $aNewList[] = $oRoot;

        foreach ($oGroups as $val) {
            $aNewList[$val->oxgroups__oxid->value] = new stdClass();
            $aNewList[$val->oxgroups__oxid->value]->oxgroups__oxid = new \OxidEsales\Eshop\Core\Field($val->oxgroups__oxid->value);
            $aNewList[$val->oxgroups__oxid->value]->oxgroups__oxtitle = new \OxidEsales\Eshop\Core\Field($val->oxgroups__oxtitle->value);
        }

        $this->_aViewData["allgroups2"] = $aNewList;

        if (isset($soxId) && $soxId != "-1") {
            $oDiscount = oxNew(\OxidEsales\Eshop\Application\Model\Discount::class);
            $oDiscount->load($soxId);

            if ($oDiscount->isDerived()) {
                $this->_aViewData["readonly"] = true;
            }
        }

        $iAoc = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("aoc");
        if ($iAoc == 1) {
            $oDiscountGroupsAjax = oxNew(\OxidEsales\Eshop\Application\Controller\Admin\DiscountGroupsAjax::class);
            $this->_aViewData['oxajax'] = $oDiscountGroupsAjax->getColumns();

            return "popups/discount_groups.tpl";
        } elseif ($iAoc == 2) {
            $oDiscountUsersAjax = oxNew(\OxidEsales\Eshop\Application\Controller\Admin\DiscountUsersAjax::class);
            $this->_aViewData['oxajax'] = $oDiscountUsersAjax->getColumns();

            return "popups/discount_users.tpl";
        }

        return "discount_users.tpl";
    }
832996
public function user() {
		$user = (int) $this->request->param('ID');
		
		$since = $this->owner->getRequest()->getVar('since');
		$offset = (int) $this->owner->getRequest()->getVar('before');
		if (!$offset) {
			$offset = false;
		}
		$filter = array('OwnerID' => $user);
		$tags = $this->getFilterTags();
		$target = $this->getTargetFilter();
		if ($target) {
			$filter['Target'] = $target;
		}
		
		$sort = $this->request->getVar('sort');
		if (!$sort) {
			$sort = 'ID';
		}
		
		
		$data = $this->owner->microBlogService->getStatusUpdates($filter, $sort, $since, $offset, $toplevel = true, $tags);
		
		$props = array(
			'Posts' => $data, 
			'Options' => $this->getOptions(),
			'QueryOffset'	=> $data->QueryOffset,
			'Target'		=> $target,
			'SortBy'		=> $sort
		);
		
		$timeline = trim($this->customise($props)->renderWith('Timeline'));

		if (Director::is_ajax()) {
			return $timeline;
		}

		$data = array(
			'Timeline'		=> '<strong>WARNING: USER VIEWS ARE IN ALPHA </strong>' . $timeline,
			'OwnerFeed'		=> $timeline,
		);

		return $this->customise($data)->renderWith(array('FullTimeline', 'Page'));
	}
75726
public function render()
    {
        parent::render();

        $soxId = $this->getEditObjectId();
        if (isset($soxId) && $soxId != "-1") {
            // load object
            $oUser = oxNew(\OxidEsales\Eshop\Application\Model\User::class);
            $oUser->load($soxId);

            // load adress
            $sAddressIdParameter = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("oxaddressid");
            $soxAddressId = isset($this->sSavedOxid) ? $this->sSavedOxid : $sAddressIdParameter;
            if ($soxAddressId != "-1" && isset($soxAddressId)) {
                $oAdress = oxNew(\OxidEsales\Eshop\Application\Model\Address::class);
                $oAdress->load($soxAddressId);
                $this->_aViewData["edit"] = $oAdress;
            }

            $this->_aViewData["oxaddressid"] = $soxAddressId;

            // generate selected
            $oAddressList = $oUser->getUserAddresses();
            foreach ($oAddressList as $oAddress) {
                if ($oAddress->oxaddress__oxid->value == $soxAddressId) {
                    $oAddress->selected = 1;
                    break;
                }
            }

            $this->_aViewData["edituser"] = $oUser;
        }

        $oCountryList = oxNew(\OxidEsales\Eshop\Application\Model\CountryList::class);
        $oCountryList->loadActiveCountries(\OxidEsales\Eshop\Core\Registry::getLang()->getObjectTplLanguage());

        $this->_aViewData["countrylist"] = $oCountryList;

        if (!$this->_allowAdminEdit($soxId)) {
            $this->_aViewData['readonly'] = true;
        }

        return "user_address.tpl";
    }
706031
public function printUsers($username, $start_from, $sort_by, $sort_dir, $show_group)
    {
        $userlist_data = [];

        $username = Container::get('hooks')
            ->fire('model.userlist.print_users_start', $username, $start_from, $sort_by, $sort_dir, $show_group);

        // Retrieve a list of user IDs, LIMIT is (really) expensive so we only fetch the
        // IDs here then later fetch the remaining data
        $result = DB::forTable('users')
            ->select('u.id')
            ->tableAlias('u')
            ->whereGt('u.id', 1)
            ->whereNotEqual('u.group_id', ForumEnv::get('FEATHER_UNVERIFIED'));

        if ($username != '') {
            $result = $result->whereLike('u.username', str_replace('*', '%', $username));
        }
        if ($show_group > -1) {
            $result = $result->where('u.group_id', $show_group);
        }

        $result = $result->orderByExpr($sort_by . ' ' . $sort_dir)
            ->orderByAsc('u.id')
            ->limit(50)
            ->offset($start_from);

        $result = Container::get('hooks')->fireDB('model.userlist.print_users_query', $result);
        $result = $result->findMany();

        if ($result) {
            $user_ids = [];
            foreach ($result as $cur_user_id) {
                $user_ids[] = $cur_user_id['id'];
            }

            // Grab the users
            $result['select'] = ['u.id', 'u.username', 'u.title', 'u.num_posts', 'u.registered',
                'g.g_id', 'g.g_user_title'];

            $result = DB::forTable('users')
                ->tableAlias('u')
                ->selectMany($result['select'])
                ->leftOuterJoin(DB::prefix() . 'groups', ['g.g_id', '=', 'u.group_id'], 'g')
                ->whereIn('u.id', $user_ids)
                ->orderByExpr($sort_by . ' ' . $sort_dir)
                ->orderByAsc('u.id');
            $result = Container::get('hooks')->fireDB('model.userlist.print_users_grab_query', $result);
            $result = $result->find_many();

            foreach ($result as $user_data) {
                $userlist_data[] = $user_data;
            }
        }

        $userlist_data = Container::get('hooks')->fire('model.userlist.print_users', $userlist_data);

        return $userlist_data;
    }
600506
function renderRoutes() {
  return (
    <Switch>
      {
        routes.map(route => (
          <Route key={route.path || ''} {...route} />
        ))
      }
    </Switch>
  );
}
493282
public function renderView() {
		$config = $this->getAppContextProperty("config");
		$globalUser = $this->getAppContextProperty("globalUser");
		$pages = $this->getAppContextProperty("pages");
		$page = $this->getAppContextProperty("page");
		$data = $this->getAppContextProperty("data");
		$app_http = $this->getAppContextProperty("app_http");
		$controllerName = $this->getAppContextProperty("controllerName");
		$systemMessages = $this->getAppContextProperty("systemMessages");
		
		include "{$this->getViewPath()}layouts/header.lo.php";
		if (!empty($this->getViewFile())) {
			$parameters = $this->getViewVariables();
			include $this->getViewFile();
		}
		include "{$this->getViewPath()}layouts/footer.lo.php";
	}