Exemplo n.º 1
0
 function __construct($path, $label, $value = NULL)
 {
     parent::__construct($path, $label);
     if ($value) {
         $this->retrieve($value);
     }
 }
Exemplo n.º 2
0
 function setPath($path)
 {
     parent::setPath($path);
     foreach ((array) $this->value as $child) {
         $child->setPath($this->path . '/' . $child->id);
     }
 }
Exemplo n.º 3
0
 function set($value)
 {
     switch (gettype($value)) {
         case 'null':
         case 'NULL':
             $value = $this->timeToDateArray(time());
             break;
         case 'integer':
             $value = $this->timeToDateArray($value);
             break;
         case 'string':
             $value = $this->timeToDateArray(strtotime($value));
             break;
         case 'array':
             break;
         default:
             throw new Exception("Impossible de récupérer la date {$path}");
     }
     parent::set($value);
 }
Exemplo n.º 4
0
 /**
  *
  * @param string	Pathname
  * @param string	Descriptive label
  * @param string	Default value
  * @param array	Values => Label array
  * @param boolean	Wether to allow multiple selection
  */
 function __construct($path, $label, $value = null, $enum = array(), $multiple = FALSE)
 {
     parent::__construct($path, $label, $value);
     $this->enum = $enum;
     $this->multiple = $multiple;
 }
Exemplo n.º 5
0
 function __construct($path, $label, $value = FALSE)
 {
     parent::__construct($path, $label, $value);
 }
Exemplo n.º 6
0
 function __construct($path, $label, $value = '', $readonly = false)
 {
     parent::__construct($path, $label, $value, $readonly);
 }
Exemplo n.º 7
0
 function __construct($path, $label, $value, $min = 0, $max = PHP_INT_MAX)
 {
     parent::__construct($path, $label, $value);
 }