1 /* vim: set expandtab sw=4 ts=4 sts=4: */
6 function show_hide_clauses(thisDropdown) {
7 // here, one span contains the label and the clause dropdown
8 // and we have one span for ON DELETE and one for ON UPDATE
10 if (thisDropdown.val() != '') {
11 thisDropdown.parent().next('span').show().next('span').show();
13 thisDropdown.parent().next('span').hide().next('span').hide();
17 $(document).ready(function() {
19 $('.referenced_column_dropdown').each(function(index, one_dropdown) {
20 show_hide_clauses($(one_dropdown));
23 $('.referenced_column_dropdown').change(function() {
24 show_hide_clauses($(this));