Model/Document.php
changeset 62 10be6b9e55e7
parent 58 87bf6ec8af90
child 63 774ba82dca59
--- a/Model/Document.php	Fri Dec 09 04:53:56 2011 +0100
+++ b/Model/Document.php	Fri Dec 09 06:43:49 2011 +0100
@@ -20,7 +20,6 @@
     */
     protected $id;
     
-    
     /**
      * @var boolean $manualOrder
      */
@@ -40,6 +39,11 @@
      * @var string tagsStr
      */
     protected $tagsStr;
+        
+   /**
+    * @var DateTime
+    */
+    protected $createdAt;
     
     
     /**
@@ -118,6 +122,25 @@
         return $this->tagsStr;
     }
     
+    /**
+     * (non-PHPdoc)
+     * @see IRI\Bundle\WikiTagBundle\Model.DocumentInterface::getCreatedAt()
+     */
+    function getCreatedAt()
+    {
+        return $this->createdAt;
+    }
+    
+    /**
+    *
+    * construct the class
+    */
+    function __construct()
+    {
+        $this->createdAt = new \DateTime("now", new \DateTimeZone('UTC'));
+    }
+    
+    
     public function __toString()
     {
         return print_r(Debug::export($this, 3),true);