diff options
author | Bernhard Posselt <nukeawhale@gmail.com> | 2013-04-04 21:18:43 +0200 |
---|---|---|
committer | Bernhard Posselt <nukeawhale@gmail.com> | 2013-04-04 21:18:43 +0200 |
commit | 76267670f3dcb6793a62a30477db830f482b4495 (patch) | |
tree | 92e42518925cfe367070163f5377db24a1f5de6c /js/public | |
parent | 346346e01c5c61e61b522520248de90e0ede3f17 (diff) |
finished feedbl methods
Diffstat (limited to 'js/public')
-rw-r--r-- | js/public/app.js | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/js/public/app.js b/js/public/app.js index c4aa53323..bdb196fbf 100644 --- a/js/public/app.js +++ b/js/public/app.js @@ -697,6 +697,27 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. return this._feedModel.size(); }; + FeedBl.prototype.isVisible = function(feedId) { + if (this.isActive(feedId) || this._showAll.getShowAll()) { + return true; + } else { + return this._feedModel.getFeedUnreadCount(feedId) > 0; + } + }; + + FeedBl.prototype.move = function(feedId, folderId) { + var feed; + feed = this._feedModel.getById(feedId); + if (angular.isDefined(feed) && feed.folderId !== folderId) { + this._feedModel.update({ + id: feedId, + folderId: folderId, + urlHash: feed.urlHash + }); + return this._persistence.moveFeed(feedId, folderId); + } + }; + return FeedBl; })(_Bl); |