Merge branch 'ent-3382-comprobacion-de-grupos-secundarios-y-primarios-al-creareditar-un-agente' into 'develop'
Added advice when a primary group will be selected when is currentl a secondary group See merge request artica/pandorafms!2353
This commit is contained in:
commit
6765544b66
|
@ -1162,6 +1162,19 @@ ui_require_jquery_file('bgiframe');
|
|||
}
|
||||
|
||||
$(document).ready (function() {
|
||||
|
||||
var previous_primary_group_select;
|
||||
$("#grupo").on('focus', function () {
|
||||
previous_primary_group_select = this.value;
|
||||
}).change(function() {
|
||||
if ($("#secondary_groups_selected option[value="+$("#grupo").val()+"]").length) {
|
||||
alert("<?php echo __('Secondary group cannot be primary too.'); ?>");
|
||||
$("#grupo").val(previous_primary_group_select);
|
||||
} else {
|
||||
previous_primary_group_select = this.value;
|
||||
}
|
||||
});
|
||||
|
||||
$("select#id_os").pandoraSelectOS ();
|
||||
|
||||
var checked = $("#checkbox-cascade_protection").is(":checked");
|
||||
|
|
Loading…
Reference in New Issue