better notifications

* longer delay
* different color for enable and disable
This commit is contained in:
kakwa 2015-06-12 01:07:17 +02:00
parent 8781018021
commit 34d7e23cd2
1 changed files with 13 additions and 2 deletions

View File

@ -11,7 +11,13 @@
var checked = document.getElementById(role).checked;
$('input[name=' + role +']').bootstrapSwitch('state', true, true);
if ( ! checked){
$.notify("Added Role '" + DnParentRole + "' (Parent Role of '" + DnRole +"')");
$.notify("Enable Role '" + DnParentRole + "' (Parent Role of '" + DnRole +"')",
{
type: 'info',
delay: 6500,
}
);
}
}
}
@ -25,7 +31,12 @@
var checked = document.getElementById(role).checked;
$('input[name=' + role +']').bootstrapSwitch('state', false, true);
if (checked){
$.notify("Removed Role '" + DnParentRole + "' (Sub Role of '" + DnRole +"')");
$.notify("Disable Role '" + DnParentRole + "' (Sub Role of '" + DnRole +"')",
{
type: 'warning',
delay: 6500,
}
);
}
}
}