What I would like to suggest:
In the filters, we can filter by "In Queue" (True or False). I'd like to see a sort of "In queue".

Why?
I have a content type with some of the nodes in a nodequeue, and others not. I'd like to be able to have the nodes in the nodequeue be shown at the top of the list with all of the other nodes not in a queue be listed below these. I could accomplish this with two sorts:

In queue (desc)
queue position (asc)

(Nodes not in this queue have a position of '0' therefore they show at the top of the list.)

If there is another way to do this sort of sort, please let me know.

Comments

asherry’s picture

Assigned: Unassigned » asherry

Our client needs exactly the same thing, so I'll assign this to me unless anybody else has worked on this already.

asherry’s picture

Status: Active » Needs review
StatusFileSize
new2.09 KB

Status: Needs review » Needs work

The last submitted patch, sort-by-in-queue-1973790-2.patch, failed testing.

asherry’s picture

Version: 7.x-2.0-beta1 » 6.x-2.x-dev
Status: Needs work » Needs review
StatusFileSize
new1.78 KB

Not exactly sure what I missed, but just in case I'm changing this to a patch for the latest 2.x version.

@dpearceMN it's also worth noting that you can probably solve your problem (and mine) temporarily by sorting by qid. (Queue ID) If you set that to descending then anything with a queue id will be sorted before anything without.

I still like having a boolean to choose from though, so hopefully this can make it in. Also this will give you the option to sort by:
In queue
Queue ID (ASC)
Nodequeue Position

asherry’s picture

Version: 6.x-2.x-dev » 7.x-2.x-dev
StatusFileSize
new1.78 KB

My apologies, I accidentally chose 6.x-2.x and not 7.x-2.x.

othermachines’s picture

Issue summary: View changes
Status: Needs review » Reviewed & tested by the community

Yes, please. I need this to set up "top 5 news" in a larger listing of articles.

Patch applied cleanly, works exactly as advertised. Thanks, @asherry!

dpearcefl’s picture

Can we please get this committed to the code base?

  • fizk committed 0912953 on 7.x-2.x authored by asherry
    Issue #1973790 by asherry: Sorting by "in queue"
    
fizk’s picture

Status: Reviewed & tested by the community » Fixed

Committed. Thanks!

fizk’s picture

Assigned: asherry » Unassigned

Status: Fixed » Closed (fixed)

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