SandBox URL :- https://www.drupal.org/sandbox/himanshupathak3/2712881

Git clone URL:- git clone --branch 7.x-1.x https://git.drupal.org/sandbox/himanshupathak3/2712881.git quicktabs_remember

This will be used to remember user's last visited quicktab.
There is an option to remember logged in user's last tab on current quicktab whenever you create any quicktab.
Please select that and see whenever you revisit the page, it will remain on the last used tab.

Usage

  • Download and extract to the module folder.
  • Navigate to path 'admin/modules' and enable the module
  • Make sure to 'clear the cache'
  • Create or edit quicktab, there you'll find an option to remember last tab.
  • Check on front end, and visit some tab in quicktab block, refresh the page, you'll land on the last visited tab now.

Comments

himanshupathak3 created an issue. See original summary.

shaktik’s picture

Status: Needs review » Needs work

@himanshupathak3 : Fix pareview errors -

Review of the 7.x-1.x branch (commit 11adfaf):

  • README.md or README.txt is missing, see the guidelines for in-project documentation.
  • ESLint has found some issues with your code (please check the JavaScript coding standards).
    /var/www/drupal-7-pareview/pareview_temp/quicktabs_remember.js: line 6, col 2, Error - Use the function form of 'use strict'. (strict)
    /var/www/drupal-7-pareview/pareview_temp/quicktabs_remember.js: line 6, col 10, Error - Missing space before function parentheses. (space-before-function-paren)
    /var/www/drupal-7-pareview/pareview_temp/quicktabs_remember.js: line 8, col 21, Error - Missing space before function parentheses. (space-before-function-paren)
    /var/www/drupal-7-pareview/pareview_temp/quicktabs_remember.js: line 9, col 66, Error - Missing space before function parentheses. (space-before-function-paren)
    
    4 problems
    
  • DrupalPractice has found some issues with your code, but could be false positives.
    
    FILE: /var/www/drupal-7-pareview/pareview_temp/quicktabs_remember.module
    ------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    ------------------------------------------------------------------------
     74 | WARNING | Unused variable $query.
    ------------------------------------------------------------------------
    
    Time: 49ms; Memory: 4.25Mb
    
  • No automated test cases were found, did you consider writing Simpletests or PHPUnit tests? This is not a requirement but encouraged for professional software development.

This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.

Source: http://pareview.sh/ - PAReview.sh online service

rajab natshah’s picture

Hi Himanshu,

Nice work on this module.

Manual review:

1. The right link for your sandbox project is.
git clone --branch 7.x-1.x https://git.drupal.org/sandbox/himanshupathak3/2712881.git quicktabs_remember

2. README file is messing. It's an important to have some info.

3. The use of "quicktabs_remembered" Table to store quicktabs remember checked option. The function _quicktabs_remember_get_quicktabs. I think the use of variable_set and variable_get will ease the work and not let us have a key filtering in PHP. As by a sample concatenation format .. like quicktabs_remember quicktab_machine_name .

4. I think we could add an option to Save the last tab in the Cookies. so that the JavaScript will read that from the cookiey then do the work as well .. I do see this options to save in database or cookies.

5. I think you could make use of hook_enable and hook_disable in the in the install file.

Rewarded module ;)

himanshupathak3’s picture

Issue summary: View changes
himanshupathak3’s picture

Thanks Rajab.
1. Updated wrong git clone URL.
2. Adding readme file soon.
3. I thought of using variable set and variable get first, but found quicktab does not have hook for quicktab deletion, so we can't delete variable automatically when quicktab is deleted, that's why I used foreign keys to get this job done automatically. Any idea how to achieve that ?
4. Yes, adding cookies is in future scope, I wanted this across all browsers, so added db records. Yes for the same browser, I'm going to add cookies as well, so that if cookies exists, we reduce one database call. And I'm adding one more checkbox "remember per browser" (which uses cookies at back end), for that I'll not store records in db.
5. Yes, will add hook_enable and hook_disable in install file.

Thanks again for your valuable review.

PA robot’s picture

Status: Needs work » Closed (duplicate)
Multiple Applications
It appears that there have been multiple project applications opened under your username:

Project 1: https://www.drupal.org/node/2593421

Project 2: https://www.drupal.org/node/2718615

As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue. With this in mind, your secondary applications have been marked as 'closed(duplicate)', with only one application left open (chosen at random).

If you prefer that we proceed through this review process with a different application than the one which was left open, then feel free to close the 'open' application as a duplicate, and re-open one of the project applications which had been closed.

I'm a robot and this is an automated message from Project Applications Scraper.

himanshupathak3’s picture

Issue summary: View changes
avpaderno’s picture

Issue tags: -quicktabs, -Ajax
Related issues: +#2593421: [D7] Reading Progress Bar