diff options
author | Alessandro Cosentino <cosenal@gmail.com> | 2013-03-03 22:27:18 +0100 |
---|---|---|
committer | Alessandro Cosentino <cosenal@gmail.com> | 2013-03-03 22:27:18 +0100 |
commit | ef450898bb702877dafb755e425fe8f37b23417b (patch) | |
tree | 53162b432a7f5a6c9d99d9eb77aee30d670853ae /db/folder.php | |
parent | 0852773340ed26ecc8faa8e61192f38132673bc6 (diff) |
create folder api call
Diffstat (limited to 'db/folder.php')
-rw-r--r-- | db/folder.php | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/db/folder.php b/db/folder.php index 23d33737f..5dfa738f3 100644 --- a/db/folder.php +++ b/db/folder.php @@ -51,6 +51,12 @@ class Folder extends Collection { public function setOpened($opened) { $this->opened = $opened; } + + public function setParentId() { + if ($this->parent !== null) { + + } + } public function getParentId() { if ($this->parent === null) { @@ -73,7 +79,12 @@ class Folder extends Collection { public function jsonSerialize() { //TODO: this is just for test - return $this->name; + $encoding = array( + 'id' => $this->getId(), + 'parentId' => $this->getParentId(), + 'title' => $this->getName(), + ); + return $encoding; } }
\ No newline at end of file |