reinstalled all contribs with composer
need to run : drush ev 'drupal_flush_all_caches();' drush cr and restart nginx and php-fpm before loading the website
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
namespace Drupal\edlp_fils\Controller;
|
||||
|
||||
use Drupal\Core\Controller\ControllerBase;
|
||||
// use Drupal\Core\Datetime\DrupalDateTime;
|
||||
use Symfony\Component\HttpFoundation\JsonResponse;
|
||||
|
||||
|
||||
class FilsController extends ControllerBase {
|
||||
|
||||
/**
|
||||
* Display productions as a page.
|
||||
*
|
||||
* @return renderable array
|
||||
*/
|
||||
public function fils() {
|
||||
return array(
|
||||
"#markup"=>"Edlp Fils"
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get agenda data as json through ajax.
|
||||
*
|
||||
* @return json
|
||||
*/
|
||||
public function filsjson() {
|
||||
|
||||
$response = new JsonResponse();
|
||||
$renderable = array(
|
||||
"#markup"=>"Edlp Fils"
|
||||
);
|
||||
$rendered = render($renderable);
|
||||
|
||||
$response->setData([
|
||||
'test'=>'hello',
|
||||
'rendered'=> $rendered
|
||||
]);
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user