Book tree outline module is developed to provide click and expand feature for book menus. This module is integrated with “JQuery Menu” module for click and expands functionality of navigation menu using different API’s of jquery menu.
User can set the display of book block and expand depth level of tree from block configuration page. This is helpful for set default expand level of book tree.

Configurations:
After installation of book tree outline module go to
(admin/structure/block/manage/book_tree_outline/navigation/configure) and select the book navigation display settings and book navigation tree depth.

Details
Project page: https://drupal.org/sandbox/shubhangibb/2135603
Git link : git clone --branch 7.x-1.x shubhangibb@git.drupal.org:sandbox/shubhangibb/2135603.git book_tree_outline

Other reviewed modules
https://drupal.org/node/2115157#comment-8190173
https://drupal.org/comment/8190371#comment-8190371
https://drupal.org/comment/8190437#comment-8190437

Comments

shubhangibb’s picture

Issue summary: View changes
shubhangibb’s picture

Issue summary: View changes
shubhangibb’s picture

Issue summary: View changes
shubhangibb’s picture

Issue tags: +PAreview: review bonus
krknth’s picture

In book_tree_outline_block_configure function you declared 2 $options arrays

1.

  $options = array(
    'all pages' => t('Show block on all pages'),
    'book pages' => t('Show block only on book pages'),
  );

2.

$options = array(
    '0' => t('Show block on all pages'),
    'book pages' => t('Show block only on book pages'),
  );

But 2 nd $options is not used, so delete it.

neerajskydiver’s picture

  1. Delete Master branch
  2. Delete unused variables
    line 34 $book_menus
    line 102 $block
    line 307 $i
  3. The functions must be start with module name so
    change build_trail function name
  4. persistent variable you declared
      variable_set('book_tree_outline_block_mode', $edit['book_tree_outline_block_mode']);
      variable_set('book_tree_depth', $edit['book_tree_depth']);

    Must be deleted in hook_unistall

  5. And also variable book_tree_depth must be changed to book_tree_outline_depth
shubhangibb’s picture

Hi Krishnakanth & Neerajskydiver ,

Thanks for review. I will do the changes as you suggested.

Thanks,
Shubhangi B.

candotri’s picture

Your git clone link is for your username. Please change that to the anonymous git clone like this:
git clone --branch 7.x-1.x http://git.drupal.org/sandbox/shubhangibb/2135603.git book_tree_outline

candotri’s picture

I don't prefer long lines with long switches - they make it harder to read code and to get a quick feeling from the code. For example, .module line 32 is 103 characters long. .module,322 is 144 characters! Not good. Hard to read
See https://drupal.org/coding-standards#linelength

Is there a reason why you are using handwritten selects like on .module, 217 instead of adding conditions like on .module,179? Maybe I'm missing something but it seems inconsistent. I much prefer the .module,179 method where possible.

The code is quite readable and easy to understand. Good work!

I'll try running the code next.

candotri’s picture

You can move some code out of the .module file and into .inc files to reduce the size of the .module. It's straightforward to do and will make things more maintainable. Use module_load_include() calls to load the .inc files. Remember that .module files are loaded every page load.

shubhangibb’s picture

Hi Chad,

Thanks for your comments. I will do the needful changes as you suggested and will update the code.

tr’s picture

If you are trying to get git access to publish your project, you need to post this issue in the Drupal.org Project applications queue at https://drupal.org/project/issues/projectapplications

Posting this here in your sandbox issue queue will not get your project published.

ratanphp’s picture

@shubhangibb
Your module looks good to me as well. As I reviewed your code and also installed on my local machine.
I think you have to use $current_bid variable in query condition at line number 45 in .module file. Also please add one check condition before foreach ($result as $book) { at line number 119 in .module file.

laceysanderson’s picture

@shubhangibb
To move this project to application status you need move it to the "Drupal.org Project applications" issue queue (as indicated by @TR). To do this, just mention what you're doing in a new comment, expand the "Issue metadata" and change "Project" from "Book tree outline (2135603)" to "Drupal.org Project applications". This will get your application in front of the main reviewers and help you get it approved Much faster.

Thanks for the contribution :)

laceysanderson’s picture

Status: Needs review » Postponed (maintainer needs more info)

Moving to postponed just to get your attention. Once you move it to the Drupal Project applications, feel free to set it back to "Needs Review" :)
Good Luck!

tr’s picture

Status: Postponed (maintainer needs more info) » Closed (won't fix)
Issue tags: -PAreview: review bonus