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
e0ca2ada
Commit
e0ca2ada
authored
Sep 09, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve Merge Request form
* added description * simplified form * enabled gfm autocomplete
parent
76a07394
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
36 additions
and
31 deletions
+36
-31
app/assets/javascripts/dispatcher.js.coffee
app/assets/javascripts/dispatcher.js.coffee
+2
-0
app/assets/stylesheets/sections/merge_requests.scss
app/assets/stylesheets/sections/merge_requests.scss
+1
-1
app/views/projects/merge_requests/_form.html.haml
app/views/projects/merge_requests/_form.html.haml
+27
-30
app/views/projects/merge_requests/show/_mr_box.html.haml
app/views/projects/merge_requests/show/_mr_box.html.haml
+6
-0
No files found.
app/assets/javascripts/dispatcher.js.coffee
View file @
e0ca2ada
...
@@ -18,6 +18,8 @@ class Dispatcher
...
@@ -18,6 +18,8 @@ class Dispatcher
switch
page
switch
page
when
'projects:issues:index'
when
'projects:issues:index'
Issues
.
init
()
Issues
.
init
()
when
'projects:issues:new'
,
'projects:merge_requests:new'
GitLab
.
GfmAutoComplete
.
setup
()
when
'dashboard:show'
when
'dashboard:show'
new
Dashboard
()
new
Dashboard
()
new
Activities
()
new
Activities
()
...
...
app/assets/stylesheets/sections/merge_requests.scss
View file @
e0ca2ada
...
@@ -117,7 +117,7 @@
...
@@ -117,7 +117,7 @@
.merge-request-angle
{
.merge-request-angle
{
text-align
:
center
;
text-align
:
center
;
margin
-top
:
45px
;
margin
:
0
;
}
}
.merge-request-form-info
{
.merge-request-form-info
{
...
...
app/views/projects/merge_requests/_form.html.haml
View file @
e0ca2ada
...
@@ -5,41 +5,32 @@
...
@@ -5,41 +5,32 @@
-
@merge_request
.
errors
.
full_messages
.
each
do
|
msg
|
-
@merge_request
.
errors
.
full_messages
.
each
do
|
msg
|
%li
=
msg
%li
=
msg
%h3
.page-title
Branches
.merge-request-branches
.merge-request-branches
.row
.row
.span5
.span5
.ui-box
.clearfix
.title
From
.pull-left
.ui-box-head
=
f
.
select
(
:source_project_id
,[[
@merge_request
.
source_project
.
path_with_namespace
,
@merge_request
.
source_project
.
id
]]
,
{},
{
class:
'source_project chosen span3'
})
Project:
.pull-left
=
f
.
select
(
:source_project_id
,[[
@merge_request
.
source_project
.
path_with_namespace
,
@merge_request
.
source_project
.
id
]]
,
{},
{
class:
'source_project chosen span4'
})
.prepend-top-10
%i
.icon-code-fork
%i
.icon-code-fork
Branch:
=
f
.
select
(
:source_branch
,
@merge_request
.
source_project
.
repository
.
branch_names
,
{
include_blank:
"Select branch"
},
{
class:
'source_branch chosen span2'
})
=
f
.
select
(
:source_branch
,
@merge_request
.
source_project
.
repository
.
branch_names
,
{
include_blank:
"Select branch"
},
{
class:
'source_branch chosen span3'
})
.mr_source_commit.prepend-top-10
.mr_source_commit.prepend-top-10
.span2
.span2
%h2
.merge-request-angle.light
%h1
.merge-request-angle
%i
.icon-long-arrow-right
%i
.icon-angle-right
.span5
.span5
.clearfix
.ui-box
.pull-left
.title
To
-
projects
=
@project
.
forked_from_project
.
nil?
?
[
@project
]
:
[
@project
,
@project
.
forked_from_project
]
.ui-box-head
=
f
.
select
(
:target_project_id
,
projects
.
map
{
|
proj
|
[
proj
.
path_with_namespace
,
proj
.
id
]
},
{
include_blank:
"Select Target Project"
},
{
class:
'target_project chosen span3'
})
-
projects
=
@project
.
forked_from_project
.
nil?
?
[
@project
]
:
[
@project
,
@project
.
forked_from_project
]
.pull-left
Project:
=
f
.
select
(
:target_project_id
,
projects
.
map
{
|
proj
|
[
proj
.
path_with_namespace
,
proj
.
id
]
},
{
include_blank:
"Select Target Project"
},
{
class:
'target_project chosen span4'
})
.prepend-top-10
%i
.icon-code-fork
%i
.icon-code-fork
Branch:
=
f
.
select
(
:target_branch
,
@target_branches
,
{
include_blank:
"Select branch"
},
{
class:
'target_branch chosen span2'
})
=
f
.
select
(
:target_branch
,
@target_branches
,
{
include_blank:
"Select branch"
},
{
class:
'target_branch chosen span3'
})
.mr_target_commit.prepend-top-10
.mr_target_commit.prepend-top-10
%hr
%hr
%h3
.page-title
Details
.merge-request-form-info
.merge-request-form-info
.control-group
.control-group
=
f
.
label
:title
do
=
f
.
label
:title
do
...
@@ -56,6 +47,12 @@
...
@@ -56,6 +47,12 @@
%i
.icon-time
%i
.icon-time
Milestone
Milestone
.controls
=
f
.
select
(
:milestone_id
,
@project
.
milestones
.
active
.
all
.
map
{
|
p
|
[
p
.
title
,
p
.
id
]
},
{
include_blank:
"Select milestone"
},
{
class:
'chosen'
})
.controls
=
f
.
select
(
:milestone_id
,
@project
.
milestones
.
active
.
all
.
map
{
|
p
|
[
p
.
title
,
p
.
id
]
},
{
include_blank:
"Select milestone"
},
{
class:
'chosen'
})
.control-group
=
f
.
label
:description
,
"Description"
.controls
=
f
.
text_area
:description
,
class:
"input-xxlarge js-gfm-input"
,
rows:
14
%p
.hint
Description is parsed with
#{
link_to
"GitLab Flavored Markdown"
,
help_markdown_path
,
target:
'_blank'
}
.
.form-actions
.form-actions
-
if
@merge_request
.
new_record?
-
if
@merge_request
.
new_record?
...
...
app/views/projects/merge_requests/show/_mr_box.html.haml
View file @
e0ca2ada
...
@@ -21,6 +21,12 @@
...
@@ -21,6 +21,12 @@
%strong
=
link_to_gfm
truncate
(
milestone
.
title
,
length:
20
),
project_milestone_path
(
milestone
.
project
,
milestone
)
%strong
=
link_to_gfm
truncate
(
milestone
.
title
,
length:
20
),
project_milestone_path
(
milestone
.
project
,
milestone
)
-
if
@merge_request
.
description
.
present?
.ui-box-bottom
.wiki
=
preserve
do
=
markdown
@merge_request
.
description
-
if
@merge_request
.
closed?
-
if
@merge_request
.
closed?
.ui-box-bottom.alert-error
.ui-box-bottom.alert-error
%span
%span
...
...
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