Open Monograph Press  1.1
 All Classes Namespaces Functions Variables Groups Pages
MultilingualListbuilderGridColumn.inc.php
1 <?php
2 
17 import('lib.pkp.classes.controllers.listbuilder.ListbuilderGridColumn');
18 
23  function MultilingualListbuilderGridColumn($listbuilder, $id = '', $title = null,
24  $titleTranslated = null, $template = null, $cellProvider = null,
25  $availableLocales = null, $flags = array()) {
26 
27  // Make sure this is a text input
28  assert($listbuilder->getSourceType() == LISTBUILDER_SOURCE_TYPE_TEXT);
29 
30  // Provide a default set of available locales if not specified
31  if (!$availableLocales) $availableLocales = AppLocale::getSupportedFormLocales();
32 
33  // Set some flags for multilingual support
34  $flags['multilingual'] = true; // This is a multilingual column.
35  $flags['availableLocales'] = $availableLocales; // Provide available locales
36 
37  parent::ListbuilderGridColumn($listbuilder, $id, $title, $titleTranslated, $template, $cellProvider, $flags);
38  }
39 }
40 
41 ?>
Represents a column within a listbuilder.
Represents a multilingual text column within a listbuilder.
MultilingualListbuilderGridColumn($listbuilder, $id= '', $title=null, $titleTranslated=null, $template=null, $cellProvider=null, $availableLocales=null, $flags=array())
static getSupportedFormLocales()