1
0
Fork 0

Service icons

This commit is contained in:
Gregory Eremin 2011-09-26 14:51:52 +04:00
parent 0f62fae63c
commit 6be5868588
9 changed files with 19 additions and 2 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 152 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 318 B

View File

@ -44,3 +44,7 @@ $ ->
$('.dropdown-menu li a').live 'click', ->
$(this).parent().parent().parent().toggleClass('open')
false
$('.foreign-link').live 'click', ->
# window.open($(this).attr('href'))
e.preventDefault();
false

View File

@ -9,6 +9,13 @@
}
.desc {
height: 220px;
.service-icons {
margin-top: 15px;
a {
text_decoration: none;
margin-right: 10px;
}
}
}
}

View File

@ -78,9 +78,10 @@ class ArtistController < ApplicationController
id: artist.id,
name: artist.name,
desc: ActionController::Base.helpers.strip_tags(artist.desc),
pic: artist.pic_url
pic: artist.pic_url,
urls: artist.artist_links
}
ap artist.artist_links
media_types = @@default_album_types
session = Session.find_by_key(session_key)
unless session.nil?

View File

@ -7,6 +7,11 @@
.span7.columns.desc
%h2= @artist[:artist][:name]
= @artist[:artist][:desc] unless @artist[:artist][:desc].nil?
.service-icons
- @artist[:artist][:urls].each do |service|
- if ['wikipedia', 'microblog', 'official_homepage', 'social_network'].include?service.service
%a.foreign-link{ :href => service.url, :target => '_blank' }
= image_tag 'services/'+service.service+(service.service == 'official_homepage' ? '.png' : '.ico')
- @artist[:albums].each do |album|