Skip to content
Extraits de code Groupes Projets
Valider 01dac4d1 rédigé par Raphael's avatar Raphael
Parcourir les fichiers

Take tinymce out of layout

parent dc1dd077
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -21,6 +21,7 @@ class PhotosController < ApplicationController ...@@ -21,6 +21,7 @@ class PhotosController < ApplicationController
def new def new
@photo = Photo.new @photo = Photo.new
render :partial => "new_photo"
end end
def destroy def destroy
......
...@@ -46,6 +46,9 @@ class User ...@@ -46,6 +46,9 @@ class User
options.delete(:group_id) options.delete(:group_id)
model_class = class_name.to_s.camelize.constantize model_class = class_name.to_s.camelize.constantize
pp options
post = model_class.instantiate(options) post = model_class.instantiate(options)
post.creator_signature = post.sign_with_key(encryption_key) post.creator_signature = post.sign_with_key(encryption_key)
post.save post.save
......
...@@ -13,7 +13,6 @@ ...@@ -13,7 +13,6 @@
/= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" /= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"
= javascript_include_tag 'jquery142', 'rails', 'google' = javascript_include_tag 'jquery142', 'rails', 'google'
= javascript_include_tag 'tiny_mce/tiny_mce'
= javascript_include_tag 'jquery.infieldlabel', 'jquery.cycle/jquery.cycle.min.js' = javascript_include_tag 'jquery.infieldlabel', 'jquery.cycle/jquery.cycle.min.js'
= javascript_include_tag 'fancybox/jquery.fancybox-1.3.1.pack' = javascript_include_tag 'fancybox/jquery.fancybox-1.3.1.pack'
......
...@@ -12,8 +12,9 @@ ...@@ -12,8 +12,9 @@
$("#add_photo_loader").fadeOut(400); $("#add_photo_loader").fadeOut(400);
$("#photo_title_status").text("Done!"); $("#photo_title_status").text("Done!");
$("#progress_report").html("Great job!"); $("#progress_report").html("");
}, resetPhotoButton
},
onStart: function(event, total){ onStart: function(event, total){
$("#add_photo_button").html( "Uploading Photos" ); $("#add_photo_button").html( "Uploading Photos" );
$("#add_photo_loader").fadeIn(400); $("#add_photo_loader").fadeIn(400);
...@@ -26,6 +27,14 @@ ...@@ -26,6 +27,14 @@
}); });
}); });
function resetPhotoButton{
$("#add_photo_button").click(function (evt){
$("#new_photo_pane").html($.get("photos/ajax_new"));
$("#add_photo_button").unbind();
$("#add_photo_button").fancybox();
}
}
%h1 %h1
%span{:id=>"photo_title_status"} %span{:id=>"photo_title_status"}
Add photos to Add photos to
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter