mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-21 04:05:45 +08:00
Merge branch 'dev_trustie' into dev_chain
This commit is contained in:
@@ -7,8 +7,8 @@ class RepositoriesController < ApplicationController
|
||||
before_action :authorizate!, except: [:sync_mirror, :tags, :commit]
|
||||
before_action :find_repository_by_id, only: %i[commit sync_mirror tags]
|
||||
before_action :authorizate_user_can_edit_repo!, only: %i[sync_mirror]
|
||||
before_action :get_ref, only: %i[entries sub_entries]
|
||||
before_action :get_statistics, only: %i[entries sub_entries]
|
||||
before_action :get_ref, only: %i[entries sub_entries top_counts]
|
||||
before_action :get_statistics, only: %i[top_counts]
|
||||
|
||||
def show
|
||||
@user = current_user
|
||||
@@ -32,6 +32,10 @@ class RepositoriesController < ApplicationController
|
||||
@path = Gitea.gitea_config[:domain]+"/#{@project.owner.login}/#{@project.identifier}/raw/branch/#{@ref}/"
|
||||
end
|
||||
|
||||
def top_counts
|
||||
@result = Gitea::Repository::GetService.new(@project.owner, @project.identifier).call
|
||||
end
|
||||
|
||||
def sub_entries
|
||||
file_path_uri = URI.parse(URI.encode(params[:filepath].to_s.strip))
|
||||
interactor = Repositories::EntriesInteractor.call(@project.owner, @project.identifier, file_path_uri, ref: @ref)
|
||||
|
||||
Reference in New Issue
Block a user