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
8c1568d9
Commit
8c1568d9
authored
Oct 03, 2018
by
George Tsiolis
Committed by
Phil Hughes
Oct 03, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add copy to clipboard button for application id and secret
parent
09f38f8d
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
45 additions
and
22 deletions
+45
-22
app/assets/stylesheets/pages/commits.scss
app/assets/stylesheets/pages/commits.scss
+1
-0
app/views/admin/applications/show.html.haml
app/views/admin/applications/show.html.haml
+14
-7
app/views/doorkeeper/applications/show.html.haml
app/views/doorkeeper/applications/show.html.haml
+13
-6
changelogs/unreleased/add-clipboard-button-to-application-id-and-secret.yml
...sed/add-clipboard-button-to-application-id-and-secret.yml
+5
-0
locale/gitlab.pot
locale/gitlab.pot
+8
-5
spec/features/admin/admin_manage_applications_spec.rb
spec/features/admin/admin_manage_applications_spec.rb
+2
-2
spec/features/profiles/user_manages_applications_spec.rb
spec/features/profiles/user_manages_applications_spec.rb
+2
-2
No files found.
app/assets/stylesheets/pages/commits.scss
View file @
8c1568d9
...
@@ -223,6 +223,7 @@
...
@@ -223,6 +223,7 @@
}
}
}
}
.clipboard-group
,
.commit-sha-group
{
.commit-sha-group
{
display
:
inline-flex
;
display
:
inline-flex
;
...
...
app/views/admin/applications/show.html.haml
View file @
8c1568d9
-
page_title
@application
.
name
,
"Applications"
-
page_title
@application
.
name
,
"Applications"
%h3
.page-title
%h3
.page-title
Application:
#{
@application
.
name
}
Application:
#{
@application
.
name
}
...
@@ -6,23 +7,29 @@
...
@@ -6,23 +7,29 @@
%table
.table
%table
.table
%tr
%tr
%td
%td
Application Id
=
_
(
'Application ID'
)
%td
%td
%code
#application_id
=
@application
.
uid
.clipboard-group
.input-group
%input
.label.label-monospace
{
id:
"application_id"
,
type:
"text"
,
autocomplete:
'off'
,
value:
@application
.
uid
,
readonly:
true
}
.input-group-append
=
clipboard_button
(
target:
'#application_id'
,
title:
_
(
"Copy ID to clipboard"
),
class:
"btn btn btn-default"
)
%tr
%tr
%td
%td
Secret:
=
_
(
'Secret'
)
%td
%td
%code
#secret
=
@application
.
secret
.clipboard-group
.input-group
%input
.label.label-monospace
{
id:
"secret"
,
type:
"text"
,
autocomplete:
'off'
,
value:
@application
.
secret
,
readonly:
true
}
.input-group-append
=
clipboard_button
(
target:
'#application_id'
,
title:
_
(
"Copy secret to clipboard"
),
class:
"btn btn btn-default"
)
%tr
%tr
%td
%td
Callback url
=
_
(
'Callback URL'
)
%td
%td
-
@application
.
redirect_uri
.
split
.
each
do
|
uri
|
-
@application
.
redirect_uri
.
split
.
each
do
|
uri
|
%div
%div
%span
.monospace
=
uri
%span
.monospace
=
uri
%tr
%tr
%td
%td
Trusted
Trusted
...
...
app/views/doorkeeper/applications/show.html.haml
View file @
8c1568d9
...
@@ -10,18 +10,25 @@
...
@@ -10,18 +10,25 @@
%table
.table
%table
.table
%tr
%tr
%td
%td
=
_
(
'Application I
d
'
)
=
_
(
'Application I
D
'
)
%td
%td
%code
#application_id
=
@application
.
uid
.clipboard-group
.input-group
%input
.label.label-monospace
{
id:
"application_id"
,
type:
"text"
,
autocomplete:
'off'
,
value:
@application
.
uid
,
readonly:
true
}
.input-group-append
=
clipboard_button
(
target:
'#application_id'
,
title:
_
(
"Copy ID to clipboard"
),
class:
"btn btn btn-default"
)
%tr
%tr
%td
%td
=
_
(
'Secret
:
'
)
=
_
(
'Secret'
)
%td
%td
%code
#secret
=
@application
.
secret
.clipboard-group
.input-group
%input
.label.label-monospace
{
id:
"secret"
,
type:
"text"
,
autocomplete:
'off'
,
value:
@application
.
secret
,
readonly:
true
}
.input-group-append
=
clipboard_button
(
target:
'#application_id'
,
title:
_
(
"Copy secret to clipboard"
),
class:
"btn btn btn-default"
)
%tr
%tr
%td
%td
=
_
(
'Callback
url
'
)
=
_
(
'Callback
URL
'
)
%td
%td
-
@application
.
redirect_uri
.
split
.
each
do
|
uri
|
-
@application
.
redirect_uri
.
split
.
each
do
|
uri
|
%div
%div
...
...
changelogs/unreleased/add-clipboard-button-to-application-id-and-secret.yml
0 → 100644
View file @
8c1568d9
---
title
:
Add copy to clipboard button for application id and secret
merge_request
:
21978
author
:
George Tsiolis
type
:
other
locale/gitlab.pot
View file @
8c1568d9
...
@@ -598,7 +598,7 @@ msgstr ""
...
@@ -598,7 +598,7 @@ msgstr ""
msgid "Application"
msgid "Application"
msgstr ""
msgstr ""
msgid "Application I
d
"
msgid "Application I
D
"
msgstr ""
msgstr ""
msgid "Application: %{name}"
msgid "Application: %{name}"
...
@@ -1101,9 +1101,6 @@ msgstr ""
...
@@ -1101,9 +1101,6 @@ msgstr ""
msgid "Callback URL"
msgid "Callback URL"
msgstr ""
msgstr ""
msgid "Callback url"
msgstr ""
msgid "Can't find HEAD commit for this branch"
msgid "Can't find HEAD commit for this branch"
msgstr ""
msgstr ""
...
@@ -1930,6 +1927,9 @@ msgstr ""
...
@@ -1930,6 +1927,9 @@ msgstr ""
msgid "Copy HTTPS clone URL"
msgid "Copy HTTPS clone URL"
msgstr ""
msgstr ""
msgid "Copy ID to clipboard"
msgstr ""
msgid "Copy SSH clone URL"
msgid "Copy SSH clone URL"
msgstr ""
msgstr ""
...
@@ -1951,6 +1951,9 @@ msgstr ""
...
@@ -1951,6 +1951,9 @@ msgstr ""
msgid "Copy reference to clipboard"
msgid "Copy reference to clipboard"
msgstr ""
msgstr ""
msgid "Copy secret to clipboard"
msgstr ""
msgid "Copy to clipboard"
msgid "Copy to clipboard"
msgstr ""
msgstr ""
...
@@ -5318,7 +5321,7 @@ msgstr ""
...
@@ -5318,7 +5321,7 @@ msgstr ""
msgid "Seconds to wait for a storage access attempt"
msgid "Seconds to wait for a storage access attempt"
msgstr ""
msgstr ""
msgid "Secret
:
"
msgid "Secret"
msgstr ""
msgstr ""
msgid "Select"
msgid "Select"
...
...
spec/features/admin/admin_manage_applications_spec.rb
View file @
8c1568d9
...
@@ -16,7 +16,7 @@ RSpec.describe 'admin manage applications' do
...
@@ -16,7 +16,7 @@ RSpec.describe 'admin manage applications' do
check
:doorkeeper_application_trusted
check
:doorkeeper_application_trusted
click_on
'Submit'
click_on
'Submit'
expect
(
page
).
to
have_content
(
'Application: test'
)
expect
(
page
).
to
have_content
(
'Application: test'
)
expect
(
page
).
to
have_content
(
'Application I
d
'
)
expect
(
page
).
to
have_content
(
'Application I
D
'
)
expect
(
page
).
to
have_content
(
'Secret'
)
expect
(
page
).
to
have_content
(
'Secret'
)
expect
(
page
).
to
have_content
(
'Trusted Y'
)
expect
(
page
).
to
have_content
(
'Trusted Y'
)
...
@@ -28,7 +28,7 @@ RSpec.describe 'admin manage applications' do
...
@@ -28,7 +28,7 @@ RSpec.describe 'admin manage applications' do
click_on
'Submit'
click_on
'Submit'
expect
(
page
).
to
have_content
(
'test_changed'
)
expect
(
page
).
to
have_content
(
'test_changed'
)
expect
(
page
).
to
have_content
(
'Application I
d
'
)
expect
(
page
).
to
have_content
(
'Application I
D
'
)
expect
(
page
).
to
have_content
(
'Secret'
)
expect
(
page
).
to
have_content
(
'Secret'
)
expect
(
page
).
to
have_content
(
'Trusted N'
)
expect
(
page
).
to
have_content
(
'Trusted N'
)
...
...
spec/features/profiles/user_manages_applications_spec.rb
View file @
8c1568d9
...
@@ -16,7 +16,7 @@ describe 'User manages applications' do
...
@@ -16,7 +16,7 @@ describe 'User manages applications' do
click_on
'Save application'
click_on
'Save application'
expect
(
page
).
to
have_content
'Application: test'
expect
(
page
).
to
have_content
'Application: test'
expect
(
page
).
to
have_content
'Application I
d
'
expect
(
page
).
to
have_content
'Application I
D
'
expect
(
page
).
to
have_content
'Secret'
expect
(
page
).
to
have_content
'Secret'
click_on
'Edit'
click_on
'Edit'
...
@@ -26,7 +26,7 @@ describe 'User manages applications' do
...
@@ -26,7 +26,7 @@ describe 'User manages applications' do
click_on
'Save application'
click_on
'Save application'
expect
(
page
).
to
have_content
'test_changed'
expect
(
page
).
to
have_content
'test_changed'
expect
(
page
).
to
have_content
'Application I
d
'
expect
(
page
).
to
have_content
'Application I
D
'
expect
(
page
).
to
have_content
'Secret'
expect
(
page
).
to
have_content
'Secret'
visit
applications_profile_path
visit
applications_profile_path
...
...
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