Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 11-24-2019, 06:58 AM   #1
matjojo
Junior Member
matjojo began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Nov 2019
Device: Android phone
Question Custom sort order for custom columns?

I have a custom column set up with 'a fixed set of permitted values'. This is a standard status column. The options are:
- Reading
- Waiting on update
- Inactive
- Completed
- Discontinued
- To Read
- On Hold

(in that order)
But, the sort order of the column seems to be alphabetical. Before I figured that out I tried to change the order in the definition, but that also kept the order alphabetical of course.

Is there a way to define a custom sort order for this column?

I'm not running from source, but I'm relatively well versed in python programming so if that is needed I should be able to do it.

Running on version 4.4 64bit
matjojo is offline   Reply With Quote
Old 11-24-2019, 07:01 AM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,860
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
A custom sort order where? While editing it?
kovidgoyal is offline   Reply With Quote
Advert
Old 11-24-2019, 07:05 AM   #3
matjojo
Junior Member
matjojo began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Nov 2019
Device: Android phone
I would like to have a custom sort order in the library viewer. So that say reading is on top, then waiting on update, then on hold, then to read, etc.

The page may not be called library viewer so here is an image to show where I would like that.

https://i.imgur.com/kyNKLQz.png
matjojo is offline   Reply With Quote
Old 11-24-2019, 08:06 AM   #4
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,860
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
sorting in the book list is always alphabetic or numeric (for numeric/date column types). Simply prefix your enum values with a number to change their sort order.
kovidgoyal is offline   Reply With Quote
Old 11-24-2019, 10:58 AM   #5
matjojo
Junior Member
matjojo began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Nov 2019
Device: Android phone
Took me a while to realise that the contents of the column having turned black was due to the changing of the names not working, but after I figured that out I got them all on working order.

Only issue now is that it puts books where there is not content above the ones with content in the tag, meaning that the books with the column filled in as 1 (...) are now not on top, but almost completely at the bottom of the list of books.

Is there a way to turn that around? Seems to me like you'd almost always want untagged to go below filled in?
matjojo is offline   Reply With Quote
Advert
Old 11-24-2019, 11:30 AM   #6
jbacelar
Interested in the matter
jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.jbacelar ought to be getting tired of karma fortunes by now.
 
jbacelar's Avatar
 
Posts: 421
Karma: 426094
Join Date: Dec 2011
Location: Spain, south coast
Device: Pocketbook InkPad 3
Mistake.

Last edited by jbacelar; 11-24-2019 at 11:51 AM. Reason: Please close the post.
jbacelar is offline   Reply With Quote
Reply

Tags
question, sort order, sorting


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Ratings Custom Columns Created From other Columns Tanjamuse Library Management 4 09-28-2020 12:57 AM
Help Needed for Custom Columns Created From other Columns Tanjamuse Library Management 5 09-02-2018 06:19 PM
Manual Sort or Sort by custom column Dethmaul Marvin 2 04-28-2014 11:54 AM
Order of Custom Columns in Edit Metadata BetterRed Calibre 13 03-13-2013 12:33 PM
Order of Custom Columns in Metadata Editor BetterRed Calibre 2 08-29-2012 12:47 AM


All times are GMT -4. The time now is 08:07 PM.


MobileRead.com is a privately owned, operated and funded community.