- var isShow = false;
- var extend = $('#extends_0').val();
-
- var contactTypes = {/literal}{$contactTypes}{literal};
- var showStyle = "{/literal}{$showStyle}{literal}";
- var showMultiple = "{/literal}{$showMultiple}{literal}";
- var showMaxMultiple = "{/literal}{$showMaxMultiple}{literal}";
+ var
+ extend = $(this).val(),
+ contactTypes = {/literal}{$contactTypes}{literal},
+ showStyle = "{/literal}{$showStyle}{literal}",
+ showMultiple = "{/literal}{$showMultiple}{literal}",
+ showMaxMultiple = "{/literal}{$showMaxMultiple}{literal}",
+ isContact = ($.inArray(extend, contactTypes) >= 0);