Commit 19863167

mo k <mo@mokhan.ca>
2012-07-29 03:16:09
remove all the comments from the uploaders.
1 parent 49c408b
Changed files (5)
app/assets/javascripts/creations.js
@@ -29,6 +29,6 @@ Creations.Crop = {
 };
 Creations.Show = {
   initialize: function(){
-    $('.thumbnail').colorbox({rel:'thumbnail'});
+    $('.gallery').colorbox({rel:'gallery'});
   }
 };
app/uploaders/image_uploader.rb
@@ -23,21 +23,16 @@ class ImageUploader < CarrierWave::Uploader::Base
   #   "/images/fallback/" + [version_name, "default.png"].compact.join('_')
   # end
   process :set_content_type
-  #process :resize_to_fit => [660, 460]
-  #process :resize_to_fit => [960, 720]
   process :convert => 'png'
-  # process :manualcrop
 
   # Create different versions of your uploaded files:
   version :large do 
     process :manualcrop
-    #process :resize_to_fit => [660, 460]
     process :resize_to_fit => [1160, 870]
   end
 
   version :thumb do
     process :manualcrop
-    #process :resize_to_fill => [210, 150]
     process :resize_to_fill => [360, 268]
   end
 
app/uploaders/photo_uploader.rb
@@ -34,8 +34,7 @@ class PhotoUploader < CarrierWave::Uploader::Base
   # Process files as they are uploaded:
   # process :scale => [200, 300]
   process :set_content_type
-  #process :resize_to_fit => [660, 470]
-  #process :resize_to_fit => [1160, 870]
+  process :resize_to_fit => [1160, 870]
   process :convert => 'png'
   #
   # def scale(width, height)
app/views/creations/show.html.erb
@@ -29,9 +29,9 @@
 <div class="row">
   <div class="span12">
     <ul class="thumbnails">
-      <li class="span6"><a class="thumbnail" href="<%= @creation.image_url(:large).to_s %>"><img src="<%= @creation.image_url(:large).to_s %>" alt="<%= @creation.name %>" /></a></li>
+      <li class="span6"><a class="thumbnail gallery" href="<%= @creation.image_url(:large).to_s %>"><img src="<%= @creation.image_url(:large).to_s %>" alt="<%= @creation.name %>" /></a></li>
       <% @creation.photos.each do |photo| %>
-        <li class="span3"><a class="thumbnail" href="<%= photo.image.url.to_s %>"><img src="<%= photo.image.thumb.url.to_s %>" alt="<%= @creation.name %>" /></a></li>
+      <li class="span3"><a class="thumbnail gallery" href="<%= photo.image.url.to_s %>"><img src="<%= photo.image.thumb.url.to_s %>" alt="<%= @creation.name %>" /></a></li>
       <% end %>
       <% if @creation.user == current_user %>
         <% if @creation.photos.length < 4 %>
db/schema.rb
@@ -29,18 +29,18 @@ ActiveRecord::Schema.define(:version => 20120717123632) do
   add_index "active_admin_comments", ["resource_type", "resource_id"], :name => "index_admin_notes_on_resource_type_and_resource_id"
 
   create_table "admin_users", :force => true do |t|
-    t.string   "email",                                 :default => "", :null => false
-    t.string   "encrypted_password",     :limit => 128, :default => "", :null => false
+    t.string   "email",                  :default => "", :null => false
+    t.string   "encrypted_password",     :default => "", :null => false
     t.string   "reset_password_token"
     t.datetime "reset_password_sent_at"
     t.datetime "remember_created_at"
-    t.integer  "sign_in_count",                         :default => 0
+    t.integer  "sign_in_count",          :default => 0
     t.datetime "current_sign_in_at"
     t.datetime "last_sign_in_at"
     t.string   "current_sign_in_ip"
     t.string   "last_sign_in_ip"
-    t.datetime "created_at",                                            :null => false
-    t.datetime "updated_at",                                            :null => false
+    t.datetime "created_at",                             :null => false
+    t.datetime "updated_at",                             :null => false
   end
 
   add_index "admin_users", ["email"], :name => "index_admin_users_on_email", :unique => true
@@ -106,18 +106,18 @@ ActiveRecord::Schema.define(:version => 20120717123632) do
   end
 
   create_table "users", :force => true do |t|
-    t.string   "email",                                 :default => "", :null => false
-    t.string   "encrypted_password",     :limit => 128, :default => "", :null => false
+    t.string   "email",                  :default => "", :null => false
+    t.string   "encrypted_password",     :default => "", :null => false
     t.string   "reset_password_token"
     t.datetime "reset_password_sent_at"
     t.datetime "remember_created_at"
-    t.integer  "sign_in_count",                         :default => 0
+    t.integer  "sign_in_count",          :default => 0
     t.datetime "current_sign_in_at"
     t.datetime "last_sign_in_at"
     t.string   "current_sign_in_ip"
     t.string   "last_sign_in_ip"
-    t.datetime "created_at",                                            :null => false
-    t.datetime "updated_at",                                            :null => false
+    t.datetime "created_at",                             :null => false
+    t.datetime "updated_at",                             :null => false
     t.string   "name"
     t.string   "website"
     t.string   "twitter"