From 15c4ed6bebdeb277c24bd92dab5bba900fc90de4 Mon Sep 17 00:00:00 2001 From: François Schmidts Date: Mon, 25 Jan 2016 13:14:06 +0100 Subject: redoing constant, handling read / unread in menu, removing bad optim for loading articles --- src/web/js/actions/MenuActions.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/web/js/actions/MenuActions.js') diff --git a/src/web/js/actions/MenuActions.js b/src/web/js/actions/MenuActions.js index 1f1eea01..bf039fd1 100644 --- a/src/web/js/actions/MenuActions.js +++ b/src/web/js/actions/MenuActions.js @@ -1,5 +1,5 @@ var JarrDispatcher = require('../dispatcher/JarrDispatcher'); -var MenuActionTypes = require('../constants/JarrConstants').MenuActionTypes; +var ActionTypes = require('../constants/JarrConstants'); var jquery = require('jquery'); @@ -8,7 +8,7 @@ var MenuActions = { reload: function() { jquery.getJSON('/menu', function(payload) { JarrDispatcher.dispatch({ - type: MenuActionTypes.RELOAD_MENU, + type: ActionTypes.RELOAD_MENU, categories: payload.categories, feed_in_error: payload.feed_in_error, all_unread_count: payload.all_unread_count, @@ -17,19 +17,19 @@ var MenuActions = { }, setFilterAll: function() { JarrDispatcher.dispatch({ - type: MenuActionTypes.MENU_FILTER, + type: ActionTypes.MENU_FILTER, filter: 'all', }); }, setFilterUnread: function() { JarrDispatcher.dispatch({ - type: MenuActionTypes.MENU_FILTER, + type: ActionTypes.MENU_FILTER, filter: 'unread', }); }, setFilterError: function() { JarrDispatcher.dispatch({ - type: MenuActionTypes.MENU_FILTER, + type: ActionTypes.MENU_FILTER, filter: 'error', }); }, -- cgit