Sha256: b10f3def2af9da6f89adb9dcc20d55e7ffcca36845bb458559dee243e2672dab
Contents?: true
Size: 783 Bytes
Versions: 6
Compression:
Stored size: 783 Bytes
Contents
class ManifestationRelationshipsController < InheritedResources::Base respond_to :html, :json has_scope :page, :default => 1 load_and_authorize_resource before_filter :prepare_options, :except => [:index, :destroy] def new @manifestation_relationship = ManifestationRelationship.new(params[:manifestation_relationship]) @manifestation_relationship.parent = Manifestation.find(params[:manifestation_id]) rescue nil @manifestation_relationship.child = Manifestation.find(params[:child_id]) rescue nil end def update if params[:move] move_position(@manifestation_relationship, params[:move]) return end update! end private def prepare_options @manifestation_relationship_types = ManifestationRelationshipType.all end end
Version data entries
6 entries across 6 versions & 1 rubygems