I've started implementing #322824: Multiple subqueues per user and/or multiple queues? and eventually ended up rewriting the module entirely.
I've reached the phase where I feel comfortable enough to publish an alpha version of this new module, and was wondering if you have any interest in making it the 2.0 version of smartqueue_users.
It breaks a few things from version 0.1-alpha, such as the settings for the (single) users nodequeue, and the references in the table nodequeue_subqueue, but these could easily be migrated.

I believe a complete rewrite of the module was in order because of two main reasons. The first reason being that the module was mostly centered around having a single users nodequeue, and a single subqueue for each user, which made it hard to write just a patch for multiple subqueues per user.
The second reason is that the module's code seems to be based mostly on Drupal 5, and when I started rewriting the module with Drupal 6 in mind I've found several places where D6 features could easily replace dozens of lines of code with 1 or 2 lines, or prevent some hack around D5's limitations.

The rewritten module introduces multiple users nodequeues, with possible multiple subqueues for each user. It allows users to change the privacy of their subqueues (public or private) on a per-subqueue basis, as long as the site's admin allows users to change it.

The following features have not been rewritten (yet):

  • Hide links from admins - The only mode for the rewritten module is NOT to show the links to add or remove a node from user subqueues in the node-links area. Is there any interest in showing these? They are still shown in the Tab and nodequeue admin UI
  • Automatically create a subqueue for new users and Batch create subqueues for existing users that don't have user subqueue - Even though there's a change in philosophy for user nodequeue, I can understand why admins would request this feature. These two are a bit tricky because there can be more then one users nodequeue. I think that adding for new users should be done with an Action/Trigger, and I'll re-implement a batch creator - The UI to start this batch job should probably be in a special maintenance page and not on the nodequeue's edit page, as the batch is for content and the nodequeue's edit page is for settings.
  • Batch remove subqueues for users whose roles can no longer own a subqueue - This one seems like a real edge case, but I guess this is worth re-implementing. (Again, special maintenance page)
  • Show a block with the user nodequeue's content on the user's profile page - Since there can be more than one subqueue for a user, blocks can put too much content on the user's profile. Instead I've placed them all in a tab on the user's profile page (which is also where the user can create and edit own subqueues).

I might have missed a few new features or non-rewritten features, please let me know if you've noticed something missing here. I'll put on a demo site of this module soon.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

z.stolar’s picture

subscribing

daniboy’s picture

jaxpax’s picture

WOW This looks so good, exactly what I am looking for.

gavri’s picture

I think it's a great idea - Is this module is going to replace the existing smartqueue_users module?

skitten’s picture

This looks like exactly what I've been looking for!

ezra-g’s picture

Status: Active » Needs review

I hope to review more completely this in the next 1-2 weeks.

Marking as NR.

daniboy’s picture

FileSize
11.46 KB

Then you'll probably want to review my latest version, attached to this comment.

Changelog:

  • Added an option to replace the way each userqueue's nodes are displayed with a View (provided that the Views module is installed.)
  • Added a views field to display the privacy of a subqueue (obviously only valid for queue relationships.)
  • Added an implementation for the hook that the patch in issue #477880: Editable tables provides.
  • Added a block to display user queues. Currently requires "advanced knowledge" - it received a $uid and outputs the same table as in "My Queues" page. The $uid is received from an editable PHP code (a default example is provided.)
  • Some changes to theme functions. I made them more customizable.
  • Some bug fixes, mostly related to access controls.
  • Added a submodule "Smartqueue Alternative Links UI" - when active this module replaces all the nodequeue related links in the "links" section inside nodes with a javascript widget to show/hide those links. This is more easily demonstrated than explained, simply activate this module on a site with lots of subqueues. The module's behavior degrades gracefully without javascript.
zinkzinkzink’s picture

Super!! After making a home-made (not nearly half-finished, i'm new to drupal..) module for private buckets of nodes (http://drupal.org/node/494558), I stumbled on this one!! It seems this SQ version will have everything I could wish for!

/asa

der100’s picture

When this module is activated, where does the node-specific link supposed to show?

ezra-g’s picture

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

Hi daniboy,

I'm reviewing this but it seems difficult to test without the ability to create any subqueues for users. How have you been creating the user subqueues?

Thanks!

Ezra

daniboy’s picture

FileSize
325 bytes

@ezra-g - It seems that I've let a bug slip in - The bug is in the theme function that prints the link to add a new subqueue for a certain user - that link will only shows up if a the user already has subqueues :)
Obviously this is not how it should be. Apply the attached patch to fix it.

You can then create new subqueues by going to a user profile and clicking on the "My Queues" tab (user/[uid]/queue)

@der100 - I'm afraid I don't understand your question

der100’s picture

My issue is that when I activate the module and "manipulate queues" for authenticated users is set, I don't see any link to add the node to a queue, or to create a queue on the node's page.

TC44’s picture

This looks excellent. I will test it out today, thanks for your work on this.

z.stolar’s picture

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

Changing status.

TC44’s picture

@daniboy - I've been testing this out, and it works great. I am new to the nodequeue module, and had a couple questions regarding this version of smartqueue_users. I'm not sure if these questions are better suited for the nodequeue module, so please let me know.

1. When viewing a node, Is there any way to display all subqueues (of all users) that this particular node has been added to? Currently I've got the nodequeue list displaying in a tab on the node view, but it only shows the nodequeue/subqueues for the logged in user, so you can't see anyone else's subqueues from the node view. It would be very useful to have an option to show a list of all the subqueues that a node belongs to, as you can then provide user created lists for nodes, and users can directly browse other "lists" that have been created that the node belongs to.

2. Is there any way to modify the displayed wording of nodequeues? Primarily the "My Queues" tab, and on the queue page "add to queue" etc. I would like to change that to something that the end user would more easily understand, such as "lists". Is there any way to achieve this? I can change the tab name via string overrides, but I'm not sure about the rest.

Thanks again for your work on this!

z.stolar’s picture

@TC44: the answer to both questions is YES, and is part of the nodequeue module itself, not to Smartqueue Per User module.
Please open a new support request on nodequeue's issue queue.

TC44’s picture

@z.stolar,

Thanks very much, I'll do that.

ezra-g’s picture

Status: Needs review » Fixed

I think this needs some coder style corrections and possibly other fixes, but I've created a DRUPAL-6-2 branch and a dev snapshot release for this rewrite. I left out the smartqueue_alternative_links module because that would be a great improvement that could be applicable to other smartqueue modules, and there's already some discussion about that at #308046: Usability: Modal popup for multiple queues -- it would be great to continue that discussion there.

Thanks for this rewrite! I know that a lot of people are excited to have multiple queues per user :).

AntiNSA’s picture

Is there any reason this module is not layed out in the typical module download pages and is laid out in the issues of another module section? WHy not publish this as a seperate project or update the code on this project?

csc4’s picture

Tracking

clockwood’s picture

Waiting anxiously for this update.

ezra-g’s picture

Everyone should stop waiting for this update since it's been committed since september 6th. I just made the snapshot release show on on the project page. thanks.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

delykj’s picture

Status: Closed (fixed) » Active

What about the following two issues, described by Daniboy? Is there any progress? Thanks for your great work!

# "Automatically create a subqueue for new users and Batch create subqueues for existing users that don't have user subqueue"
# "Batch remove subqueues for users whose roles can no longer own a subqueue"

AntiNSA’s picture

Category: feature » support
Priority: Normal » Critical

Is there any reason this module is not layed out in the typical module download pages and is laid out in the issues of another module section? WHy not publish this as a seperate project or update the code on this project?

tjaap’s picture

For my use case it is necessary that every new user will get his own subqueue. So I would very much like to know if someone has found a solution to the issues mentioned in #24. Is there an easy way to do this? I have no experience with triggers - is it easy to add an action/trigger like daniboy suggests?

It would be very nice if someone can point me in the right direction. I will have a go at getting it to work and I will report back if I succeed.

Update: same question was asked here, with a clear application:
http://drupal.org/node/793862#comment-2993778

DrakeTaylor’s picture

FileSize
651 bytes

Here's a patch to create a subqueue for a new user. This works only for the first qid owned by 'smartqueue_users' I'll try to post a new patch that works with more than one queue later.

-Drake

AntiNSA’s picture

waaiting for someone to test this...

DrakeTaylor’s picture

I've started a new issue regarding creating subqueues for users when they are created. It (along with my latest patch) can be found at: http://drupal.org/node/835928

-Drake

clemens.tolboom’s picture

Version: 6.x-1.x-dev » 6.x-2.x-dev
Category: support » feature
Status: Active » Closed (fixed)

In #18 esra-g committed it to the 6.x-2.x-dev version ... it's a little confusing to see a 6.x-6.x-dev version too.

Please don't reopen fixed issues unless the code broke.

If you need support please open a new support issue.