1 class ArtistsController < ApplicationController
2 if Manifest.manifest.magic_numbers['run_mode'] == 0
3 before_filter :authenticate_user, :only => [:new, :create, :edit, :update, :destroy]
4 before_filter :authenticate_artist, :only => [:edit, :update, :destroy]
6 before_filter :authenticate_resource_reader, :only => [:index, :show, :resource_pictures]
7 before_filter :authenticate_user, :only => [:new, :create, :edit, :update, :destroy]
8 before_filter :authenticate_artist, :only => [:edit, :update, :destroy]
19 def show_html_format format
26 respond_to do |format|
27 show_html_format format
28 show_prof_format format
29 show_json_format format
47 @item = @my_model_class.new
49 @item.attributes = params[@my_model_class.item_name]
50 @item.overwrite @operators
51 render_create root_path
56 @item.attributes = params[@my_model_class.item_name]
57 @item.overwrite @operators
58 render_update '/home/configure'
62 @artist = Artist.edit(params[:id], @operators)
65 respond_to do |format|
66 format.html { redirect_to artists_url }
67 format.json { head :ok }