Big refactoring of the Json handling, I followed what I did from OPDS. It doesn't still feel right but I think it's better.
This commit is contained in:
parent
3f5dd74361
commit
91aa062860
5 changed files with 219 additions and 216 deletions
10
base.php
10
base.php
|
@ -337,10 +337,6 @@ class Entry
|
|||
return "#";
|
||||
}
|
||||
|
||||
public function getContentArray () {
|
||||
return array ( "title" => $this->title, "content" => $this->content, "navlink" => $this->getNavLink () );
|
||||
}
|
||||
|
||||
public function __construct($ptitle, $pid, $pcontent, $pcontentType, $plinkArray, $pclass = "") {
|
||||
global $config;
|
||||
$this->title = $ptitle;
|
||||
|
@ -375,12 +371,6 @@ class EntryBook extends Entry
|
|||
$this->localUpdated = $pbook->timestamp;
|
||||
}
|
||||
|
||||
public function getContentArray () {
|
||||
$entry = array ( "title" => $this->title);
|
||||
$entry ["book"] = $this->book->getContentArray ();
|
||||
return $entry;
|
||||
}
|
||||
|
||||
public function getCoverThumbnail () {
|
||||
foreach ($this->linkArray as $link) {
|
||||
if ($link->rel == Link::OPDS_THUMBNAIL_TYPE)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue