Ejemplo n.º 1
0
 /**
  * If a Renderable object has tried to use a empty variable it returns true otherwise and when no variable
  * is used false. Needed for the Group element.
  *
  * @return boolean|null
  */
 public function hasAccessEmptyVariable()
 {
     if ($this->render instanceof Groupable == true) {
         return $this->render->hasAccessEmptyVariable();
     }
     return null;
 }
Ejemplo n.º 2
0
 /**
  * Renders the date part, if a value is set.
  *
  * @param array $data Array with the keys: month, day, year
  * @return string
  */
 public function render($data)
 {
     if (isset($data[$this->name]) == false || $data[$this->name] == '') {
         return '';
     }
     $value = $this->render->render($data[$this->name]);
     $value = $this->formatting->render($value);
     $value = $this->textCase->render($value);
     // Attributes for affixes are allowed, unless cs:date calls a localized date format
     if (Container::getContext()->get('form', 'date') !== '') {
         $value = $this->affix->render($value);
     }
     return $value;
 }