Skip to content
Snippets Groups Projects
Commit b3a736ed authored by GitLab Bot's avatar GitLab Bot
Browse files

Add latest changes from gitlab-org/gitlab@master

parent 5366964a
No related branches found
No related tags found
No related merge requests found
Showing
with 132 additions and 60 deletions
Loading
Loading
@@ -47,8 +47,7 @@
.settings-content
= render 'performance_bar'
 
- if Feature.enabled?(:self_monitoring_project)
.js-self-monitoring-settings{ data: self_monitoring_project_data }
.js-self-monitoring-settings{ data: self_monitoring_project_data }
 
%section.settings.as-usage.no-animate#js-usage-settings{ class: ('expanded' if expanded_by_default?) }
.settings-header#usage-statistics
Loading
Loading
Loading
Loading
@@ -10,7 +10,7 @@
= project_icon(@project, alt: @project.name, class: 'avatar avatar-tile s64', width: 64, height: 64)
.d-flex.flex-column.flex-wrap.align-items-baseline
.d-inline-flex.align-items-baseline
%h1.home-panel-title.prepend-top-8.append-bottom-5.qa-project-name
%h1.home-panel-title.prepend-top-8.append-bottom-5{ data: { qa_selector: 'project_name_content' } }
= @project.name
%span.visibility-icon.text-secondary.prepend-left-4.has-tooltip{ data: { container: 'body' }, title: visibility_icon_description(@project) }
= visibility_level_icon(@project.visibility_level, fw: false, options: {class: 'icon'})
Loading
Loading
@@ -70,7 +70,7 @@
- source = visible_fork_source(@project)
- if source
#{ s_('ForkedFromProjectPath|Forked from') }
= link_to source.full_name, project_path(source)
= link_to source.full_name, project_path(source), data: { qa_selector: 'forked_from_link' }
- else
= s_('ForkedFromProjectPath|Forked from an inaccessible project')
 
Loading
Loading
.tree-content-holder.js-tree-content{ data: tree_content_data(@logs_path, @project, @path) }
.table-holder.bordered-box
%table.table#tree-slider{ class: "table_#{@hex_path} tree-table qa-file-tree" }
%table.table#tree-slider{ class: "table_#{@hex_path} tree-table" }
%thead
%tr
%th= s_('ProjectFileTree|Name')
Loading
Loading
Loading
Loading
@@ -84,17 +84,16 @@
 
= render 'projects/find_file_link'
 
- if can_create_mr_from_fork
- if can_collaborate || current_user&.already_forked?(@project)
- if vue_file_list_enabled?
#js-tree-web-ide-link.d-inline-block
- else
= link_to ide_edit_path(@project, @ref, @path), class: 'btn btn-default qa-web-ide-button' do
= _('Web IDE')
- if can_collaborate || current_user&.already_forked?(@project)
- if vue_file_list_enabled?
#js-tree-web-ide-link.d-inline-block
- else
= link_to '#modal-confirm-fork', class: 'btn btn-default qa-web-ide-button', data: { target: '#modal-confirm-fork', toggle: 'modal'} do
= link_to ide_edit_path(@project, @ref, @path), class: 'btn btn-default qa-web-ide-button' do
= _('Web IDE')
= render 'shared/confirm_fork_modal', fork_path: ide_fork_and_edit_path(@project, @ref, @path)
- elsif can_create_mr_from_fork
= link_to '#modal-confirm-fork', class: 'btn btn-default qa-web-ide-button', data: { target: '#modal-confirm-fork', toggle: 'modal'} do
= _('Web IDE')
= render 'shared/confirm_fork_modal', fork_path: ide_fork_and_edit_path(@project, @ref, @path)
 
- if show_xcode_link?(@project)
.project-action-button.project-xcode.inline<
Loading
Loading
---
title: Enable Web IDE on projects without Merge Requests
merge_request: 24508
author:
type: fixed
---
title: When a namespace GitLab Subscription expires, disable SSO enforcement
merge_request: 21135
author:
type: fixed
---
title: Use closest allowed visibility level on group creation when importing groups
using Group Import/Export
merge_request: 25026
author:
type: fixed
---
title: Separate entities into own class files
merge_request: 24985
author: Rajendra Kadam
type: added
---
title: Separate Application and Blob entities into own class files
merge_request: 24997
author: Rajendra Kadam
type: added
---
title: Remove self monitoring feature flag
merge_request: 23631
author:
type: other
Loading
Loading
@@ -72,6 +72,7 @@ projects:
effects if the package is included multiple times.
- Use `go fmt` before committing ([Gofmt](https://golang.org/cmd/gofmt/) is a
tool that automatically formats Go source code).
- Place private methods below the first caller method in the source file.
 
### Automatic linting
 
Loading
Loading
Loading
Loading
@@ -199,50 +199,6 @@ module API
end.compact
end
end
class UserAgentDetail < Grape::Entity
expose :user_agent
expose :ip_address
expose :submitted, as: :akismet_submitted
end
class CustomAttribute < Grape::Entity
expose :key
expose :value
end
class PagesDomainCertificateExpiration < Grape::Entity
expose :expired?, as: :expired
expose :expiration
end
class Application < Grape::Entity
expose :id
expose :uid, as: :application_id
expose :name, as: :application_name
expose :redirect_uri, as: :callback_url
expose :confidential
end
# Use with care, this exposes the secret
class ApplicationWithSecret < Application
expose :secret
end
class Blob < Grape::Entity
expose :basename
expose :data
expose :path
# TODO: :filename was renamed to :path but both still return the full path,
# in the future we can only return the filename here without the leading
# directory path.
# https://gitlab.com/gitlab-org/gitlab/issues/34521
expose :filename, &:path
expose :id
expose :ref
expose :startline
expose :project_id
end
end
end
 
Loading
Loading
# frozen_string_literal: true
module API
module Entities
class Application < Grape::Entity
expose :id
expose :uid, as: :application_id
expose :name, as: :application_name
expose :redirect_uri, as: :callback_url
expose :confidential
end
end
end
# frozen_string_literal: true
module API
module Entities
# Use with care, this exposes the secret
class ApplicationWithSecret < Entities::Application
expose :secret
end
end
end
# frozen_string_literal: true
module API
module Entities
class Blob < Grape::Entity
expose :basename
expose :data
expose :path
# TODO: :filename was renamed to :path but both still return the full path,
# in the future we can only return the filename here without the leading
# directory path.
# https://gitlab.com/gitlab-org/gitlab/issues/34521
expose :filename, &:path
expose :id
expose :ref
expose :startline
expose :project_id
end
end
end
# frozen_string_literal: true
module API
module Entities
class CustomAttribute < Grape::Entity
expose :key
expose :value
end
end
end
# frozen_string_literal: true
module API
module Entities
class PagesDomainCertificateExpiration < Grape::Entity
expose :expired?, as: :expired
expose :expiration
end
end
end
# frozen_string_literal: true
module API
module Entities
class UserAgentDetail < Grape::Entity
expose :user_agent
expose :ip_address
expose :submitted, as: :akismet_submitted
end
end
end
Loading
Loading
@@ -5,15 +5,25 @@ module API
MAXIMUM_FILE_SIZE = 50.megabytes.freeze
 
helpers do
def authorize_create_group!
parent_group = find_group!(params[:parent_id]) if params[:parent_id].present?
def parent_group
find_group!(params[:parent_id]) if params[:parent_id].present?
end
 
def authorize_create_group!
if parent_group
authorize! :create_subgroup, parent_group
else
authorize! :create_group
end
end
def closest_allowed_visibility_level
if parent_group
Gitlab::VisibilityLevel.closest_allowed_level(parent_group.visibility_level)
else
Gitlab::VisibilityLevel::PRIVATE
end
end
end
 
resource :groups, requirements: API::NAMESPACE_OR_PROJECT_REQUIREMENTS do
Loading
Loading
@@ -59,6 +69,7 @@ module API
path: params[:path],
name: params[:name],
parent_id: params[:parent_id],
visibility_level: closest_allowed_visibility_level,
import_export_upload: ImportExportUpload.new(import_file: uploaded_file)
}
 
Loading
Loading
Loading
Loading
@@ -37,6 +37,7 @@ excluded_attributes:
- :runners_token
- :runners_token_encrypted
- :saml_discovery_token
- :visibility_level
 
methods:
labels:
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment