|
|
|
@ -3,21 +3,21 @@ class ShixunsController < ApplicationController
|
|
|
|
|
include ApplicationHelper
|
|
|
|
|
|
|
|
|
|
before_action :require_login, :check_auth, except: [:download_file, :index, :menus, :show, :show_right, :ranking_list,
|
|
|
|
|
:discusses, :collaborators, :fork_list, :propaedeutics, :add_file]
|
|
|
|
|
:discusses, :collaborators, :fork_list, :propaedeutics]
|
|
|
|
|
before_action :check_account, only: [:new, :create, :shixun_exec]
|
|
|
|
|
|
|
|
|
|
before_action :find_shixun, except: [:index, :new, :create, :menus, :get_recommend_shixuns,
|
|
|
|
|
:propaedeutics, :departments, :apply_shixun_mirror,
|
|
|
|
|
:get_mirror_script, :download_file]
|
|
|
|
|
|
|
|
|
|
before_action :shixun_access_allowed, except: [:index, :new, :create, :menus, :get_recommend_shixuns, :add_file,
|
|
|
|
|
before_action :shixun_access_allowed, except: [:index, :new, :create, :menus, :get_recommend_shixuns,
|
|
|
|
|
:propaedeutics, :departments, :apply_shixun_mirror,
|
|
|
|
|
:get_mirror_script, :download_file]
|
|
|
|
|
before_action :find_repo_name, only: [:repository, :commits, :file_content, :update_file, :shixun_exec, :copy, :add_file]
|
|
|
|
|
|
|
|
|
|
before_action :allowed, only: [:update, :close, :update_propaedeutics, :settings, :publish,
|
|
|
|
|
:shixun_members_added, :change_manager, :collaborators_delete,
|
|
|
|
|
:cancel_publish, :add_collaborators]
|
|
|
|
|
:cancel_publish, :add_collaborators, :add_file]
|
|
|
|
|
before_action :portion_allowed, only: [:copy]
|
|
|
|
|
|
|
|
|
|
before_action :special_allowed, only: [:send_to_course, :search_user_courses]
|
|
|
|
|