diff options
author | Gábor Hojtsy <gabor@hojtsy.hu> | 2008-01-02 12:12:21 +0000 |
---|---|---|
committer | Gábor Hojtsy <gabor@hojtsy.hu> | 2008-01-02 12:12:21 +0000 |
commit | 5362c16386453d2e81c1dde864ae29c093c223fd (patch) | |
tree | 04791a9d64a8b845a74f748beb61c45f83240af5 | |
parent | f96a1c769094228d0ff3fb84a01e6c368d79a2f3 (diff) | |
download | brdo-5362c16386453d2e81c1dde864ae29c093c223fd.tar.gz brdo-5362c16386453d2e81c1dde864ae29c093c223fd.tar.bz2 |
#181125 follow up by beginner: book.js should have been removed earlier in #181125, was a commit mistake
-rw-r--r-- | modules/book/book.js | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/modules/book/book.js b/modules/book/book.js deleted file mode 100644 index ada21404d..000000000 --- a/modules/book/book.js +++ /dev/null @@ -1,35 +0,0 @@ -// $Id$ - -Drupal.behaviors.bookSelect = function(context) { - // This behavior attaches by ID, so is only valid once on a page. - if ($('#edit-book-bid.book-select-processed').size()) { - return; - } - // Hide the button in the node form, since it's not needed when JS is enabled. - $('#edit-book-pick-book').css('display', 'none'); - - // Binds a function to the keyup and change actions of the book select to - // retrieve parent options. Mark as processed so this binding is only done once. - $('#edit-book-bid') - .keyup(Drupal.bookFillSelect) - .change(Drupal.bookFillSelect) - .addClass('book-select-processed'); -}; - -// This function passes the form information and the book ID to a Drupal callback -// and retrieves a parent select with changed options to replace the one in the form. -Drupal.bookFillSelect = function() { - // Create a progress bar and substitute it for the parent select. - pb = new Drupal.progressBar('book_progress'); - pb.setProgress(-1, Drupal.t('Updating parents...')); - $('#edit-book-plid-wrapper').html(pb.element); - - $.ajax({ - url: Drupal.settings.book.formCallback +'/'+ $('#'+ Drupal.settings.book.formId +' input[name=form_build_id]').val() +'/'+ $('#edit-book-bid').val(), - dataType: 'json', - success: function(data) { - // Insert the new select, and remove the progress bar. - $('#edit-book-plid-wrapper').after(data['book']).remove(); - } - }); -}; |