CMSConnector
extends ControllerBase
in package
Connector to the CMS JSON API.
Table of Contents
Properties
- $cache : CacheBackendInterface
- The Drupal Cache API service.
- $dateFormatter : DateFormatterInterface
- The date formatter service.
- $helper : Helper
- Helper functions.
- $httpClient : Client
- Guzzle\Client instance.
- $prepare : Prepare
- Prepare and format data.
- $request : RequestStack
- Symfony Request stack.
- $sessionHelper : Session
- Session Helper class.
- $stateService : StateInterface
- The Drupal State API service.
Methods
- __construct() : mixed
- CMSConnector constructor.
- getCmsData() : mixed
- Custom function to get data from the event management application.
- getFieldList() : mixed
- Custom function to get data from a field.
- getFieldValue() : mixed
- Custom function that returns the name of the given field_name and id.
- getOptions() : mixed
- Custom function that returns a list of options to be used in a form select.
- getSession() : mixed
- Get session by id.
- getSessionHelper() : mixed
- Get sessionHelper instance.
- getSessionModerators() : mixed
- Get Session Moderators.
- getSessions() : mixed
- Get sessions by year.
- getSessionSpeakers() : mixed
- Get Session Speakers.
- getSessionTestimonials() : mixed
- Get Video testimonials.
- getSideEvent() : mixed
- Get side events by id.
- getSideEvents() : mixed
- Get side events by year.
- getSpeakerTeaser() : mixed
- Return a speaker teaser for the provided speaker id.
- proccessOptionsItems() : mixed
- Proccess options items.
Properties
$cache
The Drupal Cache API service.
protected
CacheBackendInterface
$cache
$dateFormatter
The date formatter service.
protected
DateFormatterInterface
$dateFormatter
$helper
Helper functions.
protected
Helper
$helper
$httpClient
Guzzle\Client instance.
protected
Client
$httpClient
$prepare
Prepare and format data.
protected
Prepare
$prepare
$request
Symfony Request stack.
protected
RequestStack
$request
$sessionHelper
Session Helper class.
protected
Session
$sessionHelper
$stateService
The Drupal State API service.
protected
StateInterface
$stateService
Methods
__construct()
CMSConnector constructor.
public
__construct(Prepare $prepare, Helper $helper, StateInterface $stateService, CacheBackendInterface $cache, Client $http_client, RequestStack $request_stack, DateFormatterInterface $date_formatter, Session $sessionHelper) : mixed
Parameters
- $prepare : Prepare
-
Prepare and format data.
- $helper : Helper
-
Helper functions.
- $stateService : StateInterface
-
Drupal State API service.
- $cache : CacheBackendInterface
-
Drupal Cache API service.
- $http_client : Client
-
Guzzle\Client instance.
- $request_stack : RequestStack
-
Symfony Request stack.
- $date_formatter : DateFormatterInterface
-
Drupal Date formatter.
- $sessionHelper : Session
-
SessionHelper instance.
getCmsData()
Custom function to get data from the event management application.
public
getCmsData(mixed $method[, mixed $filter = NULL ][, mixed $year = 2019 ]) : mixed
Parameters
- $method : mixed
- $filter : mixed = NULL
- $year : mixed = 2019
getFieldList()
Custom function to get data from a field.
public
getFieldList(mixed $method, mixed $field_name, mixed $year) : mixed
Parameters
- $method : mixed
- $field_name : mixed
- $year : mixed
getFieldValue()
Custom function that returns the name of the given field_name and id.
public
getFieldValue(mixed $method, mixed $field_name[, mixed $filter = NULL ]) : mixed
Parameters
- $method : mixed
- $field_name : mixed
- $filter : mixed = NULL
getOptions()
Custom function that returns a list of options to be used in a form select.
public
getOptions(mixed $method[, mixed $year = 2019 ][, mixed $field_name = NULL ][, mixed $value_type = 'id' ][, mixed $sort = 'key' ]) : mixed
Parameters
- $method : mixed
- $year : mixed = 2019
- $field_name : mixed = NULL
- $value_type : mixed = 'id'
- $sort : mixed = 'key'
getSession()
Get session by id.
public
getSession(mixed $id) : mixed
Parameters
- $id : mixed
getSessionHelper()
Get sessionHelper instance.
public
getSessionHelper() : mixed
getSessionModerators()
Get Session Moderators.
public
getSessionModerators(mixed $data) : mixed
Parameters
- $data : mixed
getSessions()
Get sessions by year.
public
getSessions(mixed $year) : mixed
Parameters
- $year : mixed
getSessionSpeakers()
Get Session Speakers.
public
getSessionSpeakers(mixed $data) : mixed
Parameters
- $data : mixed
getSessionTestimonials()
Get Video testimonials.
public
getSessionTestimonials(mixed $data) : mixed
Parameters
- $data : mixed
getSideEvent()
Get side events by id.
public
getSideEvent(mixed $id) : mixed
Parameters
- $id : mixed
getSideEvents()
Get side events by year.
public
getSideEvents(mixed $year) : mixed
Parameters
- $year : mixed
getSpeakerTeaser()
Return a speaker teaser for the provided speaker id.
public
getSpeakerTeaser(mixed $id) : mixed
Parameters
- $id : mixed
proccessOptionsItems()
Proccess options items.
public
proccessOptionsItems(mixed $items, mixed $field_name, mixed $value_type) : mixed
Parameters
- $items : mixed
- $field_name : mixed
- $value_type : mixed