Class: ImagesController
- Inherits:
-
InheritedResources::Base
- Object
- InheritedResources::Base
- ImagesController
- Defined in:
- app/controllers/images_controller.rb
Instance Method Summary collapse
Instance Method Details
#collection ⇒ Object
25 26 27 28 |
# File 'app/controllers/images_controller.rb', line 25 def collection @images ||= end_of_association_chain. paginate(:page => params[:page], :order => 'created_at DESC' ) end |
#create ⇒ Object
13 14 15 |
# File 'app/controllers/images_controller.rb', line 13 def create create! {edit_gallery_path(@gallery, params.slice(:CKEditor, :CKEditorFuncNum, :langCode))} end |
#index ⇒ Object
5 6 7 8 9 10 11 |
# File 'app/controllers/images_controller.rb', line 5 def index index! do |format| if params[:CKEditorFuncNum] format.html {render :action=>:index, :layout=>"image_dialog"} end end end |
#show ⇒ Object
17 18 19 20 21 22 23 |
# File 'app/controllers/images_controller.rb', line 17 def show show! do |format| if params[:CKEditorFuncNum] format.html {render :layout=>"image_dialog"} end end end |