public
Description: The kick ass (non-commercial) home for musicians and their music
Homepage: http://alonetone.com
Clone URL: git://github.com/sudara/alonetone.git
tweak to nav (show private playlists) and tweak to disallow all subdomains
sudara (author)
Wed May 07 02:54:31 -0700 2008
commit  01d6922e8f024006228d0c27ba4c483bcab19346
tree    039c8a9a4c13a9419104909b1197bea625caacb2
parent  eb1fa0760d065d896ccd928248262e1b6eba136f
...
12
13
14
15
 
16
17
18
...
12
13
14
 
15
16
17
18
0
@@ -12,7 +12,7 @@ class PlaylistsController < ApplicationController
0
   # GET /playlists
0
   # GET /playlists.xml
0
   def index
0
- if logged_in? && current_user.id.to_s == @user.id.to_s
0
+ if logged_in? && (current_user.id.to_s == @user.id.to_s || current_user.admin?)
0
       @all_playlists = @user.playlists.include_private
0
     else
0
       @all_playlists = @user.playlists.public
...
4
5
6
7
 
 
8
9
 
10
11
 
12
13
14
 
15
16
17
...
4
5
6
 
7
8
9
 
10
11
 
12
13
14
 
15
16
17
18
0
@@ -4,14 +4,15 @@
0
   <head>
0
     <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
0
     <title><%= @page_title ? "#{h(@page_title)} - alonetone" : "alonetone - a damn fine home for musicians. Upload mp3s and share"%> </title>
0
- <%= stylesheet_link_tag 'reset','typography', 'layout', 'nav', 'flash', 'tracks','playlists','tabs','alonetone', :cache => 'alonetone-v2'%>
0
+
0
+ <%= stylesheet_link_tag 'reset','typography', 'layout', 'nav', 'flash', 'tracks','playlists','tabs','alonetone', :cache => 'alonetone-v2'%>
0
     <%= stylesheet_link_tag 'ie6' if request.env['HTTP_USER_AGENT'] and request.env['HTTP_USER_AGENT'].include? "MSIE 6.0" %>
0
-
0
+ <%= '<meta name="robots" content="noindex,nofollow" />' unless request.host =~ /^http:\/\/alonetone.com|alonetone.com/ %>
0
     <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
0
- <meta name="verify-v1" content="aaIrlgAaz4LTgcMLni358eS3yFVofWVpOykHzegpXS4=" />
0
+ <meta name="verify-v1" content="aaIrlgAaz4LTgcMLni358eS3yFVofWVpOykHzegpXS4=" />
0
     <%= yield :css %>
0
     <link rel="alternate" type="application/rss+xml" title="Latest uploaded mp3s on alonetone" href="/latest.rss"/>
0
- <%= javascript_include_tag 'jquery','soundmanager','jquery-ui','jquery-fx','jquery-easing','jquery-carousel','jquery-lowpro','jquery-tabs','jquery-png','application', :cache => 'alonetone-v2' %>
0
+ <%= javascript_include_tag 'jquery','soundmanager','jquery-ui','jquery-fx','jquery-easing','jquery-carousel','jquery-lowpro','jquery-tabs','jquery-png','application', :cache => 'alonetone-v2' %>
0
     
0
     <!-- ensure token is available to javascript for accessible link posts, etc -->
0
     <%= render :partial => 'shared/javascript_auth_token' %>
...
13
14
15
16
 
17
18
19
...
13
14
15
 
16
17
18
19
0
@@ -13,7 +13,7 @@
0
     <ul class="user_links">
0
      <%= user_nav_item "Latest", user_home_path(@user), :title => "#{h @user.name}'s latest stuff on alonetone" %>
0
      <%= user_nav_item "Tracks", user_tracks_path(@user), :title => "#{h @user.name}'s uploaded mp3s on alonetone" if @user.assets_count > 0 %>
0
- <%= user_nav_item "Albums & Playlists", user_playlists_path(@user), :title => "#{h @user.name}'s albums and playlists on alonetone" if @user.has_public_playlists? %>
0
+ <%= user_nav_item "Albums & Playlists", user_playlists_path(@user), :title => "#{h @user.name}'s albums and playlists on alonetone" if @user.has_public_playlists? || (authorized_for(@playlist) && @user.playlists.include_private.count > 0) %>
0
      <%= user_nav_item "Favorites", user_playlist_path(@user, @user.favorites) if @user.favorites %>
0
      <%= user_nav_item "Profile", profile_path(@user), :title => "#{h @user.name}'s profile on alonetone" if @user.bio %>
0
   

Comments

    No one has commented yet.