Bug 44 - browse by new music
: browse by new music
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Web Interface
: unspecified
: All All
: P2 enhancement with 3 votes (vote)
: ---
Assigned To: Dan Sully
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2003-12-19 20:06 UTC by Blackketter Dean
Modified: 2008-08-18 10:53 UTC (History)
5 users (show)

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Blackketter Dean 2003-12-19 20:06:18 UTC
We have a pretty big collection (200 Gb) stored at an online server. Several people have 
permissions to update the server with new albums. To inform each other of 'whats new' we use a 
mailing list. At this point I miss a feature at de slimp3 server. It would be great to have an item at 
the homepage under the 'browse music' heading called: 'new music' (or something like that). This 
link should show a list with uploaded dirs and files which are not older than a month (based on the 
date of each file). Perhaps this period - the month - is a variable which you change in the server 
settings.
Comment 1 Mark Winder 2004-09-26 05:57:09 UTC
I agree, with big music collections, we're all tired of the older stuff, and
what I'd like is to be able to browse the music folder chronologically, newest
first. 
Directories only need to be in Chronological order, files probably should still
be in alphabetical. 

I believe this would answer Dean's requirements, fit in with the existing
interface well and be simple to implement. 

When you want to look at new music, you just browse down from the top till you
get to what you want. 
Comment 2 Marc Reichman 2004-10-17 19:34:59 UTC
I would *love* this feature as well, both as browsing, and as a plugin or browse mode on the actual 
slim/squeeze device and the web interface. i tried to do a plugin, but i don't know enough perl!

i have a nice ls -t script on my box for my information, but it would be nice in the server. :)
Comment 3 Dirk Bergstrom 2005-02-06 09:44:49 UTC
I too desired this functionality.  After a while, I decided to dig through the
sources and see how hard it would be to implement.  Turns out it was dead
simple.  Here's a patch for 5.4.0.  I didn't bother to do I18N, or to add a knob
to the prefs page, since it looks like 6.0 is on the way soon.  However, it
wouldn't be hard for me to do that if the Slim Devices folks are interested in
this patch...

diff -pubr ./Music/Info.pm /usr/share/slimserver/Slim/Music/Info.pm
--- ./Music/Info.pm     2004-11-15 11:59:26.000000000 -0800
+++ /usr/share/slimserver/Slim/Music/Info.pm    2004-12-11 23:00:30.000000000 -0800
@@ -2108,6 +2108,20 @@ sub readTags {
                                }
                        }

+                       ###
+                       ### Special hack to create a genre of "New" for recently
added files
+                       ###
+                       if (-M $filepath <
Slim::Utils::Prefs::get('maxAgeForNew')) {
+                               if (defined($tempCacheEntry->{'GENRE'})) {
+                                       $tempCacheEntry->{'GENRE'} .= ';New';
+                               } else {
+                                       $tempCacheEntry->{'GENRE'} = 'New';
+                               }
+                       }
+                       ###
+                       ### End of "New" genre hack
+                       ###
+
                        # cache the file size & date
                        $tempCacheEntry->{'FS'} = -s $filepath;
                        $tempCacheEntry->{'AGE'} = (stat($filepath))[9];
diff -pubr ./Utils/Prefs.pm /usr/share/slimserver/Slim/Utils/Prefs.pm
--- ./Utils/Prefs.pm    2004-11-15 11:59:26.000000000 -0800
+++ /usr/share/slimserver/Slim/Utils/Prefs.pm   2004-12-11 23:00:15.000000000 -0800
@@ -133,6 +133,7 @@ my %DEFAULT = (
        ,'showYear'                             => 0
        ,'timeFormat'                   => q(|%I:%M:%S %p)
        ,'titleFormatWeb'               => 1
+       ,'maxAgeForNew'                 => 14
        ,'iTunesplaylistprefix' => 'iTunes: '
        ,'iTunesplaylistsuffix' => ''
        ,'MoodLogicplaylistprefix'              => 'MoodLogic: '
Comment 4 Dan Sully 2005-02-20 09:53:43 UTC
There's now a "New Music" top level menu in the web interface for 6.0 builds.
Comment 5 Pascal Berger 2005-02-21 06:11:33 UTC
The menu item should be accessible through the device
Comment 6 Dan Sully 2005-02-26 14:17:00 UTC
I've just added browsing by new music to the device UI.

Subversion change 2240.