diff options
Diffstat (limited to 'js')
20 files changed, 395 insertions, 379 deletions
diff --git a/js/app/app.coffee b/js/app/app.coffee index 9a8e54d6a..2042a9ebf 100644 --- a/js/app/app.coffee +++ b/js/app/app.coffee @@ -30,13 +30,13 @@ angular.module('News', ['OC', 'ui']).config ($provide) -> itemBatchSize: 20 -angular.module('News').run ['Persistence', 'Config', 'FeedBl', -(Persistence, Config, FeedBl) -> +angular.module('News').run ['Persistence', 'Config', 'FeedBusinessLayer', +(Persistence, Config, FeedBusinessLayer) -> Persistence.init() setInterval -> - FeedBl.updateFeeds() + FeedBusinessLayer.updateFeeds() , Config.feedUpdateInterval ] diff --git a/js/app/controllers/feedcontroller.coffee b/js/app/controllers/feedcontroller.coffee index e9171a455..3d8755cad 100644 --- a/js/app/controllers/feedcontroller.coffee +++ b/js/app/controllers/feedcontroller.coffee @@ -22,25 +22,27 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. angular.module('News').controller 'FeedController', -['$scope', '_ExistsError', 'Persistence', 'FolderBl', 'FeedBl', -'SubscriptionsBl', 'StarredBl', 'unreadCountFormatter', -($scope, _ExistsError, Persistence, FolderBl, FeedBl, SubscriptionsBl, -StarredBl, unreadCountFormatter) -> +['$scope', '_ExistsError', 'Persistence', 'FolderBusinessLayer', +'FeedBusinessLayer', 'SubscriptionsBusinessLayer', 'StarredBusinessLayer', +'unreadCountFormatter', +($scope, _ExistsError, Persistence, FolderBusinessLayer, FeedBusinessLayer, +SubscriptionsBusinessLayer, StarredBusinessLayer, unreadCountFormatter) -> class FeedController - constructor: (@_$scope, @_persistence, @_folderBl, @_feedBl, - @_subscriptionsBl, @_starredBl, @_unreadCountFormatter) -> + constructor: (@_$scope, @_persistence, @_folderBusinessLayer, + @_feedBusinessLayer, @_subscriptionsBusinessLayer, + @_starredBusinessLayer, @_unreadCountFormatter) -> @_isAddingFolder = false @_isAddingFeed = false # bind internal stuff to scope - @_$scope.folderBl = @_folderBl - @_$scope.feedBl = @_feedBl - @_$scope.subscriptionsBl = @_subscriptionsBl - @_$scope.starredBl = @_starredBl + @_$scope.folderBusinessLayer = @_folderBusinessLayer + @_$scope.feedBusinessLayer = @_feedBusinessLayer + @_$scope.subscriptionsBusinessLayer = @_subscriptionsBusinessLayer + @_$scope.starredBusinessLayer = @_starredBusinessLayer @_$scope.unreadCountFormatter = @_unreadCountFormatter @@ -58,13 +60,13 @@ StarredBl, unreadCountFormatter) -> @_isAddingFeed = true # set folder to open if parentFolderId != 0 - @_folderBl.open(parentFolderId) - @_feedBl.create feedUrl, parentFolderId + @_folderBusinessLayer.open(parentFolderId) + @_feedBusinessLayer.create feedUrl, parentFolderId # on success , (data) => @_$scope.feedUrl = '' @_isAddingFeed = false - @_feedBl.load(data['feeds'][0].id) + @_feedBusinessLayer.load(data['feeds'][0].id) # on error , => @_isAddingFeed = false @@ -83,7 +85,7 @@ StarredBl, unreadCountFormatter) -> try @_isAddingFolder = true - @_folderBl.create folderName + @_folderBusinessLayer.create folderName # on success , (data) => @@ -91,7 +93,7 @@ StarredBl, unreadCountFormatter) -> @_$scope.addNewFolder = false @_isAddingFolder = false activeId = data['folders'][0].id - @_$scope.folderId = @_folderBl.getById(activeId) + @_$scope.folderId = @_folderBusinessLayer.getById(activeId) # on error , => @_isAddingFolder = false @@ -106,10 +108,11 @@ StarredBl, unreadCountFormatter) -> @_$scope.$on 'moveFeedToFolder', (scope, data) => - @_feedBl.move(data.feedId, data.folderId) + @_feedBusinessLayer.move(data.feedId, data.folderId) - return new FeedController($scope, Persistence, FolderBl, FeedBl, - SubscriptionsBl, StarredBl, unreadCountFormatter) + return new FeedController($scope, Persistence, FolderBusinessLayer, + FeedBusinessLayer, SubscriptionsBusinessLayer, + StarredBusinessLayer, unreadCountFormatter) ]
\ No newline at end of file diff --git a/js/app/controllers/itemcontroller.coffee b/js/app/controllers/itemcontroller.coffee index 52f1c271a..bdc35c855 100644 --- a/js/app/controllers/itemcontroller.coffee +++ b/js/app/controllers/itemcontroller.coffee @@ -22,15 +22,17 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. angular.module('News').controller 'ItemController', -['$scope', 'ItemBl', 'FeedModel', 'FeedLoading', 'FeedBl', 'Language', -($scope, ItemBl, FeedModel, FeedLoading, FeedBl, Language) -> +['$scope', 'ItemBusinessLayer', 'FeedModel', 'FeedLoading', 'FeedBusinessLayer', +'Language', +($scope, ItemBusinessLayer, FeedModel, FeedLoading, FeedBusinessLayer, +Language) -> class ItemController - constructor: (@_$scope, @_itemBl, @_feedModel, @_feedLoading, - @_feedBl, @_language) -> - @_$scope.itemBl = @_itemBl - @_$scope.feedBl = @_feedBl + constructor: (@_$scope, @_itemBusinessLayer, @_feedModel, @_feedLoading, + @_feedBusinessLayer, @_language) -> + @_$scope.itemBusinessLayer = @_itemBusinessLayer + @_$scope.feedBusinessLayer = @_feedBusinessLayer @_$scope.isLoading = => return @_feedLoading.isLoading() @@ -50,6 +52,6 @@ angular.module('News').controller 'ItemController', - return new ItemController($scope, ItemBl, FeedModel, FeedLoading, FeedBl, - Language) + return new ItemController($scope, ItemBusinessLayer, FeedModel, FeedLoading, + FeedBusinessLayer, Language) ]
\ No newline at end of file diff --git a/js/app/controllers/settingscontroller.coffee b/js/app/controllers/settingscontroller.coffee index 3c6a7771e..a1632a761 100644 --- a/js/app/controllers/settingscontroller.coffee +++ b/js/app/controllers/settingscontroller.coffee @@ -22,17 +22,17 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. angular.module('News').controller 'SettingsController', -['$scope', 'FeedBl', 'FolderBl', 'ShowAll', -($scope, FeedBl, FolderBl, ShowAll) -> +['$scope', 'FeedBusinessLayer', 'FolderBusinessLayer', 'ShowAll', +($scope, FeedBusinessLayer, FolderBusinessLayer, ShowAll) -> - $scope.feedBl = FeedBl + $scope.feedBusinessLayer = FeedBusinessLayer $scope.import = (fileContent) => $scope.error = false ShowAll.setShowAll(true) try - FolderBl.import(fileContent) + FolderBusinessLayer.import(fileContent) catch error console.error error $scope.error = true diff --git a/js/app/services/bl/bl.coffee b/js/app/services/businesslayer/businesslayer.coffee index 27e4d321a..7cfbb703c 100644 --- a/js/app/services/bl/bl.coffee +++ b/js/app/services/businesslayer/businesslayer.coffee @@ -21,9 +21,9 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. ### -angular.module('News').factory '_Bl', -> +angular.module('News').factory '_BusinessLayer', -> - class Bl + class BusinessLayer constructor: (@_activeFeed, @_persistence, @_itemModel, @_type) -> @@ -42,4 +42,4 @@ angular.module('News').factory '_Bl', -> return @_activeFeed.getType() == @_type && @_activeFeed.getId() == id - return Bl
\ No newline at end of file + return BusinessLayer
\ No newline at end of file diff --git a/js/app/services/bl/feedbl.coffee b/js/app/services/businesslayer/feedbusinesslayer.coffee index 38aa5bff0..2540cfc5f 100644 --- a/js/app/services/bl/feedbl.coffee +++ b/js/app/services/businesslayer/feedbusinesslayer.coffee @@ -21,13 +21,13 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. ### -angular.module('News').factory 'FeedBl', -['_Bl', 'ShowAll', 'Persistence', 'ActiveFeed', 'FeedType', 'ItemModel', -'FeedModel', 'NewLoading', '_ExistsError', 'Utils', -(_Bl, ShowAll, Persistence, ActiveFeed, FeedType, ItemModel, FeedModel, -NewLoading, _ExistsError, Utils) -> +angular.module('News').factory 'FeedBusinessLayer', +['_BusinessLayer', 'ShowAll', 'Persistence', 'ActiveFeed', 'FeedType', +'ItemModel', 'FeedModel', 'NewLoading', '_ExistsError', 'Utils', +(_BusinessLayer, ShowAll, Persistence, ActiveFeed, FeedType, ItemModel, +FeedModel, NewLoading, _ExistsError, Utils) -> - class FeedBl extends _Bl + class FeedBusinessLayer extends _BusinessLayer constructor: (@_showAll, @_feedModel, persistence, activeFeed, feedType, itemModel, @_newLoading, @_utils) -> @@ -171,7 +171,7 @@ NewLoading, _ExistsError, Utils) -> @_persistence.updateFeed(feed.id) - return new FeedBl(ShowAll, FeedModel, Persistence, ActiveFeed, FeedType, - ItemModel, NewLoading, Utils) + return new FeedBusinessLayer(ShowAll, FeedModel, Persistence, ActiveFeed, + FeedType, ItemModel, NewLoading, Utils) ]
\ No newline at end of file diff --git a/js/app/services/bl/folderbl.coffee b/js/app/services/businesslayer/folderbusinesslayer.coffee index 42c1d9752..969783222 100644 --- a/js/app/services/bl/folderbl.coffee +++ b/js/app/services/businesslayer/folderbusinesslayer.coffee @@ -21,15 +21,15 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. ### -angular.module('News').factory 'FolderBl', -['_Bl', 'FolderModel', 'FeedBl', 'Persistence', 'FeedType', 'ActiveFeed', -'ItemModel', 'ShowAll', '_ExistsError', 'OPMLParser', -(_Bl, FolderModel, FeedBl, Persistence, FeedType, ActiveFeed, -ItemModel, ShowAll, _ExistsError, OPMLParser)-> +angular.module('News').factory 'FolderBusinessLayer', +['_BusinessLayer', 'FolderModel', 'FeedBusinessLayer', 'Persistence', +'FeedType', 'ActiveFeed', 'ItemModel', 'ShowAll', '_ExistsError', 'OPMLParser', +(_BusinessLayer, FolderModel, FeedBusinessLayer, Persistence, FeedType, +ActiveFeed, ItemModel, ShowAll, _ExistsError, OPMLParser) -> - class FolderBl extends _Bl + class FolderBusinessLayer extends _BusinessLayer - constructor: (@_folderModel, @_feedBl, @_showAll, activeFeed, + constructor: (@_folderModel, @_feedBusinessLayer, @_showAll, activeFeed, persistence, @_feedType, itemModel, @_opmlParser) -> super(activeFeed, persistence, itemModel, @_feedType.Folder) @@ -43,7 +43,7 @@ ItemModel, ShowAll, _ExistsError, OPMLParser)-> hasFeeds: (folderId) -> - return @_feedBl.getFeedsOfFolder(folderId).length + return @_feedBusinessLayer.getFeedsOfFolder(folderId).length open: (folderId) -> @@ -66,12 +66,12 @@ ItemModel, ShowAll, _ExistsError, OPMLParser)-> markFolderRead: (folderId) -> - for feed in @_feedBl.getFeedsOfFolder(folderId) - @_feedBl.markFeedRead(feed.id) + for feed in @_feedBusinessLayer.getFeedsOfFolder(folderId) + @_feedBusinessLayer.markFeedRead(feed.id) getUnreadCount: (folderId) -> - return @_feedBl.getFolderUnreadCount(folderId) + return @_feedBusinessLayer.getFolderUnreadCount(folderId) isVisible: (folderId) -> @@ -79,10 +79,10 @@ ItemModel, ShowAll, _ExistsError, OPMLParser)-> return true else if @isActive(folderId) or - @_feedBl.getFolderUnreadCount(folderId) > 0 + @_feedBusinessLayer.getFolderUnreadCount(folderId) > 0 return true if @_activeFeed.getType() == @_feedType.Feed - for feed in @_feedBl.getFeedsOfFolder(folderId) + for feed in @_feedBusinessLayer.getFeedsOfFolder(folderId) if feed.id == @_activeFeed.getId() return true return false @@ -146,13 +146,15 @@ ItemModel, ShowAll, _ExistsError, OPMLParser)-> else try do (item) => - @_feedBl.create(item.getUrl(), parentFolderId) + @_feedBusinessLayer.create(item.getUrl(), + parentFolderId) catch error if not error instanceof _ExistsError console.info error - return new FolderBl(FolderModel, FeedBl, ShowAll, ActiveFeed, Persistence, - FeedType, ItemModel, OPMLParser) + return new FolderBusinessLayer(FolderModel, FeedBusinessLayer, ShowAll, + ActiveFeed, Persistence, FeedType, ItemModel, + OPMLParser) ]
\ No newline at end of file diff --git a/js/app/services/bl/itembl.coffee b/js/app/services/businesslayer/itembusinesslayer.coffee index 6a09400af..294be1f40 100644 --- a/js/app/services/bl/itembl.coffee +++ b/js/app/services/businesslayer/itembusinesslayer.coffee @@ -21,14 +21,16 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. ### -angular.module('News').factory 'ItemBl', -['ItemModel', 'FeedModel', 'Persistence', 'ActiveFeed', 'FeedType', 'StarredBl', -(ItemModel, FeedModel, Persistence, ActiveFeed, FeedType, StarredBl) -> +angular.module('News').factory 'ItemBusinessLayer', +['ItemModel', 'FeedModel', 'Persistence', 'ActiveFeed', 'FeedType', +'StarredBusinessLayer', +(ItemModel, FeedModel, Persistence, ActiveFeed, FeedType, +StarredBusinessLayer) -> - class ItemBl + class ItemBusinessLayer constructor: (@_itemModel, @_feedModel, @_persistence, @_activeFeed, - @_feedType, @_starredBl) -> + @_feedType, @_starredBusinessLayer) -> getAll: -> return @_itemModel.getAll() @@ -59,11 +61,11 @@ angular.module('News').factory 'ItemBl', item = @_itemModel.getById(itemId) if item.isStarred() item.setUnstarred() - @_starredBl.decreaseCount() + @_starredBusinessLayer.decreaseCount() @_persistence.unstarItem(item.feedId, item.guidHash) else item.setStarred() - @_starredBl.increaseCount() + @_starredBusinessLayer.increaseCount() @_persistence.starItem(item.feedId, item.guidHash) @@ -107,7 +109,7 @@ angular.module('News').factory 'ItemBl', - return new ItemBl(ItemModel, FeedModel, Persistence, ActiveFeed, FeedType, - StarredBl) + return new ItemBusinessLayer(ItemModel, FeedModel, Persistence, ActiveFeed, + FeedType, StarredBusinessLayer) ]
\ No newline at end of file diff --git a/js/app/services/bl/starredbl.coffee b/js/app/services/businesslayer/starredbusinesslayer.coffee index 176973e04..656a3befb 100644 --- a/js/app/services/bl/starredbl.coffee +++ b/js/app/services/businesslayer/starredbusinesslayer.coffee @@ -21,11 +21,12 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. ### -angular.module('News').factory 'StarredBl', -['_Bl', 'StarredCount', 'Persistence', 'ActiveFeed', 'FeedType', 'ItemModel', -(_Bl, StarredCount, Persistence, ActiveFeed, FeedType, ItemModel) -> +angular.module('News').factory 'StarredBusinessLayer', +['_BusinessLayer', 'StarredCount', 'Persistence', 'ActiveFeed', 'FeedType', +'ItemModel', +(_BusinessLayer, StarredCount, Persistence, ActiveFeed, FeedType, ItemModel) -> - class StarredBl extends _Bl + class StarredBusinessLayer extends _BusinessLayer constructor: (@_starredCount, feedType, persistence, activeFeed, itemModel) -> @@ -49,6 +50,6 @@ angular.module('News').factory 'StarredBl', decreaseCount: -> @_starredCount.setStarredCount(@_starredCount.getStarredCount() - 1) - return new StarredBl(StarredCount, FeedType, Persistence, + return new StarredBusinessLayer(StarredCount, FeedType, Persistence, ActiveFeed, ItemModel) ] diff --git a/js/app/services/bl/subscriptionsbl.coffee b/js/app/services/businesslayer/subscriptionsbusinesslayer.coffee index 102ae8c44..2f08504eb 100644 --- a/js/app/services/bl/subscriptionsbl.coffee +++ b/js/app/services/businesslayer/subscriptionsbusinesslayer.coffee @@ -21,14 +21,15 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. ### -angular.module('News').factory 'SubscriptionsBl', -['_Bl', 'FeedBl', 'Persistence', 'ShowAll', 'ActiveFeed', 'FeedType', -'ItemModel', -(_Bl, FeedBl, Persistence, ShowAll, ActiveFeed, FeedType, ItemModel) -> +angular.module('News').factory 'SubscriptionsBusinessLayer', +['_BusinessLayer', 'FeedBusinessLayer', 'Persistence', 'ShowAll', 'ActiveFeed', +'FeedType', 'ItemModel', +(_BusinessLayer, FeedBusinessLayer, Persistence, ShowAll, ActiveFeed, FeedType, +ItemModel) -> - class SubscriptionsBl extends _Bl + class SubscriptionsBusinessLayer extends _BusinessLayer - constructor: (@_feedBl, @_showAll, feedType, + constructor: (@_feedBusinessLayer, @_showAll, feedType, persistence, activeFeed, itemModel) -> super(activeFeed, persistence, itemModel, feedType.Subscriptions) @@ -37,21 +38,21 @@ angular.module('News').factory 'SubscriptionsBl', return true if @_showAll.getShowAll() - return @_feedBl.getNumberOfFeeds() > 0 + return @_feedBusinessLayer.getNumberOfFeeds() > 0 else - visible = @_feedBl.getNumberOfFeeds() > 0 && - @_feedBl.getAllUnreadCount() > 0 + visible = @_feedBusinessLayer.getNumberOfFeeds() > 0 && + @_feedBusinessLayer.getAllUnreadCount() > 0 return visible markAllRead: -> - @_feedBl.markAllRead() + @_feedBusinessLayer.markAllRead() getUnreadCount: -> - return @_feedBl.getAllUnreadCount() + return @_feedBusinessLayer.getAllUnreadCount() - return new SubscriptionsBl(FeedBl, ShowAll, FeedType, Persistence, - ActiveFeed, ItemModel) + return new SubscriptionsBusinessLayer(FeedBusinessLayer, ShowAll, FeedType, + Persistence, ActiveFeed, ItemModel) ] diff --git a/js/public/app.js b/js/public/app.js index df081ffb7..ee9ddf02e 100644 --- a/js/public/app.js +++ b/js/public/app.js @@ -47,10 +47,10 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. }); angular.module('News').run([ - 'Persistence', 'Config', 'FeedBl', function(Persistence, Config, FeedBl) { + 'Persistence', 'Config', 'FeedBusinessLayer', function(Persistence, Config, FeedBusinessLayer) { Persistence.init(); return setInterval(function() { - return FeedBl.updateFeeds(); + return FeedBusinessLayer.updateFeeds(); }, Config.feedUpdateInterval); } ]); @@ -218,26 +218,26 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. (function() { angular.module('News').controller('FeedController', [ - '$scope', '_ExistsError', 'Persistence', 'FolderBl', 'FeedBl', 'SubscriptionsBl', 'StarredBl', 'unreadCountFormatter', function($scope, _ExistsError, Persistence, FolderBl, FeedBl, SubscriptionsBl, StarredBl, unreadCountFormatter) { + '$scope', '_ExistsError', 'Persistence', 'FolderBusinessLayer', 'FeedBusinessLayer', 'SubscriptionsBusinessLayer', 'StarredBusinessLayer', 'unreadCountFormatter', function($scope, _ExistsError, Persistence, FolderBusinessLayer, FeedBusinessLayer, SubscriptionsBusinessLayer, StarredBusinessLayer, unreadCountFormatter) { var FeedController; FeedController = (function() { - function FeedController(_$scope, _persistence, _folderBl, _feedBl, _subscriptionsBl, _starredBl, _unreadCountFormatter) { + function FeedController(_$scope, _persistence, _folderBusinessLayer, _feedBusinessLayer, _subscriptionsBusinessLayer, _starredBusinessLayer, _unreadCountFormatter) { var _this = this; this._$scope = _$scope; this._persistence = _persistence; - this._folderBl = _folderBl; - this._feedBl = _feedBl; - this._subscriptionsBl = _subscriptionsBl; - this._starredBl = _starredBl; + this._folderBusinessLayer = _folderBusinessLayer; + this._feedBusinessLayer = _feedBusinessLayer; + this._subscriptionsBusinessLayer = _subscriptionsBusinessLayer; + this._starredBusinessLayer = _starredBusinessLayer; this._unreadCountFormatter = _unreadCountFormatter; this._isAddingFolder = false; this._isAddingFeed = false; - this._$scope.folderBl = this._folderBl; - this._$scope.feedBl = this._feedBl; - this._$scope.subscriptionsBl = this._subscriptionsBl; - this._$scope.starredBl = this._starredBl; + this._$scope.folderBusinessLayer = this._folderBusinessLayer; + this._$scope.feedBusinessLayer = this._feedBusinessLayer; + this._$scope.subscriptionsBusinessLayer = this._subscriptionsBusinessLayer; + this._$scope.starredBusinessLayer = this._starredBusinessLayer; this._$scope.unreadCountFormatter = this._unreadCountFormatter; this._$scope.isAddingFolder = function() { return _this._isAddingFolder; @@ -256,12 +256,12 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. try { _this._isAddingFeed = true; if (parentFolderId !== 0) { - _this._folderBl.open(parentFolderId); + _this._folderBusinessLayer.open(parentFolderId); } - return _this._feedBl.create(feedUrl, parentFolderId, function(data) { + return _this._feedBusinessLayer.create(feedUrl, parentFolderId, function(data) { _this._$scope.feedUrl = ''; _this._isAddingFeed = false; - return _this._feedBl.load(data['feeds'][0].id); + return _this._feedBusinessLayer.load(data['feeds'][0].id); }, function() { return _this._isAddingFeed = false; }); @@ -282,14 +282,14 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. _this._$scope.folderExistsError = false; try { _this._isAddingFolder = true; - return _this._folderBl.create(folderName, function(data) { + return _this._folderBusinessLayer.create(folderName, function(data) { var activeId; _this._$scope.folderName = ''; _this._$scope.addNewFolder = false; _this._isAddingFolder = false; activeId = data['folders'][0].id; - return _this._$scope.folderId = _this._folderBl.getById(activeId); + return _this._$scope.folderId = _this._folderBusinessLayer.getById(activeId); }, function() { return _this._isAddingFolder = false; }); @@ -305,14 +305,14 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. } }; this._$scope.$on('moveFeedToFolder', function(scope, data) { - return _this._feedBl.move(data.feedId, data.folderId); + return _this._feedBusinessLayer.move(data.feedId, data.folderId); }); } return FeedController; })(); - return new FeedController($scope, Persistence, FolderBl, FeedBl, SubscriptionsBl, StarredBl, unreadCountFormatter); + return new FeedController($scope, Persistence, FolderBusinessLayer, FeedBusinessLayer, SubscriptionsBusinessLayer, StarredBusinessLayer, unreadCountFormatter); } ]); @@ -343,21 +343,21 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. (function() { angular.module('News').controller('ItemController', [ - '$scope', 'ItemBl', 'FeedModel', 'FeedLoading', 'FeedBl', 'Language', function($scope, ItemBl, FeedModel, FeedLoading, FeedBl, Language) { + '$scope', 'ItemBusinessLayer', 'FeedModel', 'FeedLoading', 'FeedBusinessLayer', 'Language', function($scope, ItemBusinessLayer, FeedModel, FeedLoading, FeedBusinessLayer, Language) { var ItemController; ItemController = (function() { - function ItemController(_$scope, _itemBl, _feedModel, _feedLoading, _feedBl, _language) { + function ItemController(_$scope, _itemBusinessLayer, _feedModel, _feedLoading, _feedBusinessLayer, _language) { var _this = this; this._$scope = _$scope; - this._itemBl = _itemBl; + this._itemBusinessLayer = _itemBusinessLayer; this._feedModel = _feedModel; this._feedLoading = _feedLoading; - this._feedBl = _feedBl; + this._feedBusinessLayer = _feedBusinessLayer; this._language = _language; - this._$scope.itemBl = this._itemBl; - this._$scope.feedBl = this._feedBl; + this._$scope.itemBusinessLayer = this._itemBusinessLayer; + this._$scope.feedBusinessLayer = this._feedBusinessLayer; this._$scope.isLoading = function() { return _this._feedLoading.isLoading(); }; @@ -383,7 +383,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. return ItemController; })(); - return new ItemController($scope, ItemBl, FeedModel, FeedLoading, FeedBl, Language); + return new ItemController($scope, ItemBusinessLayer, FeedModel, FeedLoading, FeedBusinessLayer, Language); } ]); @@ -414,17 +414,17 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. (function() { angular.module('News').controller('SettingsController', [ - '$scope', 'FeedBl', 'FolderBl', 'ShowAll', function($scope, FeedBl, FolderBl, ShowAll) { + '$scope', 'FeedBusinessLayer', 'FolderBusinessLayer', 'ShowAll', function($scope, FeedBusinessLayer, FolderBusinessLayer, ShowAll) { var _this = this; - $scope.feedBl = FeedBl; + $scope.feedBusinessLayer = FeedBusinessLayer; return $scope["import"] = function(fileContent) { var error; $scope.error = false; ShowAll.setShowAll(true); try { - return FolderBl["import"](fileContent); + return FolderBusinessLayer["import"](fileContent); } catch (_error) { error = _error; console.error(error); @@ -517,18 +517,18 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. |