Skip to content

Commit

Permalink
show flickr link on photos
Browse files Browse the repository at this point in the history
  • Loading branch information
stereosupersonic committed Apr 2, 2015
1 parent 6ea19f5 commit ab37fca
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 1 deletion.
1 change: 1 addition & 0 deletions app/views/admin/albums/_form.html.haml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
= info_button "https://www.flickr.com/photos/organize/?start_tab=one_set#{@album.flickr_id}", "edit on Flickr"
= button_with_icon 'Neu von Flickr laden', reload_from_flickr_admin_album_path(@album), 'repeat', :method => :put
= show_button seo_album_path(@album.collection, @album), "Bilder"

%br
%h3= "flickr_id: #{@album.flickr_id}"
Expand Down
20 changes: 19 additions & 1 deletion app/views/admin/albums/show.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,29 @@
%li= link_to 'Administration', admin_root_path
%li= link_to 'Albums', admin_albums_path
%li.strong= @album.flickr_title
= show_button seo_album_path(@album.collection, @album), "Bilder"

= info_button "https://www.flickr.com/photos/organize/?start_tab=one_set#{@album.flickr_id}", "edit on Flickr"
= show_button seo_album_path(@album.collection, @album), "Bilder anzeigen"
- Album.attribute_names.each do |attr_name|
%p
%b= attr_name
= @album.send attr_name
%h3 Bilder
%table.table.table-bordered.table-striped.table-hover
%tr
%th
%th Erstellt
%th
%tr
- @album.photos.each do |photo|
%tr
%td= link_to image_tag( photo.url_icon , :class => "img-thumbnail"), admin_photo_path(photo)
%td= format_datetime photo.created_at
%td
= show_button "https://www.flickr.com/photos/sereosonic70/#{photo.flickr_id}/", 'Flickr anzeigen'
= show_button admin_photo_path(photo)
%br
= edit_button edit_admin_photo_path(photo)

= debug @album.flickr_info
= edit_button [:edit, :admin, @album]
Expand Down
1 change: 1 addition & 0 deletions app/views/admin/photos/show.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
= @photo.send attr_name

%p= image_tag @photo.url_big , :class => "img-thumbnail"
= show_button "https://www.flickr.com/photos/sereosonic70/#{@photo.flickr_id}/", 'Flickr anzeigen'
= debug @photo.flickr_info
= edit_button [:edit, :admin, @photo]
= back_button admin_photos_path

0 comments on commit ab37fca

Please sign in to comment.