') $(this).find('.panel-body').addClass('panel-collapse collapse').attr('role','tabpanel'); if(i==0){ $(this).find('.panel-collapse').collapse('show'); $(this).find('.panel-footer').show(); }else{ $(this).find('.panel-footer').hide(); } i++; }); $('.subscription-services-filter').hide(); $('#subscription-modal').find('.subscription-services .subscription-service .service-heading').css({'padding':'0px'}); $('#subscription-modal').find('.subscription-services .subscription-service .service-heading').find('a').css({'display':'block','padding':'10px 15px'}); $('#subscription-modal').find('.subscription-services .subscription-service .service-heading').find('a[data-toggle=collapse]').on('click',function(event){ var id = $(this).attr('aria-controls'); var open = $('#'+id).find('.collapse').hasClass('in'); $('#subscription-modal').find('.subscription-services .subscription-service').each(function(){ if(this.id == id){ $(this).find('.panel-collapse').collapse('show'); $(this).find('.panel-footer').show(); }else{ $(this).find('.panel-collapse').collapse('hide'); $(this).find('.panel-footer').hide(); } }); }); $('#asset-content').find('.subscription-required').find('.panel-footer').find('a[data-toggle=collapse]').on('click',function(event){ $(this).parents('.panel-footer').find('.collapse.collapse-rates').collapse('toggle'); }); $('#asset-content').find('.meter-modal-open').on('click',function(){ $('#asset-content').find('.alert.notification').css({'z-index':'900'}); $("#template-metering").find('.metering-modal').first().modal(); }); $('#eedition-subscription').find('.meter-modal-open').on('click',function(){ $("#template-metering").find('.metering-modal').first().modal(); }); });