From 3d3618d97c7ef1fbfe2a45218237ccdcd4396d7d Mon Sep 17 00:00:00 2001 From: Marien Fressinaud Date: Tue, 12 Mar 2013 18:20:41 +0100 Subject: Correction bug gestion de l'id pour Feed et Entry --- app/models/Entry.php | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'app/models/Entry.php') diff --git a/app/models/Entry.php b/app/models/Entry.php index 4cdcf8265..4790a1681 100755 --- a/app/models/Entry.php +++ b/app/models/Entry.php @@ -1,6 +1,7 @@ guid . Configuration::selApplication ()); + if(is_null($this->id)) { + return small_hash ($this->guid . Configuration::selApplication ()); + } else { + return $this->id; + } } public function guid () { return $this->guid; @@ -63,7 +68,10 @@ class Entry extends Model { return $this->feed; } } - + + public function _id ($value) { + $this->id = $value; + } public function _guid ($value) { $this->guid = $value; } @@ -370,6 +378,10 @@ class HelperEntry { $dao['is_read'], $dao['is_favorite'] ); + + if (isset ($dao['id'])) { + $list[$key]->_id ($dao['id']); + } } return $list; -- cgit v1.2.3