diff options
author | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2013-04-23 03:36:39 -0400 |
---|---|---|
committer | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2013-04-23 03:36:39 -0400 |
commit | 909b1786a1b0d42e7cb39cf6b18fffe2bc020652 (patch) | |
tree | c70912668414d2940f05ba523f56305facdfc954 /askbot/media | |
parent | d627bd6962d24d04a6cad032a86e5fc71e037ab5 (diff) | |
download | askbot-909b1786a1b0d42e7cb39cf6b18fffe2bc020652.tar.gz askbot-909b1786a1b0d42e7cb39cf6b18fffe2bc020652.tar.bz2 askbot-909b1786a1b0d42e7cb39cf6b18fffe2bc020652.zip |
refactoring of the questions title search view
Diffstat (limited to 'askbot/media')
-rw-r--r-- | askbot/media/js/live_search.js | 2 | ||||
-rw-r--r-- | askbot/media/js/live_search_new_thread.js | 2 | ||||
-rw-r--r-- | askbot/media/js/utils.js | 5 |
3 files changed, 7 insertions, 2 deletions
diff --git a/askbot/media/js/live_search.js b/askbot/media/js/live_search.js index 98e01179..1aebb6ce 100644 --- a/askbot/media/js/live_search.js +++ b/askbot/media/js/live_search.js @@ -461,7 +461,7 @@ FullTextSearch.prototype.sendTitleSearchQuery = function(query_text) { var data = {query_text: query_text}; var me = this; $.ajax({ - url: askbot['urls']['titleSearch'], + url: askbot['urls']['apiGetQuestions'], data: data, dataType: 'json', success: function(data, text_status, xhr){ diff --git a/askbot/media/js/live_search_new_thread.js b/askbot/media/js/live_search_new_thread.js index d17951eb..21b5c876 100644 --- a/askbot/media/js/live_search_new_thread.js +++ b/askbot/media/js/live_search_new_thread.js @@ -2,7 +2,7 @@ var liveSearchNewThreadInit = function(auto_focus_out) { var query = $('input#id_title.questionTitleInput'); var prev_text = $.trim(query.val()); - var search_url = askbot['urls']['titleSearch']; + var search_url = askbot['urls']['apiGetQuestions']; var running = false; var q_list_sel = 'question-list'; //id of question listing div diff --git a/askbot/media/js/utils.js b/askbot/media/js/utils.js index db15b656..f2cc0108 100644 --- a/askbot/media/js/utils.js +++ b/askbot/media/js/utils.js @@ -54,6 +54,11 @@ var getSingletonController = function(controllerClass, name) { return controller; }; +var setController = function(controller, name) { + askbot['controllers'] = askbot['controllers'] || {}; + askbot['controllers'][name] = controller; +}; + var getUniqueValues = function(values) { var uniques = new Object(); var out = new Array(); |