Sha256: 23184dccf91ce65040c349b6f63f3bfc2558214ab733493761e8e1053c61e2e0

Contents?: true

Size: 416 Bytes

Versions: 6

Compression:

Stored size: 416 Bytes

Contents

class ProjectOptionsController < ApplicationController
  before_action :get_project
  attr_reader :project


  def update
    project.props.merge! params[:options]
    project.save!
    head :ok
  end


  def destroy
    project.props.delete! params[:key]
    project.save!
    head :ok
  end


private

  def get_project
    @project = Project.find_by_slug!(params[:slug])
    authorize! :read, @project
  end

end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
houston-core-0.8.4 app/controllers/project_options_controller.rb
houston-core-0.8.3 app/controllers/project_options_controller.rb
houston-core-0.8.2 app/controllers/project_options_controller.rb
houston-core-0.8.1 app/controllers/project_options_controller.rb
houston-core-0.8.0 app/controllers/project_options_controller.rb
houston-core-0.8.0.pre2 app/controllers/project_options_controller.rb