1
0
Fork 0
mirror of https://github.com/kbparagua/paloma synced 2023-03-27 23:21:17 -04:00
paloma/spec/sample_app/controllers.rb

30 lines
423 B
Ruby
Raw Normal View History

2012-12-17 05:50:23 -05:00
# Dummy Controllers
class ApplicationController < ActionController::Base
end
class ArticlesController < ApplicationController
def show
@article = Article.find params[:id]
end
def new
@article = Article.new
end
def create
@article = Article.new params[:article]
if @article.save
redirect_to @article
else
js_callback false
render :new
end
end
end