|
|
@ -2,13 +2,16 @@
|
|
|
|
# REDO: 创建版本库权限控制
|
|
|
|
# REDO: 创建版本库权限控制
|
|
|
|
class ShixunsController < ApplicationController
|
|
|
|
class ShixunsController < ApplicationController
|
|
|
|
layout 'base_shixun'
|
|
|
|
layout 'base_shixun'
|
|
|
|
before_filter :require_login, :except => [:ghook, :download_file]
|
|
|
|
before_filter :require_login, :except => [:ghook, :download_file, :show, :index]
|
|
|
|
before_filter :check_authentication, :except => [:ghook, :download_file]
|
|
|
|
before_filter :check_authentication, :except => [:ghook, :download_file, :show, :index]
|
|
|
|
before_filter :find_shixun, :except => [ :index, :new, :create, :index, :search, :shixun_courses, :new_disscuss, :shixun_migrate, :qrcode, :download_file, :departments, :get_mirror_script, :send_message_to_administrator]
|
|
|
|
before_filter :find_shixun, :except => [ :index, :new, :create, :index, :search, :shixun_courses, :new_disscuss, :shixun_migrate, :qrcode, :download_file, :departments, :get_mirror_script, :send_message_to_administrator]
|
|
|
|
|
|
|
|
|
|
|
|
skip_before_filter :verify_authenticity_token, :only => [:ghook, :download_file]
|
|
|
|
skip_before_filter :verify_authenticity_token, :only => [:ghook, :download_file]
|
|
|
|
before_filter :view_allow, :only => [:show, :collaborators, :propaedeutics, :shixun_discuss, :ranking_list]
|
|
|
|
before_filter :view_allow, :only => [:collaborators, :propaedeutics, :shixun_discuss, :ranking_list]
|
|
|
|
before_filter :require_manager, :only => [ :settings, :add_script, :publish, :collaborators_delete, :shixun_members_added, :add_collaborators, :update, :destroy]
|
|
|
|
before_filter :require_manager, :only => [ :settings, :add_script, :publish, :collaborators_delete, :shixun_members_added, :add_collaborators, :update, :destroy]
|
|
|
|
before_filter :validation_email, :only => [:new]
|
|
|
|
before_filter :validation_email, :only => [:new]
|
|
|
|
|
|
|
|
# 移动云ToC模式权限控制
|
|
|
|
|
|
|
|
# before_filter :ecloud_auth, :except => [:show, :index]
|
|
|
|
|
|
|
|
|
|
|
|
include ApplicationHelper
|
|
|
|
include ApplicationHelper
|
|
|
|
include ShixunsHelper
|
|
|
|
include ShixunsHelper
|
|
|
|