Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

datetime-field.inc.php

Go to the documentation of this file.
00001 <?php
00008 class DateTimeField extends CollectionField
00009 {
00016     public function __construct($name, Form &$parentForm, array $attribs = array('mode' => 12))
00017     {
00018         $attribs['fields'] = array(
00019             array('DateField', "${name}_date", $attribs),
00020             array('TimeField', "${name}_time", $attribs)
00021         );
00022 
00023         parent::__construct($name, $parentForm, $attribs);
00024     }
00025 
00030     public function setData($value)
00031     {
00032         $this->fields[0]->setData($value);
00033         $this->fields[1]->setData($value);
00034     }
00035     
00040     public function getData()
00041     {
00042         return $this->fields[0]->getData() . ' ' . $this->fields[1]->getData();
00043     }
00044 
00049     public function getSqlImpl()
00050     {
00051         return $this->name . '=\'' . $this->getData() . '\'';
00052     }
00053 }
00054 ?>

Generated on Fri Oct 27 12:26:39 2006 for BaseJumper by doxygen 1.3.9.1