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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
e79b0dd7
Commit
e79b0dd7
authored
Apr 16, 2016
by
Jacob Schatz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Simplify random user generation.
parent
ffd2416c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
12 deletions
+7
-12
app/controllers/help_controller.rb
app/controllers/help_controller.rb
+1
-6
app/views/help/ui.html.haml
app/views/help/ui.html.haml
+6
-6
No files found.
app/controllers/help_controller.rb
View file @
e79b0dd7
...
@@ -51,12 +51,7 @@ class HelpController < ApplicationController
...
@@ -51,12 +51,7 @@ class HelpController < ApplicationController
end
end
def
ui
def
ui
# this will work on gitlab.com
@user
=
User
.
new
(
id:
0
,
name:
'John Doe'
,
username:
'@johndoe'
)
@some_user
=
User
.
find_by
(
username:
'dzaporozhets'
)
if
@some_user
.
nil?
# this will work in dev
@some_user
=
User
.
find
(
1
)
end
end
end
private
private
...
...
app/views/help/ui.html.haml
View file @
e79b0dd7
...
@@ -345,11 +345,11 @@
...
@@ -345,11 +345,11 @@
%ul
%ul
%li
%li
%a
.dropdown-menu-user-link.is-active
{
href:
"#"
}
%a
.dropdown-menu-user-link.is-active
{
href:
"#"
}
=
link_to_member_avatar
(
@
some_
user
,
size:
30
)
=
link_to_member_avatar
(
@user
,
size:
30
)
%strong
.dropdown-menu-user-full-name
%strong
.dropdown-menu-user-full-name
=
@
some_
user
.
name
=
@user
.
name
.dropdown-menu-user-username
.dropdown-menu-user-username
=
@
some_
user
.
to_reference
=
@user
.
to_reference
.example
.example
%div
%div
...
@@ -372,11 +372,11 @@
...
@@ -372,11 +372,11 @@
%ul
%ul
%li
%li
%a
.dropdown-menu-user-link.is-active
{
href:
"#"
}
%a
.dropdown-menu-user-link.is-active
{
href:
"#"
}
=
link_to_member_avatar
(
@
some_
user
,
size:
30
)
=
link_to_member_avatar
(
@user
,
size:
30
)
%strong
.dropdown-menu-user-full-name
%strong
.dropdown-menu-user-full-name
=
@
some_
user
.
name
=
@user
.
name
.dropdown-menu-user-username
.dropdown-menu-user-username
=
@
some_
user
.
to_reference
=
@user
.
to_reference
.dropdown-page-two
.dropdown-page-two
.dropdown-title
.dropdown-title
%button
.dropdown-title-button.dropdown-menu-back
{
aria:
{
label:
"Go back"
}}
%button
.dropdown-title-button.dropdown-menu-back
{
aria:
{
label:
"Go back"
}}
...
...
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