Sha256: cd5363ad661622c966fc0aded03ce824c73e0525b9ba34873c07dd87c97d2741
Contents?: true
Size: 351 Bytes
Versions: 2
Compression:
Stored size: 351 Bytes
Contents
class EricWeixin::Cms::BaseController < ApplicationController before_filter :need_login around_filter :round def round yield end def current_user return nil if session[:employee_id].blank? ::Personal::Employee.find(session[:employee_id]) end def need_login redirect_to '/' if current_user.blank? return end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
eric_weixin-0.1.1 | app/controllers/eric_weixin/cms/base_controller.rb |
eric_weixin-0.1.0 | app/controllers/eric_weixin/cms/base_controller.rb |