mirror of https://github.com/apache/archiva.git
add route to edit group directly
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1410357 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
33b6f95108
commit
f27178e792
|
@ -677,6 +677,14 @@ function(jquery,ui,sammy,tmpl,i18n,jqueryCookie,bootstrap,archivaSearch,jqueryVa
|
|||
displayRepositoriesGrid(function(managedRepositoriesViewModel){managedRepositoriesViewModel.editManagedRepositoryWithId(repositoryId)});
|
||||
});
|
||||
|
||||
this.get("#repositorygroupedit/:groupId",function(){
|
||||
var groupId=this.params.groupId;
|
||||
$.log("edit repository group:"+groupId);
|
||||
displayRepositoryGroups(function(repositoryGroupsViewModel){repositoryGroupsViewModel.editRepositoryGroupWithId(groupId)});
|
||||
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
};
|
||||
|
||||
|
|
|
@ -127,6 +127,15 @@ function(jquery,i18n,jqueryTmpl,bootstrap,jqueryValidate,jqueryUi,ko) {
|
|||
});
|
||||
}
|
||||
|
||||
this.editRepositoryGroupWithId=function(repositoryGroupId){
|
||||
|
||||
$.each(self.repositoryGroups(), function(index, value) {
|
||||
if(value.id()==repositoryGroupId){
|
||||
self.editRepositoryGroup(value);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
this.saveRepositoryGroup=function(repositoryGroup){
|
||||
clearUserMessages();
|
||||
$("#user-messages").html(mediumSpinnerImg());
|
||||
|
@ -187,7 +196,7 @@ function(jquery,i18n,jqueryTmpl,bootstrap,jqueryValidate,jqueryUi,ko) {
|
|||
|
||||
}
|
||||
|
||||
displayRepositoryGroups=function(){
|
||||
displayRepositoryGroups=function(successFn){
|
||||
screenChange();
|
||||
var mainContent = $("#main-content");
|
||||
mainContent.html(mediumSpinnerImg());
|
||||
|
@ -237,6 +246,10 @@ function(jquery,i18n,jqueryTmpl,bootstrap,jqueryValidate,jqueryUi,ko) {
|
|||
|
||||
});
|
||||
|
||||
if(successFn){
|
||||
successFn(self.repositoryGroupsViewModel);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue