class Wco::GalleriesController

def j_show

def j_show
  authorize! :show, @gallery
  respond_to do |format|
    format.json do
      jjj = {}
      jjj[:photos] = @gallery.photos.map do |ph|
        { :thumbnail_url => ph.photo.url( :thumb ),
        :delete_type => 'DELETE',
        :delete_url => photo_path(ph) }
      end
      render :json => jjj
    end
  end
end