fix selection of metatype on saved searches (#4053)
This commit is contained in:
parent
cb24ef7c29
commit
a731d3d115
|
@ -180,11 +180,11 @@ function select_metatype(elem)
|
|||
$(this).parent().parent().find(':checked').each(function() {
|
||||
var portal_type = $(this).val();
|
||||
var checkbox = $('.subtype-fieldset').find('[data-portaltype="' + portal_type + '"]');
|
||||
if ($(checkbox).parents('.docs')) {
|
||||
if ($(checkbox).parents('.docs').length == 1) {
|
||||
select_metatype($('.metatypes [data-type="docs"]'));
|
||||
} else if ($(checkbox).parents('.tasks')) {
|
||||
} else if ($(checkbox).parents('.tasks').length == 1) {
|
||||
select_metatype($('.metatypes [data-type="tasks"]'));
|
||||
} else if ($(checkbox).parents('.contacts')) {
|
||||
} else if ($(checkbox).parents('.contacts').length == 1) {
|
||||
select_metatype($('.metatypes [data-type="contacts"]'));
|
||||
}
|
||||
$(checkbox).click();
|
||||
|
|
Reference in New Issue