mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2024-12-20 19:06:06 +01:00
Fix:Book library sort by publishedYear #3620
- Updated sort to cast publishedYear to INTEGER
This commit is contained in:
parent
46a3c3de33
commit
75eef8d722
@ -259,7 +259,7 @@ module.exports = {
|
||||
} else if (sortBy === 'media.duration') {
|
||||
return [['duration', dir]]
|
||||
} else if (sortBy === 'media.metadata.publishedYear') {
|
||||
return [['publishedYear', dir]]
|
||||
return [[Sequelize.literal(`CAST(\`book\`.\`publishedYear\` AS INTEGER)`), dir]]
|
||||
} else if (sortBy === 'media.metadata.authorNameLF') {
|
||||
return [[Sequelize.literal('author_name COLLATE NOCASE'), dir]]
|
||||
} else if (sortBy === 'media.metadata.authorName') {
|
||||
|
Loading…
Reference in New Issue
Block a user