Add latest changes from gitlab-org/gitlab@master

This commit is contained in:
GitLab Bot
2025-07-03 03:10:37 +00:00
parent f95337d05e
commit 2a708022d4
16 changed files with 134 additions and 9 deletions

View File

@ -113,7 +113,7 @@ export default {
</gl-disclosure-dropdown-item>
</gl-disclosure-dropdown>
<div class="gl-ml-2" data-testid="information">
<gl-sprintf :message="s__('BulkImport|Showing %{start}-%{end} of %{total}')">
<gl-sprintf :message="s__('BulkImport|Showing %{start} - %{end} of %{total}')">
<template #start>
{{ paginationInfo.start }}
</template>

View File

@ -3,7 +3,9 @@
module WorkItems
module Widgets
class LinkedResources < Base
delegate :zoom_meetings, to: :work_item
def zoom_meetings
work_item.zoom_meetings.added_to_issue
end
end
end
end

View File

@ -821,6 +821,10 @@ vulnerability_occurrences:
- table: projects
column: project_id
on_delete: async_delete
vulnerability_partial_scans:
- table: projects
column: project_id
on_delete: async_delete
vulnerability_reads:
- table: cluster_agents
column: casted_cluster_agent_id

View File

@ -59,6 +59,7 @@ InitializerConnections.raise_if_new_database_connection do
scope path: '/users/sign_up', module: :registrations, as: :users_sign_up do
Gitlab.ee do
resource :welcome, only: [:show, :update], controller: 'welcome'
resource :trial_welcome, only: [:new], controller: 'trial_welcome'
resource :company, only: [:new, :create], controller: 'company'
resources :groups, only: [:new, :create]
end

View File

@ -0,0 +1,13 @@
---
table_name: vulnerability_partial_scans
classes:
- Vulnerabilities::PartialScan
feature_categories:
- vulnerability_management
description: Contains information related to partial scans
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/195373
milestone: '18.2'
gitlab_schema: gitlab_sec
sharding_key:
project_id: projects
table_size: small

View File

@ -0,0 +1,16 @@
# frozen_string_literal: true
class CreatePartialScanTable < Gitlab::Database::Migration[2.3]
milestone '18.2'
def change
# rubocop:disable Migration/EnsureFactoryForTable -- Ruby namespace differs from table prefix
create_table :vulnerability_partial_scans, id: false do |t|
t.timestamps_with_timezone null: false
t.bigint :scan_id, null: false, primary_key: true, index: true, default: nil
t.bigint :project_id, null: false, index: true
t.integer :mode, limit: 2, null: false
end
# rubocop:enable Migration/EnsureFactoryForTable
end
end

View File

@ -0,0 +1,16 @@
# frozen_string_literal: true
class AddForeignKeyToPartialScanId < Gitlab::Database::Migration[2.3]
milestone '18.2'
disable_ddl_transaction!
def up
add_concurrent_foreign_key :vulnerability_partial_scans, :security_scans, column: :scan_id, on_delete: :cascade
end
def down
with_lock_retries do
remove_foreign_key_if_exists :vulnerability_partial_scans, column: :scan_id
end
end
end

View File

@ -11,6 +11,8 @@ class RemovePCiBuildsTriggerRequestId < Gitlab::Database::Migration[2.3]
def up
return unless can_execute_on?(:ci_builds)
execute("ALTER SEQUENCE ci_builds_id_seq OWNED BY p_ci_builds.id")
remove_column(TABLE, COLUMN)
end

View File

@ -0,0 +1 @@
82bca77125c6ec691f4cb9a65ff3086a980876bf022d12c47bf0194ae1f66d0e

View File

@ -0,0 +1 @@
d9bf5dd197018a90a5af537837dd676d4293df494245b09fc604b85ba8d507a1

View File

@ -25695,6 +25695,14 @@ CREATE SEQUENCE vulnerability_occurrences_id_seq
ALTER SEQUENCE vulnerability_occurrences_id_seq OWNED BY vulnerability_occurrences.id;
CREATE TABLE vulnerability_partial_scans (
created_at timestamp with time zone NOT NULL,
updated_at timestamp with time zone NOT NULL,
scan_id bigint NOT NULL,
project_id bigint NOT NULL,
mode smallint NOT NULL
);
CREATE TABLE vulnerability_reads (
id bigint NOT NULL,
vulnerability_id bigint NOT NULL,
@ -31840,6 +31848,9 @@ ALTER TABLE ONLY vulnerability_occurrence_identifiers
ALTER TABLE ONLY vulnerability_occurrences
ADD CONSTRAINT vulnerability_occurrences_pkey PRIMARY KEY (id);
ALTER TABLE ONLY vulnerability_partial_scans
ADD CONSTRAINT vulnerability_partial_scans_pkey PRIMARY KEY (scan_id);
ALTER TABLE ONLY vulnerability_reads
ADD CONSTRAINT vulnerability_reads_pkey PRIMARY KEY (id);
@ -38443,6 +38454,10 @@ CREATE INDEX index_vulnerability_occurrences_on_vulnerability_id ON vulnerabilit
CREATE INDEX index_vulnerability_occurrences_prim_iden_id_and_vuln_id ON vulnerability_occurrences USING btree (primary_identifier_id, vulnerability_id);
CREATE INDEX index_vulnerability_partial_scans_on_project_id ON vulnerability_partial_scans USING btree (project_id);
CREATE INDEX index_vulnerability_partial_scans_on_scan_id ON vulnerability_partial_scans USING btree (scan_id);
CREATE INDEX index_vulnerability_reads_common_attrs_for_groups ON vulnerability_reads USING btree (resolved_on_default_branch, state, report_type, severity, traversal_ids, vulnerability_id, has_vulnerability_resolution) WHERE (archived = false);
CREATE INDEX index_vulnerability_reads_common_finder_query ON vulnerability_reads USING btree (project_id, state, report_type, severity, vulnerability_id DESC, dismissal_reason, has_vulnerability_resolution);
@ -44220,6 +44235,9 @@ ALTER TABLE ONLY lists
ALTER TABLE ONLY agent_activity_events
ADD CONSTRAINT fk_d6f785c9fc FOREIGN KEY (user_id) REFERENCES users(id) ON DELETE SET NULL;
ALTER TABLE ONLY vulnerability_partial_scans
ADD CONSTRAINT fk_d7311920a8 FOREIGN KEY (scan_id) REFERENCES security_scans(id) ON DELETE CASCADE;
ALTER TABLE ONLY user_achievements
ADD CONSTRAINT fk_d7653ef780 FOREIGN KEY (revoked_by_user_id) REFERENCES users(id) ON DELETE SET NULL;

View File

@ -5,13 +5,14 @@ module Gitlab
module Reports
module Security
class Scan
attr_accessor :type, :status, :start_time, :end_time
attr_accessor :type, :status, :start_time, :end_time, :partial_scan_mode
def initialize(params = {})
@type = params['type']
@status = params['status']
@start_time = params['start_time']
@end_time = params['end_time']
@partial_scan_mode = params.dig('partial_scan', 'mode')
end
def to_hash

View File

@ -11646,7 +11646,7 @@ msgstr ""
msgid "BulkImport|Select whether user memberships in groups and projects are imported."
msgstr ""
msgid "BulkImport|Showing %{start}-%{end} of %{total}"
msgid "BulkImport|Showing %{start} - %{end} of %{total}"
msgstr ""
msgid "BulkImport|Some groups are imported without projects."
@ -30252,12 +30252,18 @@ msgstr ""
msgid "Group milestone"
msgstr ""
msgid "Group name"
msgstr ""
msgid "Group name (your organization)"
msgstr ""
msgid "Group name can contain only letters, digits, dashes, spaces, dots, underscores, parenthesis, and emojis."
msgstr ""
msgid "Group name is required."
msgstr ""
msgid "Group name must start with a letter, digit, emoji, or underscore."
msgstr ""
@ -48299,6 +48305,9 @@ msgstr ""
msgid "Project name can contain only lowercase or uppercase letters, digits, emoji, spaces, dots, underscores, dashes, or pluses."
msgstr ""
msgid "Project name is required."
msgstr ""
msgid "Project name must start with a letter, digit, emoji, or underscore."
msgstr ""
@ -49478,6 +49487,9 @@ msgstr ""
msgid "Projects are where you store your code, access issues, wiki, and other features of GitLab."
msgstr ""
msgid "Projects contain the resources for your repository"
msgstr ""
msgid "Projects contributed to"
msgstr ""
@ -65539,6 +65551,9 @@ msgstr ""
msgid "Trial|Continue"
msgstr ""
msgid "Trial|Continue to GitLab"
msgstr ""
msgid "Trial|Continue with trial"
msgstr ""
@ -65569,6 +65584,9 @@ msgstr ""
msgid "Trial|We need a few more details from you to activate your trial."
msgstr ""
msgid "Trial|Welcome to GitLab"
msgstr ""
msgid "Trial|Your free Ultimate & GitLab Duo Enterprise Trial lasts for 60 days. After this period, you can maintain a GitLab Free account forever, or upgrade to a paid plan."
msgstr ""
@ -72356,6 +72374,9 @@ msgstr ""
msgid "You tried to fork %{link_to_the_project} but it failed for the following reason:"
msgstr ""
msgid "You use groups to organize your projects"
msgstr ""
msgid "You will be redirected to %{strong_start}%{domain}%{strong_end} after authorizing."
msgstr ""

View File

@ -112,7 +112,6 @@ spec/frontend/vue_popovers_spec.js
spec/frontend/vue_shared/components/file_tree_spec.js
spec/frontend/vue_shared/components/filtered_search_bar/tokens/date_token_spec.js
spec/frontend/vue_shared/components/metric_images/metric_image_details_modal_spec.js
spec/frontend/vue_shared/components/pagination_bar/pagination_bar_spec.js
spec/frontend/vue_shared/components/registry/code_instruction_spec.js
spec/frontend/vue_shared/components/tooltip_on_truncate_spec.js
spec/frontend/vue_shared/components/upload_dropzone/upload_dropzone_spec.js

View File

@ -17,13 +17,32 @@ RSpec.describe Gitlab::Ci::Reports::Security::Scan do
context 'when all params are given' do
it 'initializes an instance' do
expect { subject }.not_to raise_error
expect(subject).to have_attributes(
status: 'success',
type: 'dependency-scanning',
start_time: 'placeholer',
end_time: 'placholder'
end_time: 'placholder',
partial_scan_mode: nil
)
end
end
context 'when partial scan' do
let(:params) do
{
status: 'success',
type: 'dependency-scanning',
start_time: 'placeholer',
end_time: 'placholder',
partial_scan: {
mode: 'differential'
}
}
end
it 'sets partial_scan_mode attribute' do
expect(subject).to have_attributes(
partial_scan_mode: 'differential'
)
end
end

View File

@ -9,6 +9,17 @@ RSpec.describe WorkItems::Widgets::LinkedResources, feature_category: :team_plan
describe '#zoom_meetings' do
subject { described_class.new(work_item).zoom_meetings }
it { is_expected.to eq(work_item.zoom_meetings) }
context 'when zoom meeting is added' do
it { is_expected.to eq(work_item.zoom_meetings.added_to_issue) }
it { is_expected.to include(zoom_meeting) }
end
context 'when zoom meeting is removed' do
before do
zoom_meeting.update!(issue_status: :removed)
end
it { is_expected.not_to include(zoom_meeting) }
end
end
end