Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
4b89322e
Commit
4b89322e
authored
Oct 18, 2021
by
scootergrisen
Committed by
Martin Wortschack
Oct 18, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove "::" from namespace part of translation strings
parent
d59ee459
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
24 additions
and
24 deletions
+24
-24
app/models/metrics/dashboard/annotation.rb
app/models/metrics/dashboard/annotation.rb
+3
-3
app/services/metrics/dashboard/annotations/create_service.rb
app/services/metrics/dashboard/annotations/create_service.rb
+3
-3
app/services/metrics/dashboard/annotations/delete_service.rb
app/services/metrics/dashboard/annotations/delete_service.rb
+2
-2
app/services/metrics/users_starred_dashboards/create_service.rb
...rvices/metrics/users_starred_dashboards/create_service.rb
+2
-2
locale/gitlab.pot
locale/gitlab.pot
+14
-14
No files found.
app/models/metrics/dashboard/annotation.rb
View file @
4b89322e
...
@@ -32,19 +32,19 @@ module Metrics
...
@@ -32,19 +32,19 @@ module Metrics
def
ending_at_after_starting_at
def
ending_at_after_starting_at
return
if
ending_at
.
blank?
||
starting_at
.
blank?
||
starting_at
<=
ending_at
return
if
ending_at
.
blank?
||
starting_at
.
blank?
||
starting_at
<=
ending_at
errors
.
add
(
:ending_at
,
s_
(
"Metrics
::Dashboard::
Annotation|can't be before starting_at time"
))
errors
.
add
(
:ending_at
,
s_
(
"Metrics
Dashboard
Annotation|can't be before starting_at time"
))
end
end
def
single_ownership
def
single_ownership
return
if
cluster
.
nil?
^
environment
.
nil?
return
if
cluster
.
nil?
^
environment
.
nil?
errors
.
add
(
:base
,
s_
(
"Metrics
::Dashboard::
Annotation|Annotation can't belong to both a cluster and an environment at the same time"
))
errors
.
add
(
:base
,
s_
(
"Metrics
Dashboard
Annotation|Annotation can't belong to both a cluster and an environment at the same time"
))
end
end
def
orphaned_annotation
def
orphaned_annotation
return
if
cluster
.
present?
||
environment
.
present?
return
if
cluster
.
present?
||
environment
.
present?
errors
.
add
(
:base
,
s_
(
"Metrics
::Dashboard::
Annotation|Annotation must belong to a cluster or an environment"
))
errors
.
add
(
:base
,
s_
(
"Metrics
Dashboard
Annotation|Annotation must belong to a cluster or an environment"
))
end
end
end
end
end
end
...
...
app/services/metrics/dashboard/annotations/create_service.rb
View file @
4b89322e
...
@@ -30,7 +30,7 @@ module Metrics
...
@@ -30,7 +30,7 @@ module Metrics
options
[
:environment
]
=
environment
options
[
:environment
]
=
environment
success
(
options
)
success
(
options
)
else
else
error
(
s_
(
'Metrics
::Dashboard::
Annotation|You are not authorized to create annotation for selected environment'
))
error
(
s_
(
'Metrics
Dashboard
Annotation|You are not authorized to create annotation for selected environment'
))
end
end
end
end
...
@@ -39,7 +39,7 @@ module Metrics
...
@@ -39,7 +39,7 @@ module Metrics
options
[
:cluster
]
=
cluster
options
[
:cluster
]
=
cluster
success
(
options
)
success
(
options
)
else
else
error
(
s_
(
'Metrics
::Dashboard::
Annotation|You are not authorized to create annotation for selected cluster'
))
error
(
s_
(
'Metrics
Dashboard
Annotation|You are not authorized to create annotation for selected cluster'
))
end
end
end
end
...
@@ -51,7 +51,7 @@ module Metrics
...
@@ -51,7 +51,7 @@ module Metrics
success
(
options
)
success
(
options
)
rescue
Gitlab
::
Template
::
Finders
::
RepoTemplateFinder
::
FileNotFoundError
rescue
Gitlab
::
Template
::
Finders
::
RepoTemplateFinder
::
FileNotFoundError
error
(
s_
(
'Metrics
::Dashboard::
Annotation|Dashboard with requested path can not be found'
))
error
(
s_
(
'Metrics
Dashboard
Annotation|Dashboard with requested path can not be found'
))
end
end
def
create
(
options
)
def
create
(
options
)
...
...
app/services/metrics/dashboard/annotations/delete_service.rb
View file @
4b89322e
...
@@ -27,7 +27,7 @@ module Metrics
...
@@ -27,7 +27,7 @@ module Metrics
if
Ability
.
allowed?
(
user
,
:delete_metrics_dashboard_annotation
,
annotation
)
if
Ability
.
allowed?
(
user
,
:delete_metrics_dashboard_annotation
,
annotation
)
success
success
else
else
error
(
s_
(
'Metrics
::Dashboard::
Annotation|You are not authorized to delete this annotation'
))
error
(
s_
(
'Metrics
Dashboard
Annotation|You are not authorized to delete this annotation'
))
end
end
end
end
...
@@ -35,7 +35,7 @@ module Metrics
...
@@ -35,7 +35,7 @@ module Metrics
if
annotation
.
destroy
if
annotation
.
destroy
success
success
else
else
error
(
s_
(
'Metrics
::Dashboard::
Annotation|Annotation has not been deleted'
))
error
(
s_
(
'Metrics
Dashboard
Annotation|Annotation has not been deleted'
))
end
end
end
end
end
end
...
...
app/services/metrics/users_starred_dashboards/create_service.rb
View file @
4b89322e
...
@@ -35,7 +35,7 @@ module Metrics
...
@@ -35,7 +35,7 @@ module Metrics
if
Ability
.
allowed?
(
user
,
:create_metrics_user_starred_dashboard
,
project
)
if
Ability
.
allowed?
(
user
,
:create_metrics_user_starred_dashboard
,
project
)
success
(
user:
user
,
project:
project
)
success
(
user:
user
,
project:
project
)
else
else
error
(
s_
(
'Metrics
::
UsersStarredDashboards|You are not authorized to add star to this dashboard'
))
error
(
s_
(
'MetricsUsersStarredDashboards|You are not authorized to add star to this dashboard'
))
end
end
end
end
...
@@ -44,7 +44,7 @@ module Metrics
...
@@ -44,7 +44,7 @@ module Metrics
options
[
:dashboard_path
]
=
dashboard_path
options
[
:dashboard_path
]
=
dashboard_path
success
(
options
)
success
(
options
)
else
else
error
(
s_
(
'Metrics
::
UsersStarredDashboards|Dashboard with requested path can not be found'
))
error
(
s_
(
'MetricsUsersStarredDashboards|Dashboard with requested path can not be found'
))
end
end
end
end
...
...
locale/gitlab.pot
View file @
4b89322e
...
@@ -21670,34 +21670,28 @@ msgstr ""
...
@@ -21670,34 +21670,28 @@ msgstr ""
msgid "Metrics and profiling"
msgid "Metrics and profiling"
msgstr ""
msgstr ""
msgid "Metrics
::Dashboard::
Annotation|Annotation can't belong to both a cluster and an environment at the same time"
msgid "Metrics
Dashboard
Annotation|Annotation can't belong to both a cluster and an environment at the same time"
msgstr ""
msgstr ""
msgid "Metrics
::Dashboard::
Annotation|Annotation has not been deleted"
msgid "Metrics
Dashboard
Annotation|Annotation has not been deleted"
msgstr ""
msgstr ""
msgid "Metrics
::Dashboard::
Annotation|Annotation must belong to a cluster or an environment"
msgid "Metrics
Dashboard
Annotation|Annotation must belong to a cluster or an environment"
msgstr ""
msgstr ""
msgid "Metrics
::Dashboard::
Annotation|Dashboard with requested path can not be found"
msgid "Metrics
Dashboard
Annotation|Dashboard with requested path can not be found"
msgstr ""
msgstr ""
msgid "Metrics
::Dashboard::
Annotation|You are not authorized to create annotation for selected cluster"
msgid "Metrics
Dashboard
Annotation|You are not authorized to create annotation for selected cluster"
msgstr ""
msgstr ""
msgid "Metrics
::Dashboard::
Annotation|You are not authorized to create annotation for selected environment"
msgid "Metrics
Dashboard
Annotation|You are not authorized to create annotation for selected environment"
msgstr ""
msgstr ""
msgid "Metrics
::Dashboard::
Annotation|You are not authorized to delete this annotation"
msgid "Metrics
Dashboard
Annotation|You are not authorized to delete this annotation"
msgstr ""
msgstr ""
msgid "Metrics::Dashboard::Annotation|can't be before starting_at time"
msgid "MetricsDashboardAnnotation|can't be before starting_at time"
msgstr ""
msgid "Metrics::UsersStarredDashboards|Dashboard with requested path can not be found"
msgstr ""
msgid "Metrics::UsersStarredDashboards|You are not authorized to add star to this dashboard"
msgstr ""
msgstr ""
msgid "MetricsSettings|Add a button to the metrics dashboard linking directly to your existing external dashboard."
msgid "MetricsSettings|Add a button to the metrics dashboard linking directly to your existing external dashboard."
...
@@ -21724,6 +21718,12 @@ msgstr ""
...
@@ -21724,6 +21718,12 @@ msgstr ""
msgid "MetricsSettings|User's local timezone"
msgid "MetricsSettings|User's local timezone"
msgstr ""
msgstr ""
msgid "MetricsUsersStarredDashboards|Dashboard with requested path can not be found"
msgstr ""
msgid "MetricsUsersStarredDashboards|You are not authorized to add star to this dashboard"
msgstr ""
msgid "Metrics|1. Define and preview panel"
msgid "Metrics|1. Define and preview panel"
msgstr ""
msgstr ""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment