Commit Graph

141 Commits

Author SHA1 Message Date
Deluan 09d1fd0658 Simplify normalized AlbumPlayCountMode calc 2024-05-09 08:13:42 -04:00
Deluan Quintão c4b05dac28
Make sorting lists by name/title case-insensitive (#2993)
* Make sort by order_* fields case-insensitive.

* Sort internet radios by name case-insensitive
2024-05-09 07:08:15 -04:00
Deluan a8955f24e0 Fix AlbumPlayCountMode. Closes #2984 2024-05-01 20:05:36 -04:00
Deluan 31fcab07d2 Refactor loadGenres, remove duplication 2024-04-28 17:04:12 -04:00
Deluan de90152a71 Refactor DB Album mapping to model.Album 2024-04-28 13:51:57 -04:00
Deluan 92a98cd558 Add tests for AlbumPlayCountMode, change the calc to match the request from #1032 2024-04-27 15:20:46 -04:00
vvdveen 8bff1ad512 Add AlbumPlayCountMode config option (#2803)
Closes #1032

* feat(album_repository.go): add kodi-style album playcount option - #1032

Signed-off-by: Victor van der Veen <vvdveen@gmail.com>

* fix format issue and remove reference to kodi (now normalized)

Signed-off-by: Victor van der Veen <vvdveen@gmail.com>

* reduced complexity but added rounding

Signed-off-by: Victor van der Veen <vvdveen@gmail.com>

* Use constants for AlbumPlayCountMode values

---------

Signed-off-by: Victor van der Veen <vvdveen@gmail.com>
Co-authored-by: Deluan <deluan@navidrome.org>
2024-04-27 14:10:40 -04:00
Deluan 7ccf685973 Fix PreferSortTags 2023-12-14 21:45:47 -05:00
Deluan Quintão ab53313273
Add new PrefSortTags option (#2696) 2023-12-11 20:37:11 -05:00
Deluan af7eead037 Add discs to album 2023-12-09 13:53:38 -05:00
Deluan Quintão 0ca0d5da22
Replace beego/orm with dbx (#2693)
* Start migration to dbx package

* Fix annotations and bookmarks bindings

* Fix tests

* Fix more tests

* Remove remaining references to beego/orm

* Add PostScanner/PostMapper interfaces

* Fix importing SmartPlaylists

* Renaming

* More renaming

* Fix artist DB mapping

* Fix playlist updates

* Remove bookmarks at the end of the test

* Remove remaining `orm` struct tags

* Fix user timestamps DB access

* Fix smart playlist evaluated_at DB access

* Fix search3
2023-12-09 13:52:17 -05:00
Deluan 28dc98dec4 Revert "Replace `COUNT(DISTINCT primary_key)` with `COUNT(*)`"
Genres are required as part of the count queries, so filter by genres work
2023-11-25 23:08:20 -05:00
Deluan 8c8e1ea701 Replace `COUNT(DISTINCT primary_key)` with `COUNT(*)` 2023-11-25 22:46:15 -05:00
Caio Cotts f69c27d146 Return genres in search3 endpoint. 2023-11-21 21:34:03 -05:00
Deluan e38a690632 Order albums by full original date (this time is for real). Fixes #1452 2023-05-23 09:51:02 -04:00
Deluan 7d0656f44a Order albums by full original date. Fixes #1452 2023-05-22 23:50:16 -04:00
Deluan 2f90fc9bd4 Move album refresh to scanner 2022-12-28 15:31:56 -05:00
Deluan 566ae93950 Remove old refresh code 2022-12-28 15:31:56 -05:00
Deluan 28e7371d93 Moved logic of collapsing songs into albums to model package
(it should really be called domain.... maybe will rename it later)
2022-12-28 15:31:56 -05:00
Deluan 695f82a1a0 Upgrade to Beego 2's orm 2022-07-30 12:43:48 -04:00
Deluan 9422373be0 Optimize AlbumRepository.GetAll and add a GetAllWithoutGenres method specifically for Subsonic API, where multiple-genres are not required 2021-11-02 21:19:49 -04:00
Deluan 12818fb590 Make song/album/artist endpoints read-only 2021-11-02 14:44:50 -04:00
Deluan 778f474d26 Use new `rest` lib (Update receives all columns that need to be updated) 2021-11-01 21:27:36 -04:00
Deluan c831dc4cdf Use `structs` lib to map models to DB. Fix #1266 2021-08-01 12:04:45 -04:00
Deluan 08840f6170 Simplify cover detection in roll-up code by left-joining synthesized table 2021-07-20 17:45:08 -04:00
Deluan cddd1b3f6b Simplify genre roll-up code by left-joining synthesized tables 2021-07-20 17:45:08 -04:00
Deluan 95181d748d Fix rollup of track genres to albums and artists.
See: https://github.com/navidrome/navidrome/pull/1251#issuecomment-882343022
2021-07-20 17:45:08 -04:00
Deluan 21cd50d81c Fix aggregated values (count, size, duration) in roll-up queries 2021-07-20 17:45:08 -04:00
Deluan a0cd585401 Fix Count methods 2021-07-20 17:45:08 -04:00
Deluan 20b7e5c49b Add Genre filters to UI 2021-07-20 17:45:08 -04:00
Deluan b56e034ce3 Add multiple genres to Artists 2021-07-20 17:45:08 -04:00
Deluan 1d8607ef6a Remove unnecessary repositories methods 2021-07-20 17:45:08 -04:00
Deluan 5e54925520 Add multiple genres to Albums 2021-07-20 17:45:08 -04:00
Deluan 44e7502aef Log warning when artist has a MBID of Various Artists 2021-07-18 18:28:51 -04:00
Deluan 8d56ec898e Use AlbumArtist tag even for compilations, when it is specified.
If the tracks' AlbumArtists are different, then use "Various Artists"
2021-07-15 11:53:08 -04:00
caiocotts b671d0ff7b
Better handling of album comments (#1013)
* Change album comment behaviour

* Don't check first item

* Fix previously imported album comments.

* Remove song comments if album comment is present
2021-04-24 21:40:55 -04:00
Deluan 5178f44094 Add `has_rating` filter to albums 2021-04-07 11:04:36 -04:00
Deluan 720e2357b7 Add option to sort Recently Added by file's mtime instead of time of import. 2021-03-12 18:18:35 -05:00
Deluan 6ee45a9ccc Move project to Navidrome GitHub organization 2021-02-06 21:46:35 -05:00
Deluan 7cc9fbaaf9 Revert: Use modified time as updated_at and created_at when refreshing/creating albums 2021-02-01 00:30:45 -05:00
Deluan 9807b0b6c0 Use modified time as updated_at and created_at when refreshing/creating albums. Closes #717 2021-01-31 22:17:40 -05:00
Deluan 4f90fa9924 Add denormalized list of artist_ids to album, to speed-up artist's albums queries
This will be removed once we have a proper many-to-many relationship between album and artist
2020-12-13 14:05:48 -05:00
Deluan 98af68ac99 Import comments and lyrics 2020-11-11 10:43:17 -05:00
Deluan 173dd52fe1 Use MBID with most occurrences 2020-10-20 17:16:24 -04:00
Deluan 6663c079e0 Add MBIDs to media_file, album and artist 2020-10-20 16:27:22 -04:00
Jay R. Wren fd6edf967f
Add size to album details (#561)
* add size to album details

for #534

* addressing review comments:

* create index album(size)
* remove unneeded Size field from refresh struct
* add whitespace to album details
* add size to album list view

* prettier
2020-10-12 11:10:07 -04:00
Deluan 841c1129ff Break-up album/artist refresh in chunks 2020-09-09 08:57:59 -04:00
Deluan e50a720818 Sort by album name, then artist name 2020-09-07 16:21:29 -04:00
Deluan a2e0acd6a2 Fix starring albums. Seems I may have lost a commit? 2020-08-15 15:03:03 -04:00
Deluan c2e03c8162 Add stars to Albums 2020-08-14 13:35:28 -04:00