Render client list for the current instance

@return \Symfony\Component\HttpFoundation\RedirectResponse
4597
public function clientAction()
    {
        $worker = $this->getWorker();
        // Worker can be undefined if server went away
        // For the current instance or if we have no instance selected
        if(!$worker) {
            return new RedirectResponse($this->generateUrl('ringo_php_redmon'));
        }
        return $this->render(
            $this->getTemplatePath().'client.html.twig',
            array(
                'instance' => $worker->getInstance(),
                'clients'=> $worker->getClients()
            )
        );
    }
968533
public function clients()
    {
        if (is_null($this->clientRequests)) {
            $this->clientRequests = new ClientRequests($this->client);
        }

        return $this->clientRequests;
    }
1317862
protected function clientRenderPages()
    {
        /** @var TClientUI $page */
        $page = Eresus_Kernel::app()->getPage();
        $result = $page->pages($this->pagesCount, $this->settings['itemsPerPage'],
            $this->table['sortDesc']);
        return $result;
    }
1144508
public function render()
    {
        // Massage the response from base controller subclassings of sidebar
        $items = array_map(function ($item) {

            // If a listing instance, apply defaults common to all sidebar instances
            if (is_a($item, 'Bkwld\Decoy\Fields\Listing')) {
                return $item->layout('sidebar')->parent($this->parent)->__toString();
            }

            // Anything else will be converted to a string in the next step
            return $item;
        }, array_merge($this->items, $this->ending_items));

        // Combine all listing items into a single string and return
        return array_reduce($items, function ($carry, $item) {
            return $carry.$item;
        }, '');
    }
112192
public function configurationAction()
    {
        $worker = $this->getWorker();
        // Worker can be undefined if server went away
        // For the current instance or if we have no instance selected
        if(!$worker) {
            return new RedirectResponse($this->generateUrl('ringo_php_redmon'));
        }
        
        return $this->render(
            $this->getTemplatePath().'configuration.html.twig',
            array(
                'instance' => $worker->getInstance(),
                'configs'  => $worker->getConfiguration()
            )
        );
    }
569877
public function getList()
    {
        $request = new ListDirtyWordRequest();
        $response = new BaseResponse();
        return $this->client->sendRequest($request, $response);
    }
958599
public function getActiveClients()
    {
        $result = $this->getClients();
        if ( $result->isSuccess() ) {
            $clients = array();
            foreach ($result->data as $client) {
                if ($client->active == "true") {
                    $clients[$client->id] = $client;
                }
            }
            $result->data = $clients;
        }

        return $result;
    }
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 );
    }
524320
public function listAction()
    {
        $user = $this->getUser();
        $repository = $this->get('ekyna_user.address.repository');

        $addresses = $repository->findByUser($user);

        return $this->render('EkynaUserBundle:Address:list.html.twig', [
            'addresses' => $addresses
        ]);
    }
1199713
public function buildClient()
    {
        //Handle redirect configuration for guzzle 6
        if (class_exists('\GuzzleHttp\Psr7\Request')) {
            $options = ['allow_redirects' => false];
        } else {
            $options = [
                'defaults' => [
                    'allow_redirects' => false
                ]
            ];
        }

        $this->client = new Client(
            $options
        );
    }
634422
public function render()
    {
        if ($this->isAfterLastPage()) {
            $this->invokeFinishers();
            $parentResponse = $this->response->getParentResponse();
            if ($parentResponse !== null) {
                foreach ($this->response->getHeaders()->getAll() as $key => $value) {
                    $parentResponse->getHeaders()->set($key, $value, true);
                }
            }
            return $this->response->getContent();
        }

        $this->formState->setLastDisplayedPageIndex($this->currentPage->getIndex());

        if ($this->formDefinition->getRendererClassName() === null) {
            throw new RenderingException(sprintf('The form definition "%s" does not have a rendererClassName set.', $this->formDefinition->getIdentifier()), 1326095912);
        }
        $rendererClassName = $this->formDefinition->getRendererClassName();
        $renderer = new $rendererClassName();
        if (!($renderer instanceof RendererInterface)) {
            throw new RenderingException(sprintf('The renderer "%s" des not implement RendererInterface', $rendererClassName), 1326096024);
        }

        $controllerContext = $this->getControllerContext();
        $renderer->setControllerContext($controllerContext);

        $renderer->setFormRuntime($this);
        return $renderer->renderRenderable($this);
    }
1210135
public function render()
    {
        parent::render();

        // performing redirect if needed
        $this->redirectAfterLogin();

        // is logged in ?
        $user = $this->getUser();
        $passwordField = 'oxuser__oxpassword';
        if (!$user || ($user && !$user->$passwordField->value) ||
            ($this->isEnabledPrivateSales() && $user && (!$user->isTermsAccepted() || $this->confirmTerms()))
        ) {
            $this->_sThisTemplate = $this->_getLoginTemplate();
        }

        return $this->_sThisTemplate;
    }
358843
public function indexAction()
    {
        // Get all instances
        $instances = $this->getManager()->findAll();
        
        $worker = $this->get('ringo_php_redmon.instance_worker');
        if(is_array($instances)) {
            foreach($instances as $index => $instance) {
                // Ping server and get potential error message
                $working = $worker->setInstance($instance)->ping();
                $instances[$index]->setWorking($working);
                $instances[$index]->setError($worker->getMessage());
            }
        }
        
        return $this->render(
            $this->getTemplatePath().'index.html.twig',
            array(
                'instances' => $instances 
            )
        );
    }
1128103
public function indexAction()
    {
        $response = $this->response;

        $mainPage = new \stdClass();
        $mainPage->services = $this->determineServices(
            $this->restUtils->getOptionRoutes()
        );

        $mainPage->thirdparty = $this->registerThirdPartyServices();

        $response->setContent(json_encode($mainPage));
        $response->setStatusCode(Response::HTTP_OK);
        $response->headers->set('Link', $this->prepareLinkHeader());

        // todo: make sure, that the correct content type is set.
        // todo: this should be covered by a kernel.response event listener?
        $response->headers->set('Content-Type', 'application/json');

        return $response;
    }
1045770
public function render() {

		$type = $this->getEntityType();
		$options = $this->getOptions();

		$options['base_url'] = $this->getBaseURL();
		$options['list_id'] = $this->getId();

		$list = elgg_list_entities($options, $this->getter);
		$list = elgg_format_element('div', [
			'class' => 'elgg-sortable-list-view',
		], $list);
		
		if (empty($this->search_query) && empty($this->filters) && !preg_match_all("/<ul.*>.*<\/ul>/s", $list)) {
			// List is empty
			return $list;
		}

		$sort_options = (array) elgg_extract('sort_options', $options, $this->getSortOptions());
		$filter_options = (array) elgg_extract('filter_options', $options, $this->getFilterOptions());
		$subtype_options = (array) elgg_extract('subtype_options', $options, $this->getSubtypeOptions());

		$show_subtype = elgg_extract('show_subtype', $options, false) && !empty($subtype_options);
		$show_sort = elgg_extract('show_sort', $options, false) && !empty($sort_options);
		$show_search = elgg_extract('show_search', $options, false);
		if (isset($options['show_rel'])) {
			// BC
			$show_filter = $options['show_rel'] && !empty($filter_options);
		} else {
			$show_filter = elgg_extract('show_filter', $options, false) && !empty($filter_options);
		}

		$form = '';
		if ($show_sort || $show_search || $show_filter || $show_subtype) {

			$form_vars = [
				'entity_type' => $this->getEntityType(),
				'show_sort' => $show_sort,
				'show_search' => $show_search,
				'show_filter' => $show_filter,
				'show_subtype' => $show_subtype,
				'filter' => array_map(function($e) {
					return $e['filter'];
				}, $this->filters),
				'query' => $this->search_query,
				'sort' => array_map(function($e) {
					return strtolower("{$e['field']}::{$e['direction']}");
				}, $this->sorts),
				'sort_options' => $sort_options,
				'filter_options' => $filter_options,
				'subtype_options' => $subtype_options,
				'expand_form' => elgg_extract('expand_form', $options),
			];

			$form = elgg_view_form('lists/sort', array(
				'action' => $this->getBaseURL(),
				'method' => 'GET',
				'disable_security' => true,
				'class' => 'elgg-form-sortable-list',
			), $form_vars);
		}

		echo elgg_format_element('div', [
			'id' => "$type-sort-{$this->getId()}",
			'class' => "elgg-sortable-list $type-sort-list",
		], $form . $list);
	}
904145
public function clientListURL()
    {
        $url = $this->clientURL();

        /* @var TClientUI $page */
        $page = Eresus_Kernel::app()->getPage();
        if ($page->subpage)
        {
            $url .= 'p' . $page->subpage . '/';
        }

        return $url;
    }
373237
public function render(): string
    {
        $this->checkRoutesValidity($this->getAttribute('routes'));
        $this->checkIfAtLeastOneColumnIsDeclared();
        $this->checkDestroyAttributesDefinition();
        $this->handleRequest();
        $this->generateEntitiesListFromQuery();

        return view('tablelist::table', ['table' => $this]);
    }