mirror of https://github.com/apache/archiva.git
switch button to toggle state while deleting
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1397732 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
99e5b54918
commit
5eb7e7af77
|
@ -107,6 +107,7 @@ define("archiva.search",["jquery","i18n","jquery.tmpl","choosen","knockout","kno
|
||||||
var previousHash=getUrlHash();
|
var previousHash=getUrlHash();
|
||||||
$.log("previousHash:"+previousHash);
|
$.log("previousHash:"+previousHash);
|
||||||
openDialogConfirm(function(){
|
openDialogConfirm(function(){
|
||||||
|
$("#dialog-confirm-modal-ok").button('loading');
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url:"restServices/archivaServices/repositoriesService/deleteGroupId?groupId="+groupId+"&repositoryId="+repoId,
|
url:"restServices/archivaServices/repositoriesService/deleteGroupId?groupId="+groupId+"&repositoryId="+repoId,
|
||||||
type:"GET",
|
type:"GET",
|
||||||
|
@ -119,6 +120,7 @@ define("archiva.search",["jquery","i18n","jquery.tmpl","choosen","knockout","kno
|
||||||
displayRestError(data,"user-messages");
|
displayRestError(data,"user-messages");
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete:function(){
|
||||||
|
$("#dialog-confirm-modal-ok").button('reset');
|
||||||
closeDialogConfirm();
|
closeDialogConfirm();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -222,6 +224,7 @@ define("archiva.search",["jquery","i18n","jquery.tmpl","choosen","knockout","kno
|
||||||
clearUserMessages();
|
clearUserMessages();
|
||||||
var artifact = new Artifact(repoId,null,self.groupId,self.artifactId,repoId,version);
|
var artifact = new Artifact(repoId,null,self.groupId,self.artifactId,repoId,version);
|
||||||
openDialogConfirm(function(){
|
openDialogConfirm(function(){
|
||||||
|
$("#dialog-confirm-modal-ok").button('loading');
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url:"restServices/archivaServices/repositoriesService/deleteArtifact",
|
url:"restServices/archivaServices/repositoriesService/deleteArtifact",
|
||||||
type:"POST",
|
type:"POST",
|
||||||
|
@ -236,6 +239,7 @@ define("archiva.search",["jquery","i18n","jquery.tmpl","choosen","knockout","kno
|
||||||
displayRestError( data,"user-messages");
|
displayRestError( data,"user-messages");
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete:function(){
|
||||||
|
$("#dialog-confirm-modal-ok").button('reset');
|
||||||
closeDialogConfirm();
|
closeDialogConfirm();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -603,6 +607,7 @@ define("archiva.search",["jquery","i18n","jquery.tmpl","choosen","knockout","kno
|
||||||
clearUserMessages();
|
clearUserMessages();
|
||||||
|
|
||||||
openDialogConfirm(function(){
|
openDialogConfirm(function(){
|
||||||
|
$("#dialog-confirm-modal-ok").button('loading');
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url:"restServices/archivaServices/repositoriesService/deleteArtifact",
|
url:"restServices/archivaServices/repositoriesService/deleteArtifact",
|
||||||
type:"POST",
|
type:"POST",
|
||||||
|
@ -627,6 +632,7 @@ define("archiva.search",["jquery","i18n","jquery.tmpl","choosen","knockout","kno
|
||||||
displayRestError(data,"user-messages");
|
displayRestError(data,"user-messages");
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete:function(){
|
||||||
|
$("#dialog-confirm-modal-ok").button('reset');
|
||||||
closeDialogConfirm();
|
closeDialogConfirm();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
<p id="dialog-confirm-modal-body-text"></p>
|
<p id="dialog-confirm-modal-body-text"></p>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<a class="btn btn-secondary" id="dialog-confirm-modal-cancel">${$.i18n.prop('cancel')}</a>
|
<a class="btn btn-secondary" id="dialog-confirm-modal-cancel" data-loading-text="${$.i18n.prop('common.loading')}">${$.i18n.prop('cancel')}</a>
|
||||||
<a class="btn btn-primary" id="dialog-confirm-modal-ok">${$.i18n.prop('ok')}</a>
|
<a class="btn btn-primary" id="dialog-confirm-modal-ok">${$.i18n.prop('ok')}</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -37,5 +37,4 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body" id="dialog-modal-merge-repo-body-text">>
|
<div class="modal-body" id="dialog-modal-merge-repo-body-text">>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue