require 'fiona7/controller_helper' module Fiona7 class BlobsController < ActionController::Base include Fiona7::BinaryHandling::DeliveryMixin include Fiona7::ControllerHelper include RailsConnector::CmsAccessible before_filter :load_obj before_filter :ensure_object_is_active before_filter :ensure_object_is_permitted protected def load_obj @obj = Fiona7::WriteObj.find(binary_id_from_params) end def render_obj_error(code, msg) head code end def binary_id_from_params params[:id] end def transformation_from_params if params[:t] BinaryHandling::ParamEncoder.new.decode( params[:t] ) end end def set_header(name, value) response.headers[name] = value end end end