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
Tatuya Kamada
gitlab-ce
Commits
f1795a49
Commit
f1795a49
authored
Apr 17, 2012
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issues form improved, Show milestone for Issue show
parent
c9def945
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
76 additions
and
34 deletions
+76
-34
app/assets/stylesheets/main.scss
app/assets/stylesheets/main.scss
+5
-0
app/assets/stylesheets/sections/issues.scss
app/assets/stylesheets/sections/issues.scss
+27
-0
app/views/issues/_form.html.haml
app/views/issues/_form.html.haml
+33
-30
app/views/issues/show.html.haml
app/views/issues/show.html.haml
+11
-4
No files found.
app/assets/stylesheets/main.scss
View file @
f1795a49
...
@@ -98,6 +98,11 @@ $hover: #FDF5D9;
...
@@ -98,6 +98,11 @@ $hover: #FDF5D9;
*/
*/
@import
"sections/commits.scss"
;
@import
"sections/commits.scss"
;
/**
* Styles related to displaying issues
*/
@import
"sections/issues.scss"
;
/**
/**
* This scss file redefine chozen selectbox styles for
* This scss file redefine chozen selectbox styles for
* project Branch/Tag select element
* project Branch/Tag select element
...
...
app/assets/stylesheets/sections/issues.scss
0 → 100644
View file @
f1795a49
.issue_form_box
{
@extend
.main_box
;
.issue_title
{
@extend
.top_box_content
;
.clearfix
{
margin-bottom
:
0px
;
input
{
@extend
.span8
;
}
}
}
.issue_middle_block
{
@extend
.middle_box_content
;
height
:
30px
;
.issue_assignee
{
@extend
.span6
;
float
:left
;
}
.issue_milestone
{
@extend
.span4
;
float
:left
;
}
}
.issue_description
{
@extend
.bottom_box_content
;
}
}
app/views/issues/_form.html.haml
View file @
f1795a49
%div
.issue-form-holder
%div
.issue-form-holder
=
form_for
[
@project
,
@issue
],
:remote
=>
request
.
xhr?
do
|
f
|
%h3
=
@issue
.
new_record?
?
"New Issue"
:
"Edit Issue #
#{
@issue
.
id
}
"
%h3
=
@issue
.
new_record?
?
"New Issue"
:
"Edit Issue #
#{
@issue
.
id
}
"
%hr
-
unless
request
.
xhr?
.back_link
=
link_to
project_issue_path
(
@project
,
@issue
)
do
←
back to show page
=
form_for
[
@project
,
@issue
],
:remote
=>
request
.
xhr?
do
|
f
|
-
if
@issue
.
errors
.
any?
-
if
@issue
.
errors
.
any?
.alert-message.block-message.error
.alert-message.block-message.error
%ul
%ul
-
@issue
.
errors
.
full_messages
.
each
do
|
msg
|
-
@issue
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
%li
=
msg
.issue_form_box
.issue_title
.clearfix
.clearfix
=
f
.
label
:title
,
"Issue Subject *"
=
f
.
label
:title
,
"Issue Subject *"
.input
.input
=
f
.
text_field
:title
,
:maxlength
=>
255
,
:class
=>
"xxlarge"
=
f
.
text_field
:title
,
:maxlength
=>
255
,
:class
=>
"xxlarge"
.issue_middle_block
.clearfix
.issue_assignee
=
f
.
label
:assignee_id
,
"Assign to *"
=
f
.
label
:assignee_id
,
"Assign to *"
.input
=
f
.
select
(
:assignee_id
,
@project
.
users
.
all
.
collect
{
|
p
|
[
p
.
name
,
p
.
id
]
},
{
:include_blank
=>
"Assign to user"
})
.input
=
f
.
select
(
:assignee_id
,
@project
.
users
.
all
.
collect
{
|
p
|
[
p
.
name
,
p
.
id
]
},
{
:include_blank
=>
"Assign to user"
})
.issue_milestone
.clearfix
=
f
.
label
:description
,
"Issue Details"
.input
=
f
.
text_area
:description
,
:maxlength
=>
2000
,
:class
=>
"xxlarge"
,
:rows
=>
10
%p
.hint
Markdown is enabled.
.clearfix
=
f
.
label
:milestone_id
=
f
.
label
:milestone_id
.input
=
f
.
select
(
:milestone_id
,
@project
.
milestones
.
active
.
all
.
collect
{
|
p
|
[
p
.
title
,
p
.
id
]
},
{
:include_blank
=>
"Select milestone"
})
.input
=
f
.
select
(
:milestone_id
,
@project
.
milestones
.
active
.
all
.
collect
{
|
p
|
[
p
.
title
,
p
.
id
]
},
{
:include_blank
=>
"Select milestone"
})
.issue_description
.clearfix
.clearfix
=
f
.
label
:critical
,
"Critical"
=
f
.
label
:critical
,
"Critical"
.input
=
f
.
check_box
:critical
.input
=
f
.
check_box
:critical
...
@@ -37,6 +33,13 @@
...
@@ -37,6 +33,13 @@
.clearfix
.clearfix
=
f
.
label
:closed
=
f
.
label
:closed
.input
=
f
.
check_box
:closed
.input
=
f
.
check_box
:closed
.clearfix
=
f
.
label
:description
,
"Issue Details"
.input
=
f
.
text_area
:description
,
:maxlength
=>
2000
,
:class
=>
"xxlarge"
,
:rows
=>
14
%p
.hint
Markdown is enabled.
.actions
.actions
-
if
@issue
.
new_record?
-
if
@issue
.
new_record?
...
...
app/views/issues/show.html.haml
View file @
f1795a49
...
@@ -7,11 +7,11 @@
...
@@ -7,11 +7,11 @@
%span
.right
%span
.right
-
if
can?
(
current_user
,
:admin_project
,
@project
)
||
@issue
.
author
==
current_user
-
if
can?
(
current_user
,
:admin_project
,
@project
)
||
@issue
.
author
==
current_user
-
if
@issue
.
closed
-
if
@issue
.
closed
=
link_to
'Reopen'
,
project_issue_path
(
@project
,
@issue
,
:issue
=>
{
:closed
=>
false
},
:status_only
=>
true
),
:method
=>
:put
,
:class
=>
"btn"
=
link_to
'Reopen'
,
project_issue_path
(
@project
,
@issue
,
:issue
=>
{
:closed
=>
false
},
:status_only
=>
true
),
:method
=>
:put
,
:class
=>
"btn
small
"
-
else
-
else
=
link_to
'Close'
,
project_issue_path
(
@project
,
@issue
,
:issue
=>
{
:closed
=>
true
},
:status_only
=>
true
),
:method
=>
:put
,
:class
=>
"btn"
,
:title
=>
"Close Issue"
=
link_to
'Close'
,
project_issue_path
(
@project
,
@issue
,
:issue
=>
{
:closed
=>
true
},
:status_only
=>
true
),
:method
=>
:put
,
:class
=>
"btn
small
"
,
:title
=>
"Close Issue"
-
if
can?
(
current_user
,
:admin_project
,
@project
)
||
@issue
.
author
==
current_user
-
if
can?
(
current_user
,
:admin_project
,
@project
)
||
@issue
.
author
==
current_user
=
link_to
edit_project_issue_path
(
@project
,
@issue
),
:class
=>
"btn"
do
=
link_to
edit_project_issue_path
(
@project
,
@issue
),
:class
=>
"btn
small
"
do
Edit
Edit
%br
%br
...
@@ -40,6 +40,13 @@
...
@@ -40,6 +40,13 @@
=
image_tag
gravatar_icon
(
@issue
.
assignee_email
),
:width
=>
16
,
:class
=>
"lil_av"
=
image_tag
gravatar_icon
(
@issue
.
assignee_email
),
:width
=>
16
,
:class
=>
"lil_av"
%strong
.author
=
link_to_issue_assignee
(
@issue
)
%strong
.author
=
link_to_issue_assignee
(
@issue
)
-
if
@issue
.
milestone
-
milestone
=
@issue
.
milestone
%cite
.cgray
and attached to milestone
=
link_to
project_milestone_path
(
milestone
.
project
,
milestone
)
do
%strong
=
truncate
(
milestone
.
title
,
:length
=>
20
)
-
if
@issue
.
description
.
present?
-
if
@issue
.
description
.
present?
.bottom_box_content
.bottom_box_content
=
preserve
do
=
preserve
do
...
...
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