1(function ($) { 2 3 /** 4 * Fulfill path field on submit 5 * */ 6 7 Drupal.behaviors.feedbackFormSubmit = { 8 attach:function (context) { 9 jQuery('.feedback-form .form-item-title').hide(); 10 jQuery('.feedback-form input[type=submit]').click(function () { 11// alert(window.location.pathname); 12 jQuery('.feedback-form .form-item-title input').val(window.location.pathname); 13 }); 14 jQuery('.ctools-modal-content .close').click(function(event){ 15 event.preventDefault(); 16 var nodeTest = jQuery(this).parent().parent().find(".node-feedback"); 17 if (nodeTest.length > 0 ) location.reload(true); 18 }); 19 } 20 }; 21// 22// Drupal.behaviors.feedbackCancelModal = { 23// attach:function (context) { 24// 25// } 26// }; 27 28// 29///** 30// * Attach auto-submit to admin view form. 31// */ 32//Drupal.behaviors.feedbackAdminForm = { 33// attach: function (context) { 34// $('#feedback-admin-view-form', context).once('feedback', function () { 35// $(this).find('fieldset.feedback-messages :input[type="checkbox"]').click(function () { 36// this.form.submit(); 37// }); 38// }); 39// } 40//}; 41// 42///** 43// * Attach collapse behavior to the feedback form block. 44// */ 45//Drupal.behaviors.feedbackForm = { 46// attach: function (context) { 47// $('#block-feedback-form', context).once('feedback', function () { 48// var $block = $(this); 49// $block.find('span.feedback-link') 50// .prepend('<span id="feedback-form-toggle"></span> ') 51// .css('cursor', 'pointer') 52// .toggle(function () { 53// Drupal.feedbackFormToggle($block, false); 54// }, 55// function() { 56// Drupal.feedbackFormToggle($block, true); 57// } 58// ); 59// $block.find('form').hide(); 60// $block.show(); 61// }); 62// } 63//}; 64// 65///** 66// * Re-collapse the feedback form after every successful form submission. 67// */ 68//Drupal.behaviors.feedbackFormSubmit = { 69// attach: function (context) { 70// var $context = $(context); 71// if (!$context.is('#feedback-status-message')) { 72// return; 73// } 74// // Collapse the form. 75// $('#block-feedback-form .feedback-link').click(); 76// // Blend out and remove status message. 77// window.setTimeout(function () { 78// $context.fadeOut('slow', function () { 79// $context.remove(); 80// }); 81// }, 3000); 82// } 83//}; 84// 85///** 86// * Collapse or uncollapse the feedback form block. 87// */ 88//Drupal.feedbackFormToggle = function ($block, enable) { 89// $block.find('form').slideToggle('medium'); 90// if (enable) { 91// $('#feedback-form-toggle', $block).html(''); 92// } 93// else { 94// $('#feedback-form-toggle', $block).html(' x '); 95// } 96//}; 97// 98})(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.