You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@archiva.apache.org by ol...@apache.org on 2014/01/16 00:32:16 UTC
svn commit: r1558608 -
/archiva/trunk/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/search.js
Author: olamy
Date: Wed Jan 15 23:32:15 2014
New Revision: 1558608
URL: http://svn.apache.org/r1558608
Log:
simple hack to avoid weird effect of typeahead local caching
Modified:
archiva/trunk/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/search.js
Modified: archiva/trunk/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/search.js
URL: http://svn.apache.org/viewvc/archiva/trunk/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/search.js?rev=1558608&r1=1558607&r2=1558608&view=diff
==============================================================================
--- archiva/trunk/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/search.js (original)
+++ archiva/trunk/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/search.js Wed Jan 15 23:32:15 2014
@@ -33,7 +33,7 @@ define("archiva.search",["jquery","jquer
this.repositoryId=repositoryId;
this.feedsUrl=feedsUrl;
displayGroupId=function(groupId){
- $.log("BrowseViewModel#displayGroupId,self.repositoryId:"+self.repositoryId);
+ $.log("BrowseViewModel#displayGroupId"+groupId+",self.repositoryId:"+self.repositoryId);
if(self.repositoryId){
window.sammyArchivaApplication.setLocation("#browse~"+self.repositoryId+"/"+groupId);
} else {
@@ -1209,6 +1209,7 @@ define("archiva.search",["jquery","jquer
success: function(applicationUrl){
var mainContent = $("#main-content");
+ mainContent.empty();
mainContent.html($("#browse-tmpl" ).tmpl());
mainContent.find("#browse_result").html(mediumSpinnerImg());
var parentBrowseViewModel=new BrowseViewModel(null,null,groupId,repositoryId);
@@ -1439,9 +1440,11 @@ define("archiva.search",["jquery","jquer
browseBox.typeahead(
{
- name: 'browse-result',
+ name: 'browse-result-'+$.now() ,////hack to avoid local storage caching
+ local: [],
remote: {
url: url,
+ cache: false,
beforeSend: function(jqXhr){
$.log("beforeSend browseBox.val():'"+browseBox.val()+"'");
},