Skip to content

Commit

Permalink
Corrige função askDelete (#4)
Browse files Browse the repository at this point in the history
Closes: #3
  • Loading branch information
JP Rodrigues committed May 18, 2016
1 parent ed50d34 commit e016100
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions build/js/gainTime.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,11 @@ $(document).on('click', function(e) {

//Ask Delete

function askDelete(name, entity) {
if(confirm("Deseja deletar "+ entity +" \""+ name +"\" do sistema?")){
function askDelete(name, entity, url = '') {
if(confirm("Deseja deletar "+ entity +" \""+ name +"\" do sistema?")) {
if (url != '') {
window.location.href = url;
}
return true;
}
return false;
Expand All @@ -29,7 +32,7 @@ setTimeout(function(){
$('.msg').fadeOut();
}, 3000);

// Inputs and Labels
// Inputs and Labels

$('document').ready(function() {
$('input').each(function() {
Expand Down

0 comments on commit e016100

Please sign in to comment.