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
fca1ffb8
Commit
fca1ffb8
authored
Jan 29, 2012
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bootstrap: Issues, Merge Requests, SSH Key completed
parent
20721eff
Changes
32
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
32 changed files
with
213 additions
and
1010 deletions
+213
-1010
app/assets/stylesheets/buttons.scss
app/assets/stylesheets/buttons.scss
+0
-118
app/assets/stylesheets/common.scss
app/assets/stylesheets/common.scss
+7
-8
app/assets/stylesheets/dashboard.scss
app/assets/stylesheets/dashboard.scss
+0
-27
app/assets/stylesheets/style.scss
app/assets/stylesheets/style.scss
+0
-570
app/assets/stylesheets/tags.scss
app/assets/stylesheets/tags.scss
+0
-55
app/assets/stylesheets/top_panel.scss
app/assets/stylesheets/top_panel.scss
+1
-1
app/controllers/admin/projects_controller.rb
app/controllers/admin/projects_controller.rb
+6
-0
app/controllers/keys_controller.rb
app/controllers/keys_controller.rb
+1
-1
app/views/admin/projects/_form.html.haml
app/views/admin/projects/_form.html.haml
+13
-16
app/views/admin/users/_form.html.haml
app/views/admin/users/_form.html.haml
+19
-26
app/views/admin/users/new.html.haml
app/views/admin/users/new.html.haml
+2
-5
app/views/commits/index.html.haml
app/views/commits/index.html.haml
+5
-1
app/views/dashboard/_merge_requests_feed.html.haml
app/views/dashboard/_merge_requests_feed.html.haml
+1
-1
app/views/issues/_show.html.haml
app/views/issues/_show.html.haml
+3
-5
app/views/issues/index.html.haml
app/views/issues/index.html.haml
+4
-7
app/views/issues/index.js.haml
app/views/issues/index.js.haml
+1
-1
app/views/issues/show.html.haml
app/views/issues/show.html.haml
+14
-14
app/views/keys/_form.html.haml
app/views/keys/_form.html.haml
+12
-10
app/views/keys/_show.html.haml
app/views/keys/_show.html.haml
+7
-7
app/views/keys/index.html.haml
app/views/keys/index.html.haml
+5
-11
app/views/keys/new.html.haml
app/views/keys/new.html.haml
+2
-4
app/views/keys/show.html.haml
app/views/keys/show.html.haml
+5
-8
app/views/layouts/_head_panel.html.haml
app/views/layouts/_head_panel.html.haml
+0
-4
app/views/layouts/_project_side.html.haml
app/views/layouts/_project_side.html.haml
+4
-4
app/views/layouts/profile.html.haml
app/views/layouts/profile.html.haml
+12
-10
app/views/merge_requests/show.html.haml
app/views/merge_requests/show.html.haml
+16
-14
app/views/profile/design.html.haml
app/views/profile/design.html.haml
+19
-21
app/views/profile/password.html.haml
app/views/profile/password.html.haml
+37
-40
app/views/profile/show.html.haml
app/views/profile/show.html.haml
+6
-1
spec/requests/dashboard_merge_requests_spec.rb
spec/requests/dashboard_merge_requests_spec.rb
+0
-7
spec/requests/issues_spec.rb
spec/requests/issues_spec.rb
+6
-8
spec/requests/projects_spec.rb
spec/requests/projects_spec.rb
+5
-5
No files found.
app/assets/stylesheets/buttons.scss
deleted
100644 → 0
View file @
20721eff
/* Buttons */
.grey-button
{
border-radius
:
5px
;
font-size
:
12px
;
font-weight
:
bold
;
padding
:
5px
17px
;
border
:
1px
solid
#999
;
color
:
#666
;
display
:
inline-block
;
box-shadow
:
0
1px
2px
rgba
(
0
,
0
,
0
,.
3
);
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
26
,
color-stop
(
0
.192
,
#fff
)
,
to
(
#f4f4f4
));
background-image
:
-webkit-linear-gradient
(
#fff
19
.2%
,
#f4f4f4
);
background-image
:
-moz-linear-gradient
(
#fff
19
.2%
,
#f4f4f4
);
background-image
:
-o-linear-gradient
(
#fff
19
.2%
,
#f4f4f4
);
}
.red-button
{
border-radius
:
5px
;
font-size
:
12px
;
font-weight
:
bold
;
padding
:
5px
17px
;
border
:
1px
solid
#999
;
color
:
#666
;
display
:
inline-block
;
box-shadow
:
0
1px
2px
rgba
(
0
,
0
,
0
,.
3
);
background
:
#D12F19
;
color
:
white
;
}
.positive-button
{
border-radius
:
5px
;
font-size
:
12px
;
font-weight
:
bold
;
padding
:
5px
17px
;
border
:
1px
solid
#999
;
color
:
#666
;
display
:
inline-block
;
box-shadow
:
0
1px
2px
rgba
(
0
,
0
,
0
,.
3
);
background
:
#4A2
;
color
:
white
;
}
.lbutton
,
.lite_button
{
display
:block
;
float
:left
;
margin
:
0px
5px
0px
0px
;
padding
:
5px
10px
;
font-family
:
"Helvetica Neue"
,
Arial
,
Helvetica
,
sans-serif
;
border
:
1px
solid
#D3D3D3
;
background
:white
;
font-size
:
12px
!
important
;
line-height
:
130%
;
text-decoration
:none
;
font-weight
:bold
;
color
:
#565656
;
cursor
:pointer
;
&
:hover
{
border
:
1px
solid
#C2E1EF
;
color
:
#0099FF
;
}
&
.hm
{
margin
:
0px
0px
;
}
&
.vm
{
margin
:
5px
0px
;
}
}
a
.button
,
input
.button
{
font-weight
:
bold
;
padding
:
10px
20px
;
text-align
:
center
;
display
:
inline-block
;
border-radius
:
5px
;
color
:
#578E91
;
font-size
:
12px
;
text-transform
:
uppercase
;
border
:
1px
solid
#8CE2E6
;
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
34
,
color-stop
(
0
.794
,
#dbf5f6
)
,
to
(
#c5eef0
));
background-image
:
-webkit-linear-gradient
(
#dbf5f6
79
.4%
,
#c5eef0
);
background-image
:
-moz-linear-gradient
(
#dbf5f6
79
.4%
,
#c5eef0
);
background-image
:
-o-linear-gradient
(
#dbf5f6
79
.4%
,
#c5eef0
);
}
input
.button
{
margin-bottom
:
1
.5em
}
.button
:hover
{
color
:
rgba
(
0
,
0
,
0
,.
8
)}
.button.green
{
margin-right
:
0
;
}
.button.yellow
{
color
:
#908054
;
border-color
:
#DDCDA1
;
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
34
,
color-stop
(
0
.794
,
#FFEFC3
)
,
to
(
#F3E3B7
));
background-image
:
-webkit-linear-gradient
(
#FFEFC3
79
.4%
,
#F3E3B7
);
background-image
:
-moz-linear-gradient
(
#FFEFC3
79
.4%
,
#F3E3B7
);
background-image
:
-o-linear-gradient
(
#FFEFC3
79
.4%
,
#F3E3B7
);
}
.button.blue
{
color
:
#417E97
;
border-color
:
#b2cdec
;
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
34
,
color-stop
(
0
.794
,
#dbe8f6
)
,
to
(
#c7daf1
));
background-image
:
-webkit-linear-gradient
(
#dbe8f6
79
.4%
,
#c7daf1
);
background-image
:
-moz-linear-gradient
(
#dbe8f6
79
.4%
,
#c7daf1
);
background-image
:
-o-linear-gradient
(
#dbe8f6
79
.4%
,
#c7daf1
);
}
.button-small
{
text-shadow
:
none
;
padding
:
4px
10px
;
}
.button-green
{
background
:
#A6B807
;
color
:
white
}
app/assets/stylesheets/common.scss
View file @
fca1ffb8
...
...
@@ -117,6 +117,7 @@ $blue_link: "#2fa0bb";
margin
:
10px
0
0
0
;
font-size
:
13px
;
font-weight
:bold
;
color
:
#444
;
}
}
...
...
@@ -141,6 +142,12 @@ img.avatar {
border-radius
:
4px
;
}
img
.lil_av
{
padding-left
:
5px
;
position
:
relative
;
top
:
3px
;
}
.media-grid
{
h3
,
h2
,
h4
{
&
.media_h
{
...
...
@@ -176,14 +183,6 @@ img.avatar {
@import
"notes.css.scss"
;
@import
"login.scss"
;
//@import "style.scss";
//@import "commits.css.scss";
//@import "dashboard.scss";
//@import "tags.scss";
//@import "buttons.scss";
/** CODE HIGHTLIGHT **/
@import
"highlight.css.scss"
;
@import
"highlight.black.css.scss"
;
...
...
app/assets/stylesheets/dashboard.scss
deleted
100644 → 0
View file @
20721eff
.application
.news-feed
{
margin-left
:
285px
;
min-height
:
600px
;
margin-top
:
20px
;
margin-right
:
2px
;
padding
:
20px
;}
.application
.application-content
{
position
:
relative
;
float
:
left
;
width
:
100%
;
height
:
100%
;
}
.application
.news-feed
h2
{
float
:
left
;}
body
.application
aside
{
min-height
:
820px
;
position
:
relative
;
top
:
0
;
bottom
:
0
;
right
:
0
;
width
:
260px
;
float
:
left
;
border-right
:
1px
solid
$border_color
;
padding
:
20px
;
padding-right
:
0
;
h4
{
margin
:
0
;
border-bottom
:
1px
solid
#ccc
;
padding
:
20px
20px
20px
0px
;
font-size
:
11px
;
font-weight
:
bold
;
text-transform
:
uppercase
;}
.project-list
{
list-style
:
none
;
margin
:
0
;
padding
:
0
;}
.project-list
li
a
{
background
:
white
;
color
:
#{
$blue_link
}
;
display
:
block
;
border-bottom
:
1px
solid
$lite_border_color
;
padding
:
14px
6%
14px
0px
;}
.project-list
li
a
span
.project-name
{
font-size
:
14px
;
display
:
block
;
margin-bottom
:
8px
}
.project-list
li
a
span
.time
{
color
:
#666
;
font-weight
:
normal
;
font-size
:
11px
}
.project-list
li
a
span
.arrow
{
float
:
right
;
background
:
#E3E5EA
;
padding
:
10px
;
border-radius
:
5px
;
margin-top
:
2px
;
text-shadow
:
none
;
color
:
#999
}
}
body
.application
.news-feed
.project-updates
{
margin-bottom
:
20px
;
display
:
block
;
width
:
100%
;
.data
{
padding
:
0
}
a
.project-update
{
padding
:
10px
;
overflow
:
hidden
;
display
:
block
;}
a
.project-update
:last-child
{
border-bottom
:
0
}
a
.project-update
img
{
float
:
left
;
margin-right
:
10px
;}
a
.project-update
span
.update-title
,
.application
.news-feed
.project-updates
li
a
span
.update-author
{
display
:
block
;}
a
.project-update
span
.update-title
{
margin-bottom
:
10px
}
a
.project-update
span
.update-author
{
color
:
#999
;
font-weight
:
normal
;
font-style
:
italic
;}
a
.project-update
span
.update-author
strong
{
font-weight
:
bold
;
font-style
:
normal
;}
}
/* eo Dashboard Page */
app/assets/stylesheets/style.scss
deleted
100644 → 0
View file @
20721eff
This diff is collapsed.
Click to expand it.
app/assets/stylesheets/tags.scss
deleted
100644 → 0
View file @
20721eff
.tag
{
@include
round-borders-all
(
4px
);
padding
:
2px
4px
;
border
:none
;
text-shadow
:none
;
&
.inline
{
display
:inline
;
}
&
.high
,
&
.closed
{
background
:
#D12F19
;
color
:white
;
}
&
.today
,
&
.open
{
background
:
#44aa22
;
color
:white
;
}
&
.yours
{
background
:
#4466cc
;
color
:white
;
}
&
.normal
{
background
:
#2c5ca6
;
color
:white
;
}
&
.notes
{
background
:
#2c5c66
;
color
:white
;
}
&
.note
{
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
26
,
color-stop
(
0
.076
,
#fefefe
)
,
to
(
#F6F7F8
));
background-image
:
-webkit-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
background-image
:
-moz-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
background-image
:
-o-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
color
:
#777
;
border
:
1px
solid
#DEDFE1
;
}
&
.issue
{
background
:
#D12F19
;
color
:white
;
}
&
.commit
{
background-image
:
-webkit-gradient
(
linear
,
0
0
,
0
26
,
color-stop
(
0
.076
,
#fefefe
)
,
to
(
#F6F7F8
));
background-image
:
-webkit-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
background-image
:
-moz-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
background-image
:
-o-linear-gradient
(
#fefefe
7
.6%
,
#F6F7F8
);
color
:
#777
;
border
:
1px
solid
#DEDFE1
;
}
}
app/assets/stylesheets/top_panel.scss
View file @
fca1ffb8
...
...
@@ -50,7 +50,7 @@ body header {
border
:
1px
solid
#AAA
;
padding
:
0
10px
0
30px
;
background
:
transparent
url('images.png')
no-repeat
8px
-42px
;
width
:
1
60px
;
width
:
2
60px
;
height
:
26px
;
}
}
...
...
app/controllers/admin/projects_controller.rb
View file @
fca1ffb8
...
...
@@ -52,6 +52,12 @@ class Admin::ProjectsController < ApplicationController
def
update
@admin_project
=
Project
.
find_by_code
(
params
[
:id
])
owner_id
=
params
[
:project
][
:owner_id
]
if
owner_id
@admin_project
.
owner
=
User
.
find
(
owner_id
)
end
if
@admin_project
.
update_attributes
(
params
[
:project
])
redirect_to
[
:admin
,
@admin_project
],
notice:
'Project was successfully updated.'
else
...
...
app/controllers/keys_controller.rb
View file @
fca1ffb8
class
KeysController
<
ApplicationController
layout
"profile"
respond_to
:js
respond_to
:js
,
:html
def
index
@keys
=
current_user
.
keys
.
all
...
...
app/views/admin/projects/_form.html.haml
View file @
fca1ffb8
...
...
@@ -6,28 +6,24 @@
-
@admin_project
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
.
form-row
.
clearfix
=
f
.
label
:name
%br
=
f
.
text_field
:name
.form-row
.input
=
f
.
text_field
:name
.clearfix
=
f
.
label
:code
%br
=
f
.
text_field
:code
.form-row
.input
=
f
.
text_field
:code
.clearfix
=
f
.
label
:path
%br
=
f
.
text_field
:path
.input
=
f
.
text_field
:path
.form-row
=
f
.
label
:tag_list
%br
=
f
.
text_area
:tag_list
,
:placeholder
=>
"project tags"
,
:style
=>
"height:50px"
,
:id
=>
:tag_field
-
unless
@admin_project
.
new_record?
.clearfix
=
f
.
label
:owner_id
.input
=
f
.
select
:owner_id
,
User
.
all
.
map
{
|
user
|
[
user
.
name
,
user
.
id
]
}
.
form-row
.
clearfix
=
f
.
label
:description
%br
=
f
.
text_area
:description
.input
=
f
.
text_area
:description
.clear
%br
.actions
...
...
@@ -36,4 +32,5 @@
:javascript
$
(
function
(){
taggifyForm
();
$
(
'
#project_owner_id
'
).
chosen
();
})
app/views/admin/users/_form.html.haml
View file @
fca1ffb8
...
...
@@ -2,48 +2,41 @@
=
form_for
[
:admin
,
@admin_user
]
do
|
f
|
-
if
@admin_user
.
errors
.
any?
#error_explanation
%h2
=
"
#{
pluralize
(
@admin_user
.
errors
.
count
,
"error"
)
}
prohibited this admin_user from being saved:"
%ul
-
@admin_user
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
.
form-row
.
clearfix
=
f
.
label
:name
%br
=
f
.
text_field
:name
.form-row
.input
=
f
.
text_field
:name
.clearfix
=
f
.
label
:email
%br
=
f
.
text_field
:email
.form-row
.input
=
f
.
text_field
:email
.clearfix
=
f
.
label
:password
%br
=
f
.
password_field
:password
.form-row
.input
=
f
.
password_field
:password
.clearfix
=
f
.
label
:password_confirmation
%br
=
f
.
password_field
:password_confirmation
.form-row
.input
=
f
.
password_field
:password_confirmation
.clearfix
=
f
.
check_box
:admin
=
f
.
label
:admin
.form-row
=
f
.
text_field
:projects_limit
,
:class
=>
"small_input"
.clearfix
=
f
.
label
:projects_limit
.input
=
f
.
text_field
:projects_limit
,
:class
=>
"small_input"
.
form-row
.
clearfix
=
f
.
label
:skype
%br
=
f
.
text_field
:skype
.form-row
.input
=
f
.
text_field
:skype
.clearfix
=
f
.
label
:linkedin
%br
=
f
.
text_field
:linkedin
.form-row
.input
=
f
.
text_field
:linkedin
.clearfix
=
f
.
label
:twitter
%br
=
f
.
text_field
:twitter
.input
=
f
.
text_field
:twitter
.clear
%br
.actions
=
f
.
submit
'Save'
,
:class
=>
"btn"
=
f
.
submit
'Save'
,
:class
=>
"btn primary"
=
link_to
'Cancel'
,
admin_users_path
,
:class
=>
"btn"
app/views/admin/users/new.html.haml
View file @
fca1ffb8
%h
1
New user
%h
2
New user
%hr
=
render
'form'
%br
=
link_to
'Back'
,
admin_users_path
,
:class
=>
""
app/views/commits/index.html.haml
View file @
fca1ffb8
...
...
@@ -29,5 +29,9 @@
:javascript
$
(
function
(){
CommitsList
.
init
(
"
#{
@ref
}
"
,
20
);
$
(
'
.project-refs-select
'
).
chosen
();
});
:javascript
$
(
function
(){
$
(
'
.project-refs-select
'
).
chosen
();
});
app/views/dashboard/_merge_requests_feed.html.haml
View file @
fca1ffb8
...
...
@@ -5,6 +5,6 @@
%strong
=
merge_request
.
project
.
name
–
Issue
#
Merge Request
#
=
merge_request
.
id
=
truncate
merge_request
.
title
,
:length
=>
50
app/views/issues/_show.html.haml
View file @
fca1ffb8
%li
.wll
{
:id
=>
dom_id
(
issue
),
:class
=>
"issue #{issue.critical ? "
critical
" : ""}"
,
:url
=>
project_issue_path
(
issue
.
project
,
issue
)
}
=
image_tag
gravatar_icon
(
issue
.
a
uthor
_email
),
:class
=>
"avatar"
=
image_tag
gravatar_icon
(
issue
.
a
ssignee
_email
),
:class
=>
"avatar"
%span
.update-author
assigned to
%strong
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
issue
.
author_id
)),
:class
=>
"author_link"
do
=
issue
.
author_name
authored
=
time_ago_in_words
(
issue
.
created_at
)
ago
=
issue
.
assignee_name
-
if
issue
.
critical
%span
.label.important
critical
-
if
issue
.
today?
...
...
app/views/issues/index.html.haml
View file @
fca1ffb8
-
if
current_user
.
private_token
=
content_for
:rss_icon
do
.rss-icon
=
link_to
project_issues_path
(
@project
,
:atom
,
{
:private_token
=>
current_user
.
private_token
})
do
=
image_tag
"Rss-UI.PNG"
,
:width
=>
22
,
:title
=>
"feed"
.issues_content
%h3
Issues
%span
.rss-icon
=
link_to
project_issues_path
(
@project
,
:atom
,
{
:private_token
=>
current_user
.
private_token
})
do
=
image_tag
"Rss-UI.PNG"
,
:width
=>
22
,
:title
=>
"feed"
-
if
can?
current_user
,
:write_issue
,
@project
=
link_to
new_project_issue_path
(
@project
),
:class
=>
"right btn small"
,
:title
=>
"New Issue"
,
:remote
=>
true
do
New Issue
...
...
app/views/issues/index.js.haml
View file @
fca1ffb8
:plain
$('#issues-table
tbody
').html("
#{
escape_javascript
(
render
(
'issues'
))
}
");
$('#issues-table').html("
#{
escape_javascript
(
render
(
'issues'
))
}
");
setSortable();
app/views/issues/show.html.haml
View file @
fca1ffb8
%h3
Issue ##{@issue.id}
%small
created at
=
@issue
.
created_at
.
stamp
(
"Aug 21, 2011"
)
%span
.right
-
if
can?
(
current_user
,
:admin_project
,
@project
)
||
@issue
.
author
==
current_user
...
...
@@ -20,21 +23,18 @@
%div
.well
%div
%span
.entity-info
=
image_tag
gravatar_icon
(
@issue
.
author_email
),
:class
=>
"left"
,
:width
=>
40
,
:style
=>
"padding-right:5px;"
%span
.commit-title
%strong
%span
.commit-author
%strong
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@issue
.
author
.
id
))
do
%span
.author
=
@issue
.
author_name
→
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@issue
.
assignee
.
id
))
do
%span
.author
=
@issue
.
assignee_name
%br
.cgray
=
@issue
.
created_at
.
stamp
(
"Aug 21, 2011 9:23pm"
)
%cite
.cgray
Created by
=
image_tag
gravatar_icon
(
@issue
.
author_email
),
:width
=>
16
,
:class
=>
"lil_av"
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@issue
.
author
.
id
))
do
%strong
.author
=
@issue
.
author_name
%cite
.cgray
and currently assigned to
=
image_tag
gravatar_icon
(
@issue
.
assignee_email
),
:width
=>
16
,
:class
=>
"lil_av"
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@issue
.
assignee
.
id
))
do
%strong
.author
=
@issue
.
assignee_name
%hr
%div
=
simple_format
@issue
.
title
...
...
app/views/keys/_form.html.haml
View file @
fca1ffb8
%div
=
form_for
@key
,
:remote
=>
true
do
|
f
|
=
form_for
@key
do
|
f
|
-
if
@key
.
errors
.
any?
%ul
-
@key
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
.alert-message.block-message.error
%ul
-
@key
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
.
form-row
.
clearfix
=
f
.
label
:title
=
f
.
text_field
:title
,
:style
=>
"width:300px"
.
form-row
.input
=
f
.
text_field
:title
.
clearfix
=
f
.
label
:key
=
f
.
text_area
:key
,
:style
=>
"width:300px; height:130px"
.form-row
=
f
.
submit
'Save'
,
:class
=>
"grey-button"
.input
=
f
.
text_area
:key
,
:class
=>
"xlarge"
.actions
=
f
.
submit
'Save'
,
:class
=>
"primary btn"
=
link_to
"Cancel"
,
keys_path
,
:class
=>
"btn"
app/views/keys/_show.html.haml
View file @
fca1ffb8
%
a
.update-item
{
:href
=>
key_path
(
key
)}
%span
.update-title
=
key
.
title
%span
.update-author
Added
=
time_ago_in_words
(
key
.
created_at
)
ago
%
li
.entry
=
link_to
key_path
(
key
)
do
%strong
=
key
.
title
%span
.right.cgray
Added
=
time_ago_in_words
(
key
.
created_at
)
ago
app/views/keys/index.html.haml
View file @
fca1ffb8
%h2
.icon
%span
>
%h3
SSH Keys
%div
#new-key-holder
.right
=
link_to
"Add new"
,
new_key_path
,
:remote
=>
true
,
:class
=>
"grey-button"
%
b
r
=
link_to
"Add new"
,
new_key_path
,
:class
=>
"btn small right"
%
h
r
%div
#keys-table
{
:class
=>
"update-data ui-box ui-box-small ui-box-big"
}
.data
%ul
.unstyled
-
@keys
.
each
do
|
key
|
=
render
(
:partial
=>
'show'
,
:locals
=>
{
:key
=>
key
})
:javascript
$
(
'
.delete-key
'
).
live
(
'
ajax:success
'
,
function
()
{
$
(
this
).
closest
(
'
.update-item
'
).
fadeOut
();
});
app/views/keys/new.html.haml
View file @
fca1ffb8
%h
1
New key
%h
3
New key
%hr
=
render
'form'
=
link_to
'Back'
,
keys_path
app/views/keys/show.html.haml
View file @
fca1ffb8
.ui-box.width-100p
%h3
=
@key
.
title
.data
%pre
=
@key
.
key
.clear
.buttons
=
link_to
'Remove'
,
@key
,
:confirm
=>
'Are you sure?'
,
:method
=>
:delete
,
:class
=>
"red-button delete-key right"
.clear
%h3
=
@key
.
title
%hr
%pre
=
@key
.
key
.actions
=
link_to
'Remove'
,
@key
,
:confirm
=>
'Are you sure?'
,
:method
=>
:delete
,
:class
=>
"btn danger delete-key"
app/views/layouts/_head_panel.html.haml
View file @
fca1ffb8
...
...
@@ -11,10 +11,6 @@
=
truncate
@project
.
name
,
:length
=>
28
.git_url_wrapper
%input
.git-url.text
{
:id
=>
""
,
:name
=>
""
,
:readonly
=>
""
,
:type
=>
"text"
,
:value
=>
@project
.
url_to_repo
,
:class
=>
"one_click_select"
}
-#- if @project.repo_exists?
.left{:style => "margin-left:5px;"}
= render :partial => "projects/refs", :locals => { :destination => controller.controller_name == "commits" ? "commits" : "tree" }
=
yield
:rss_icon
.account-box
...
...
app/views/layouts/_project_side.html.haml
View file @
fca1ffb8
...
...
@@ -6,14 +6,14 @@
-
if
@project
.
repo_exists?
=
link_to
"Repository"
,
project_repository_path
(
@project
),
:class
=>
repository_tab_class
=
link_to
"
Tre
e"
,
tree_project_ref_path
(
@project
,
@project
.
root_ref
),
:class
=>
tree_tab_class
=
link_to
"
Cod
e"
,
tree_project_ref_path
(
@project
,
@project
.
root_ref
),
:class
=>
tree_tab_class
=
link_to
"Commits"
,
project_commits_path
(
@project
),
:class
=>
(
controller
.
controller_name
==
"commits"
)
?
"current"
:
nil
=
link_to
"Network"
,
graph_project_path
(
@project
),
:class
=>
current_page?
(
:controller
=>
"projects"
,
:action
=>
"graph"
,
:id
=>
@project
)
?
"current"
:
nil
=
link_to
project_issues_filter_path
(
@project
),
:class
=>
(
controller
.
controller_name
==
"issues"
)
?
"current"
:
nil
do
Issues
=
link_to
project_merge_requests_path
(
@project
),
:class
=>
(
controller
.
controller_name
==
"merge_requests"
)
?
"current"
:
nil
do
Merge Requests
=
link_to
wall_project_path
(
@project
),
:class
=>
current_page?
(
:controller
=>
"projects"
,
:action
=>
"wall"
,
:id
=>
@project
)
?
"current"
:
nil
do
Wall
@
Wall
-
if
@project
.
common_notes
.
today
.
count
>
0
%span
.label
=
@project
.
common_notes
.
today
.
count
=
link_to
project_merge_requests_path
(
@project
),
:class
=>
(
controller
.
controller_name
==
"merge_requests"
)
?
"current"
:
nil
do
Requests
app/views/layouts/profile.html.haml
View file @
fca1ffb8
...
...
@@ -13,13 +13,15 @@
=
render
:partial
=>
"layouts/head_panel"
.container-fluid
.sidebar
.fixed
%aside
=
link_to
"Profile"
,
profile_path
,
:class
=>
current_page?
(
:controller
=>
"profile"
,
:action
=>
:show
)
?
"current"
:
nil
=
link_to
"Password & token"
,
profile_password_path
,
:class
=>
current_page?
(
:controller
=>
"profile"
,
:action
=>
:password
)
?
"current"
:
nil
=
link_to
"Design"
,
profile_design_path
,
:class
=>
current_page?
(
:controller
=>
"profile"
,
:action
=>
:design
)
?
"current"
:
nil
=
link_to
keys_path
,
:class
=>
controller
.
controller_name
==
"keys"
?
"current"
:
nil
do
Keys
-
unless
current_user
.
keys
.
empty?
%span
{
:class
=>
"number"
}=
current_user
.
keys
.
count
.content
=
yield
%aside
=
link_to
"Profile"
,
profile_path
,
:class
=>
current_page?
(
:controller
=>
"profile"
,
:action
=>
:show
)
?
"current"
:
nil
=
link_to
"Password & token"
,
profile_password_path
,
:class
=>
current_page?
(
:controller
=>
"profile"
,
:action
=>
:password
)
?
"current"
:
nil
=
link_to
"Design"
,
profile_design_path
,
:class
=>
current_page?
(
:controller
=>
"profile"
,
:action
=>
:design
)
?
"current"
:
nil
=
link_to
keys_path
,
:class
=>
controller
.
controller_name
==
"keys"
?
"current"
:
nil
do
Keys
-
unless
current_user
.
keys
.
empty?
%span
.label
=
current_user
.
keys
.
count
.content
.row
.span10
=
yield
.span4
=
render
"layouts/projects_side"
app/views/merge_requests/show.html.haml
View file @
fca1ffb8
...
...
@@ -5,6 +5,10 @@
→
%span
.label
=
@merge_request
.
target_branch
%small
created at
=
@merge_request
.
created_at
.
stamp
(
"Aug 21, 2011"
)
%span
.right
-
if
can?
(
current_user
,
:admin_project
,
@project
)
||
@merge_request
.
author
==
current_user
-
if
@merge_request
.
closed
...
...
@@ -24,19 +28,17 @@
%div
.well
%div
%span
.entity-info
=
image_tag
gravatar_icon
(
@merge_request
.
author_email
),
:class
=>
"left"
,
:width
=>
40
,
:style
=>
"padding-right:5px;"
%span
.commit-title
%strong
%span
.commit-author
%strong
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@merge_request
.
author
.
id
))
do
%span
.author
=
@merge_request
.
author_name
→
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@merge_request
.
assignee
.
id
))
do
%span
.author
=
@merge_request
.
assignee_name
%br
.cgray
=
@merge_request
.
created_at
.
stamp
(
"Aug 21, 2011 9:23pm"
)
%cite
.cgray
Created by
=
image_tag
gravatar_icon
(
@merge_request
.
author_email
),
:width
=>
16
,
:class
=>
"lil_av"
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@merge_request
.
author
.
id
))
do
%strong
.author
=
@merge_request
.
author_name
%cite
.cgray
and currently assigned to
=
image_tag
gravatar_icon
(
@merge_request
.
assignee_email
),
:width
=>
16
,
:class
=>
"lil_av"
=
link_to
project_team_member_path
(
@project
,
@project
.
team_member_by_id
(
@merge_request
.
assignee
.
id
))
do
%strong
.author
=
@merge_request
.
assignee_name
%hr
%div
=
simple_format
@merge_request
.
title
...
...
@@ -56,7 +58,7 @@
%img
{
:src
=>
"/assets/ajax-loader-facebook.gif"
,
:class
=>
"dashboard-loader"
}
.merge-request-notes
.
issue
_notes
=
render
"notes/notes"
.
merge_request
_notes
=
render
"notes/notes"
.loading
{
:style
=>
"display:none;"
}
%center
=
image_tag
"ajax-loader.gif"
.clear
...
...
app/views/profile/design.html.haml
View file @
fca1ffb8
.ui-box.width-100p
%h3
Design
=
form_for
@user
,
:url
=>
profile_update_path
,
:method
=>
:put
do
|
f
|
.data
.left.dark_scheme_box
%label
{
:for
=>
"user_dark_scheme_false"
}
=
image_tag
"white.png"
,
:width
=>
310
,
:height
=>
212
%center
%h4
=
f
.
radio_button
:dark_scheme
,
false
White code preview
.right.dark_scheme_box
%label
{
:for
=>
"user_dark_scheme_true"
}
=
image_tag
"dark.png"
,
:width
=>
310
,
:height
=>
212
%center
%h4
=
f
.
radio_button
:dark_scheme
,
true
Dark code preview
.clear
.buttons
=
f
.
submit
'Save'
,
:class
=>
"btn"
%h3
Design
%hr
=
form_for
@user
,
:url
=>
profile_update_path
,
:method
=>
:put
do
|
f
|
.row
%label
.span4
{
:for
=>
"user_dark_scheme_false"
}
=
image_tag
"white.png"
,
:width
=>
210
%center
%h4
=
f
.
radio_button
:dark_scheme
,
false
White code preview
%label
.span4
{
:for
=>
"user_dark_scheme_true"
}
=
image_tag
"dark.png"
,
:width
=>
210
%center
%h4
=
f
.
radio_button
:dark_scheme
,
true
Dark code preview
.clearfix
.actions
=
f
.
submit
'Save'
,
:class
=>
"btn"
app/views/profile/password.html.haml
View file @
fca1ffb8
.ui-box.width-100p.append-bottom-20
%h3
Password
=
form_for
@user
,
:url
=>
profile_password_path
,
:method
=>
:put
do
|
f
|
.data
%p
After successfull password update you will be redirected to login page where you should login with new password
-
if
@user
.
errors
.
any?
#error_explanation
%ul
-
@user
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
%h3
Password
%hr
=
form_for
@user
,
:url
=>
profile_password_path
,
:method
=>
:put
do
|
f
|
.data
%p
After successfull password update you will be redirected to login page where you should login with new password
-
if
@user
.
errors
.
any?
#error_explanation
%ul
-
@user
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
.form-row
=
f
.
label
:password
%br
=
f
.
password_field
:password
.form-row
=
f
.
label
:password_confirmation
%br
=
f
.
password_field
:password_confirmation
.buttons
=
f
.
submit
'Save'
,
:class
=>
"btn"
.clear
.ui-box.width-100p
%h3
Private token
%em
.cred.right
keep it in secret!
=
form_for
@user
,
:url
=>
profile_reset_private_token_path
,
:method
=>
:put
do
|
f
|
.data
%p
Private token used to access application resources without authentication.
%p
For example its required to access commits feed.
%hr
%p
.cgray
-
if
current_user
.
private_token
=
text_field_tag
"token"
,
current_user
.
private_token
-
else
You don`t have one yet. Click generate to fix it.
.buttons
.clearfix
=
f
.
label
:password
.input
=
f
.
password_field
:password
.clearfix
=
f
.
label
:password_confirmation
.input
=
f
.
password_field
:password_confirmation
.actions
=
f
.
submit
'Save'
,
:class
=>
"btn"
%h3
Private token
%span
.cred.right
keep it in secret!
%hr
=
form_for
@user
,
:url
=>
profile_reset_private_token_path
,
:method
=>
:put
do
|
f
|
.data
%p
Private token used to access application resources without authentication.
%p
For example its required to access commits feed.
%hr
%p
.cgray
-
if
current_user
.
private_token
=
f
.
submit
'Reset'
,
:confirm
=>
"Are you sure?"
,
:class
=>
"grey-button"
=
text_field_tag
"token"
,
current_user
.
private_token
-
else
=
f
.
submit
'Generate'
,
:class
=>
"btn"
You don`t have one yet. Click generate to fix it.
.actions
-
if
current_user
.
private_token
=
f
.
submit
'Reset'
,
:confirm
=>
"Are you sure?"
,
:class
=>
"btn"
-
else
=
f
.
submit
'Generate'
,
:class
=>
"btn"
app/views/profile/show.html.haml
View file @
fca1ffb8
%h3
=
@user
.
name
.media-grid
=
link_to
"#"
do
=
image_tag
gravatar_icon
(
@user
.
email
,
90
),
:class
=>
"thumbnail"
%h3
.media_h
=
@user
.
name
%hr
=
form_for
@user
,
:url
=>
profile_update_path
,
:method
=>
:put
do
|
f
|
-
if
@user
.
errors
.
any?
...
...
spec/requests/dashboard_merge_requests_spec.rb
View file @
fca1ffb8
...
...
@@ -34,14 +34,7 @@ describe "User MergeRequests" do
it
{
should
have_content
(
@merge_request1
.
title
[
0
..
10
])
}
it
{
should
have_content
(
@merge_request1
.
project
.
name
)
}
it
{
should
have_content
(
@merge_request1
.
target_branch
)
}
it
{
should
have_content
(
@merge_request1
.
source_branch
)
}
it
{
should
have_content
(
@merge_request1
.
assignee
.
name
)
}
it
{
should
have_content
(
@merge_request2
.
title
[
0
..
10
])
}
it
{
should
have_content
(
@merge_request2
.
project
.
name
)
}
it
{
should
have_content
(
@merge_request2
.
target_branch
)
}
it
{
should
have_content
(
@merge_request2
.
source_branch
)
}
it
{
should
have_content
(
@merge_request2
.
assignee
.
name
)
}
end
end
spec/requests/issues_spec.rb
View file @
fca1ffb8
...
...
@@ -51,17 +51,17 @@ describe "Issues" do
# admin access to remove issue
@user
.
users_projects
.
destroy_all
project
.
add_access
(
@user
,
:read
,
:write
,
:admin
)
visit
project_issues_path
(
project
)
visit
edit_project_issue_path
(
project
,
@issue
)
end
it
"should remove entry"
do
expect
{
click_link
"
destroy_issue_
#{
@issue
.
id
}
"
click_link
"
Remove
"
}.
to
change
{
Issue
.
count
}.
by
(
-
1
)
end
end
describe
"statuses"
,
:js
=>
true
do
describe
"statuses"
do
before
do
@closed_issue
=
Factory
:issue
,
:author
=>
@user
,
...
...
@@ -76,13 +76,13 @@ describe "Issues" do
end
it
"should show only closed"
do
c
hoose
"closed_issues
"
c
lick_link
"Closed
"
should
have_no_content
(
@issue
.
title
)
should
have_content
(
@closed_issue
.
title
[
0
..
25
])
end
it
"should show all"
do
c
hoose
"all_issues
"
c
lick_link
"All
"
should
have_content
(
@issue
.
title
[
0
..
25
])
should
have_content
(
@closed_issue
.
title
[
0
..
25
])
end
...
...
@@ -182,7 +182,6 @@ describe "Issues" do
:assignee
=>
@user
,
:project
=>
project
visit
project_issues_path
(
project
)
page
.
execute_script
(
"$('.action-links').css('display', 'block');"
)
click_link
"Edit"
end
...
...
@@ -200,7 +199,6 @@ describe "Issues" do
it
"should update issue fields"
do
click_button
"Save"
page
.
should_not
have_content
(
"Issue #
#{
@issue
.
id
}
"
)
page
.
should
have_content
@user
.
name
page
.
should
have_content
"bug 345"
page
.
should
have_content
project
.
name
...
...
@@ -226,7 +224,7 @@ describe "Issues" do
@issue
.
save
visit
project_issues_path
(
project
)
c
hoose
'closed_issues
'
c
lick_link
'Closed
'
fill_in
'issue_search'
,
:with
=>
'foobar'
page
.
should
have_content
'foobar'
...
...
spec/requests/projects_spec.rb
View file @
fca1ffb8
...
...
@@ -5,7 +5,7 @@ describe "Projects" do
describe
"GET /projects"
do
before
do
@project
=
Factory
:project
@project
=
Factory
:project
,
:owner
=>
@user
@project
.
add_access
(
@user
,
:read
)
visit
projects_path
end
...
...
@@ -15,7 +15,7 @@ describe "Projects" do
end
it
"should have link to new project"
do
page
.
should
have_content
(
"
Create new p
roject"
)
page
.
should
have_content
(
"
New P
roject"
)
end
it
"should have project"
do
...
...
@@ -26,7 +26,7 @@ describe "Projects" do
describe
"GET /projects/new"
do
before
do
visit
projects_path
click_link
"
Create new p
roject"
click_link
"
New P
roject"
end
it
"should be correct path"
do
...
...
@@ -68,7 +68,7 @@ describe "Projects" do
describe
"GET /projects/show"
do
before
do
@project
=
Factory
:project
@project
=
Factory
:project
,
:owner
=>
@user
@project
.
add_access
(
@user
,
:read
)
visit
project_path
(
@project
)
...
...
@@ -128,7 +128,7 @@ describe "Projects" do
describe
"PUT /projects/:id"
do
before
do
@project
=
Factory
:project
@project
=
Factory
:project
,
:owner
=>
@user
@project
.
add_access
(
@user
,
:admin
,
:read
)
visit
edit_project_path
(
@project
)
...
...
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