summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2014-02-18 21:18:46 +0200
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2014-02-18 21:18:46 +0200
commit7e42084fb800546070d3c5d0d704320d1785fdda (patch)
tree8cc948f7a2bf312d22cc76e27f921686d78a20c8
parenta718a9af3e9a4f7431cab066fc81f3311f9fe639 (diff)
downloadgitlab-ce-7e42084fb800546070d3c5d0d704320d1785fdda.tar.gz
Move author/date info for Issue#show, MR#show pages to issue-box
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
-rw-r--r--app/assets/stylesheets/generic/issue_box.scss7
-rw-r--r--app/views/projects/issues/_issue_context.html.haml19
-rw-r--r--app/views/projects/issues/show.html.haml6
-rw-r--r--app/views/projects/merge_requests/show/_context.html.haml19
-rw-r--r--app/views/projects/merge_requests/show/_mr_box.html.haml3
-rw-r--r--app/views/projects/merge_requests/show/_mr_title.html.haml2
6 files changed, 31 insertions, 25 deletions
diff --git a/app/assets/stylesheets/generic/issue_box.scss b/app/assets/stylesheets/generic/issue_box.scss
index 033b4b20f5b..a6573fa0e5f 100644
--- a/app/assets/stylesheets/generic/issue_box.scss
+++ b/app/assets/stylesheets/generic/issue_box.scss
@@ -17,6 +17,13 @@
margin-bottom: 0;
}
+ .creator {
+ padding: 8px 25px;
+ background: #eee;
+ border-bottom: 1px solid #DDD;
+ color: #777;
+ }
+
.title {
font-size: 22px;
font-weight: 500;
diff --git a/app/views/projects/issues/_issue_context.html.haml b/app/views/projects/issues/_issue_context.html.haml
index e5418c25b23..aae101cf40f 100644
--- a/app/views/projects/issues/_issue_context.html.haml
+++ b/app/views/projects/issues/_issue_context.html.haml
@@ -1,23 +1,22 @@
= form_for [@project, @issue], remote: true, html: {class: 'edit-issue inline-update'} do |f|
- Created by #{link_to_member(@project, issue.author)}&nbsp;
- - if issue.assignee
- \ and currently assigned to
+ %strong.append-right-10
+ Assignee:
- if can?(current_user, :modify_issue, @issue)
= project_users_select_tag('issue[assignee_id]', placeholder: 'Select assignee', class: 'custom-form-control', selected: @issue.assignee_id)
- elsif issue.assignee
= link_to_member(@project, @issue.assignee)
+ - else
+ None
-
- .pull-right.hidden-sm.hidden-xs
- - if issue.milestone
- - milestone = issue.milestone
- %cite.cgray Attached to milestone
-
+ .pull-right
+ %strong.append-right-10
+ Milestone:
- if can?(current_user, :modify_issue, @issue)
= f.select(:milestone_id, milestone_options(@issue), { include_blank: "Select milestone (none):" }, {class: 'select2 select2-compact'})
-
= hidden_field_tag :issue_context
= f.submit class: 'btn'
- elsif issue.milestone
= link_to issue.milestone.title, project_milestone_path
+ - else
+ None
diff --git a/app/views/projects/issues/show.html.haml b/app/views/projects/issues/show.html.haml
index c1bd1147912..101f1ddbd1b 100644
--- a/app/views/projects/issues/show.html.haml
+++ b/app/views/projects/issues/show.html.haml
@@ -1,9 +1,6 @@
%h3.page-title
Issue ##{@issue.iid}
- %small
- created #{time_ago_with_tooltip(@issue.created_at)}
-
- if @issue.closed?
%span.state-label.state-label-red Closed
- else
@@ -38,6 +35,9 @@
= @issue.milestone.title
.issue-box
+ .creator
+ Created by #{link_to_member(@project, @issue.author)} #{time_ago_with_tooltip(@issue.created_at)}
+
%h4.title
= gfm escape_once(@issue.title)
diff --git a/app/views/projects/merge_requests/show/_context.html.haml b/app/views/projects/merge_requests/show/_context.html.haml
index 705eeb9894a..2bd850426a9 100644
--- a/app/views/projects/merge_requests/show/_context.html.haml
+++ b/app/views/projects/merge_requests/show/_context.html.haml
@@ -1,23 +1,22 @@
= form_for [@project, @merge_request], remote: true, html: {class: 'edit-merge_request inline-update'} do |f|
- Created by #{link_to_member(@project, merge_request.author)}&nbsp;
- - if merge_request.assignee
- \ and currently assigned to
+ %strong.append-right-10
+ Assignee:
- if can?(current_user, :modify_merge_request, @merge_request)
= project_users_select_tag('merge_request[assignee_id]', placeholder: 'Select assignee', class: 'custom-form-control', selected: @merge_request.assignee_id)
- elsif merge_request.assignee
= link_to_member(@project, @merge_request.assignee)
+ - else
+ None
-
- .pull-right.hidden-sm.hidden-xs
- - if merge_request.milestone
- - milestone = merge_request.milestone
- %cite.cgray Attached to milestone
-
+ .pull-right
+ %strong.append-right-10
+ Milestone:
- if can?(current_user, :modify_merge_request, @merge_request)
= f.select(:milestone_id, milestone_options(@merge_request), { include_blank: "Select milestone (none):" }, {class: 'select2 select2-compact'})
-
= hidden_field_tag :merge_request_context
= f.submit class: 'btn'
- elsif merge_request.milestone
= link_to merge_request.milestone.title, project_milestone_path
+ - else
+ None
diff --git a/app/views/projects/merge_requests/show/_mr_box.html.haml b/app/views/projects/merge_requests/show/_mr_box.html.haml
index 7c3f9b93444..15c3d311bdc 100644
--- a/app/views/projects/merge_requests/show/_mr_box.html.haml
+++ b/app/views/projects/merge_requests/show/_mr_box.html.haml
@@ -1,4 +1,7 @@
.issue-box
+ .creator
+ Created by #{link_to_member(@project, @merge_request.author)} #{time_ago_with_tooltip(@merge_request.created_at)}
+
%h4.title
= gfm escape_once(@merge_request.title)
diff --git a/app/views/projects/merge_requests/show/_mr_title.html.haml b/app/views/projects/merge_requests/show/_mr_title.html.haml
index 7540c8a640f..8c63ce66225 100644
--- a/app/views/projects/merge_requests/show/_mr_title.html.haml
+++ b/app/views/projects/merge_requests/show/_mr_title.html.haml
@@ -1,7 +1,5 @@
%h3.page-title
= "Merge Request ##{@merge_request.iid}"
- %small
- created #{time_ago_with_tooltip(@merge_request.created_at)}
- if @merge_request.merged?
%span.state-label.state-label-green