From d712218a14f35a390d26c399462cc431df8676f0 Mon Sep 17 00:00:00 2001 From: danielvincent Date: Mon, 9 Aug 2010 20:18:20 -0700 Subject: [PATCH] removed commented out stuff on photo_new partial. also, fixed the delete button in photo show. --- app/views/photos/_new_photo.haml | 27 --------------------------- app/views/photos/show.html.haml | 4 ++-- 2 files changed, 2 insertions(+), 29 deletions(-) diff --git a/app/views/photos/_new_photo.haml b/app/views/photos/_new_photo.haml index ef9396ac7..83547fdaa 100644 --- a/app/views/photos/_new_photo.haml +++ b/app/views/photos/_new_photo.haml @@ -7,47 +7,20 @@ onStart: function(event, total) { return confirm("You are about to upload " + total + " photos. Are you sure?"); }, - setName: function(text) { - //$("#progress_report_name").text(text); - }, - setStatus: function(text) { - //$("#progress_report_status").text(text); - }, - setProgress: function(val) { - //$("#progress_report_bar").css('width', Math.ceil(val*100)+"%"); - }, - onFinishOne: function(event, response, name, number, total) { - //alert(response); - }, onFinish: function(event, total){ - //$("#progress_report").delay(600).slideUp(200); - //$("#add_photo_pane").delay(600).fadeOut(200); $("#add_photo_button .button").html( "Add Photos" ); $("#add_photo_loader").fadeOut(0); }, onStart: function(event, total){ $("#add_photo_pane").fadeOut(400); $("#add_photo_button .button").html( "Uploading Photos" ); - //$("#add_photo_button").prepend( "Loader" ); $("#add_photo_loader").fadeIn(400); return true; } }); }); -:css - #progress_report, #progress_report_name, #progress_report_status{ - font-size: 12px; - padding: 0; - line-height: auto; - } - = form_for photo, :html => {:multipart => true} do |f| = f.error_messages = f.hidden_field :album_id, :value => album.id = f.file_field :image, :multiple => 'multiple' - - #progress_report{ :style => "display:none;" } - = image_tag "loader.gif" - #progress_report_name - #progress_report_status{ :style => "font-style: italic;" } diff --git a/app/views/photos/show.html.haml b/app/views/photos/show.html.haml index bf5a8f01d..e27988446 100644 --- a/app/views/photos/show.html.haml +++ b/app/views/photos/show.html.haml @@ -27,8 +27,8 @@ = link_to "⇧ #{@album.name}", album_path(@album) -if current_user.owns? @album - .button.right - = link_to 'Delete Photo', @photo, :confirm => 'Are you sure?', :method => :delete + .right + = link_to 'Delete Photo', @photo, :confirm => 'Are you sure?', :method => :delete, :class => 'button' %h4{:class => "show_post_comments"} = "comments (#{@photo.comments.count})"