git-subtree-dir: RubyFun git-subtree-mainline: a04a5027875fe2e51a5a08dc7aed05e3e06284b1 git-subtree-split: b01c6826131196ba58b5288a3182f2526c89c249
19 lines
227 B
Ruby
19 lines
227 B
Ruby
class FooController < ApplicationController
|
|
layout :figure_out_layout
|
|
|
|
def index
|
|
end
|
|
|
|
def pretty
|
|
end
|
|
|
|
def figure_out_layout
|
|
if action_name =~ /pretty/
|
|
'pretty'
|
|
else
|
|
'standard'
|
|
end
|
|
end
|
|
|
|
end
|