app/controllers/phcscriptcdnpro/script/extensions_controller.rb in phcscriptcdnpro-74.0.0 vs app/controllers/phcscriptcdnpro/script/extensions_controller.rb in phcscriptcdnpro-75.0.0

- old
+ new

@@ -9,11 +9,11 @@ before_action :set_paper_trail_whodunnit before_action :set_script_extension, only: [:show, :edit, :update, :destroy] # INDEX def index - @script_extensions = Script::Extension.all + @script_extensions = Script::Extension.where(org_id: current_user.org_id) end # SHOW def show @script_extensions = Script::Extension.friendly.find(params[:id]) @@ -31,9 +31,10 @@ # CREATE def create @script_extension = Script::Extension.new(script_extension_params) @script_extension.user_id = current_user.id + @script_extension.org_id = current_user.org_id if @script_extension.save redirect_to script_extensions_url, :flash => { :success => 'Extension was successfully created.' } else render :new end