Sha256: f2459e76264c02ae3f6e144d328824036d4221ca8fbb73907b213624975e8a1e

Contents?: true

Size: 987 Bytes

Versions: 53

Compression:

Stored size: 987 Bytes

Contents

# -*- coding: utf-8 -*-
class TransSidBaseController < ApplicationController
  # 事前にセッションを作成しないと trans_sid が有効にならない
  before_filter :session_init

  def form
    render :inline=>%{<%= form_tag do %>Hello<% end %>}
  end
  def link
    render :inline=>%{<%= link_to "linkto" %>}
  end
  def redirect
    redirect_to('/')
  end
  def session_init
    session[:jpmobile] = "everyleaf"
    @user = User.find(1) rescue User.create(:id => 1, :name => "everyleaf")
  end

  def form_path
    render :inline=>%{<%= form_for @user do %>Hello<% end %>}
  end
  def form_path_admin
    render :inline=>%{<%= form_for [:admin, @user] do %>Hello<% end %>}
  end

  def link_path
    render :inline => %{<%= link_to "linkto", @user -%>}
  end
  def link_path_admin
    render :inline => %{<%= link_to "linkto", [:admin, @user] -%>}
  end

  def redirect_path
    redirect_to @user
  end
  def redirect_path_admin
    redirect_to [:admin, @user]
  end
end

Version data entries

53 entries across 45 versions & 1 rubygems

Version Path
jpmobile-2.0.11 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-1.0.12 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-1.0.11 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.10 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-1.0.10 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.9 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-1.0.9 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.8 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-3.0.1 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.7 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.6 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-3.0.0 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.5 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-1.0.8 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.4 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.3 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-1.0.7 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-1.0.6 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.2 test/rails/overrides/app/controllers/trans_sid_base_controller.rb
jpmobile-2.0.1 test/rails/overrides/app/controllers/trans_sid_base_controller.rb