forgeplus/app/controllers/ci/languages_controller.rb

21 lines
437 B
Ruby
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

class Ci::LanguagesController < Ci::BaseController
# TODO 需要开启权限认证只有该项目devops初始化成功后才能获取语言列表
before_action :find_langugae, only: :show
def index
@languages = Ci::Language.by_usage_amount_desc
end
def show
end
def common
@languages = Ci::Language.six_common
end
private
def find_langugae
@language = Ci::Language.find params[:id]
end
end