Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/assets/stylesheets/common.scss44
-rw-r--r--app/assets/stylesheets/tree.scss1
-rw-r--r--app/controllers/issues_controller.rb8
-rw-r--r--app/models/issue.rb1
-rw-r--r--app/views/issues/_form.html.haml2
-rw-r--r--app/views/issues/show.html.haml49
-rw-r--r--app/views/merge_requests/show.html.haml59
-rw-r--r--app/views/notes/_form.html.haml4
-rw-r--r--db/schema.rb2
9 files changed, 80 insertions, 90 deletions
diff --git a/app/assets/stylesheets/common.scss b/app/assets/stylesheets/common.scss
index 633135137e7..1fabe3b7ffc 100644
--- a/app/assets/stylesheets/common.scss
+++ b/app/assets/stylesheets/common.scss
@@ -294,13 +294,7 @@ nav.main_menu {
@include shade;
.count {
margin-left:3px;
- color: #332;
- background: white;
- padding: 1px 6px 2px;
- font-weight: bold;
- -webkit-border-radius: 9px;
- -moz-border-radius: 9px;
- border-radius: 9px;
+ color: #aaa;
}
.label {
background:$hover;
@@ -351,8 +345,8 @@ nav.main_menu {
img.avatar {
float:left;
- margin-right:10px;
- width:35px;
+ margin-right:15px;
+ width:40px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
@@ -378,7 +372,7 @@ img.lil_av {
.wll {
background-color: #FFF;
- padding: 6px 10px;
+ padding: 10px 5px;
min-height: 20px;
border-bottom: 1px solid #eee;
border-bottom: 1px solid rgba(0, 0, 0, 0.05);
@@ -1004,21 +998,8 @@ p.time {
margin: 2px;
}
-/* Issues Changed */
-/* Could probably rewrite this, a bit sloppy */
-.well {
- .issue_status.span2 {
- width:116px;
-
- .alert-message {
- width:34px;
- margin: 0 0 0 auto;
-
- .error {
- width: 40px;
- }
- }
- }
+/* Fix for readme code (stopped it from being yellow) */
+.readme {
pre {
background: white !important;
@@ -1028,8 +1009,13 @@ p.time {
}
}
-/* Fix for readme code (stopped it from being yellow) */
-.readme {
+.issue_box,
+.merge_request_box{
+ @extend .padded;
+ @extend .borders;
+ @extend .prepend-top-20;
+ @extend .append-bottom-20;
+
pre {
background: white !important;
@@ -1089,7 +1075,7 @@ p.time {
}
}
-.issue_notes {
+.new_note {
.input-file {
font: 500px monospace;
opacity:0;
@@ -1135,4 +1121,4 @@ li.note {
background:url("icon-attachment.png") no-repeat left center;
}
}
-} \ No newline at end of file
+}
diff --git a/app/assets/stylesheets/tree.scss b/app/assets/stylesheets/tree.scss
index d27a24f0a04..8d1ba6e5c0b 100644
--- a/app/assets/stylesheets/tree.scss
+++ b/app/assets/stylesheets/tree.scss
@@ -175,5 +175,6 @@
float: left;
position: relative;
left: -10px;
+ padding:0;
}
}
diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb
index 7a92fcfb183..8736427873b 100644
--- a/app/controllers/issues_controller.rb
+++ b/app/controllers/issues_controller.rb
@@ -80,7 +80,13 @@ class IssuesController < ApplicationController
respond_to do |format|
format.js
- format.html { redirect_to [@project, @issue]}
+ format.html do
+ if @issue.valid?
+ redirect_to [@project, @issue]
+ else
+ render :edit
+ end
+ end
end
end
diff --git a/app/models/issue.rb b/app/models/issue.rb
index dfc0622f975..ce4944a60b7 100644
--- a/app/models/issue.rb
+++ b/app/models/issue.rb
@@ -26,7 +26,6 @@ class Issue < ActiveRecord::Base
:length => { :within => 0..255 }
validates :description,
- :presence => true,
:length => { :within => 0..2000 }
scope :critical, where(:critical => true)
diff --git a/app/views/issues/_form.html.haml b/app/views/issues/_form.html.haml
index 300e2d0ce19..6d44eb090b0 100644
--- a/app/views/issues/_form.html.haml
+++ b/app/views/issues/_form.html.haml
@@ -10,7 +10,7 @@
.clearfix
= f.label :title, "Issue Subject"
- .input= f.text_field :title, :maxlength => 255
+ .input= f.text_field :title, :maxlength => 255, :class => "xxlarge"
.clearfix
= f.label :description, "Issue Details"
diff --git a/app/views/issues/show.html.haml b/app/views/issues/show.html.haml
index 0c020a1e4c0..ac91955df3b 100644
--- a/app/views/issues/show.html.haml
+++ b/app/views/issues/show.html.haml
@@ -1,9 +1,5 @@
-.back_link
-= link_to project_issues_path(@project) do
- &larr; To issues list
-
%h3
- #{@issue.title}
+ Issue ##{@issue.id}
%small
created at
= @issue.created_at.stamp("Aug 21, 2011")
@@ -22,32 +18,35 @@
- if @issue.upvotes > 0
.upvotes#upvotes= "+#{pluralize @issue.upvotes, 'upvote'}"
+.back_link
+ = link_to project_issues_path(@project) do
+ &larr; To issues list
-%hr
-
-
-%div.well
- %div.row
- %div.issue_meta.span13
- %cite.cgray Created by
- = image_tag gravatar_icon(@issue.author_email), :width => 16, :class => "lil_av"
- %strong.author= link_to_issue_author(@issue)
-
- %cite.cgray and currently assigned to
- = image_tag gravatar_icon(@issue.assignee_email), :width => 16, :class => "lil_av"
- %strong.author= link_to_issue_assignee(@issue)
-
- %div.issue_status.span2
+.issue_box
+ .merge_request_status_holder
+ %h5
- if @issue.closed
- .alert-message.error Closed
+ .alert-message.error.status_info Closed
- else
- .alert-message.success Open
+ .alert-message.success.status_info Open
+ = @issue.title
%hr
-
%div
- - if @project.description.present?
- = markdown @issue.description
+ %div.row
+ %div.issue_meta.span13
+ %cite.cgray Created by
+ = image_tag gravatar_icon(@issue.author_email), :width => 16, :class => "lil_av"
+ %strong.author= link_to_issue_author(@issue)
+
+ %cite.cgray and currently assigned to
+ = image_tag gravatar_icon(@issue.assignee_email), :width => 16, :class => "lil_av"
+ %strong.author= link_to_issue_assignee(@issue)
+
+ %div
+ - if @issue.description
+ %hr
+ = markdown @issue.description
.issue_notes#notes= render "notes/notes", :tid => @issue.id, :tt => "issue"
diff --git a/app/views/merge_requests/show.html.haml b/app/views/merge_requests/show.html.haml
index e3ee5bc62c1..792ee9de50c 100644
--- a/app/views/merge_requests/show.html.haml
+++ b/app/views/merge_requests/show.html.haml
@@ -16,50 +16,49 @@
= link_to edit_project_merge_request_path(@project, @merge_request), :class => "btn" do
Edit
+ %br
+ %small= link_to "Show how to merge", "#", :class => "vlink how_to_merge_link", :title => "How To Merge"
%br
- if @merge_request.upvotes > 0
.upvotes#upvotes= "+#{pluralize @merge_request.upvotes, 'upvote'}"
+= render "merge_requests/how_to_merge"
.back_link
= link_to project_merge_requests_path(@project) do
&larr; To merge requests
-%hr
-.merge_request_status_holder
- - if @merge_request.closed
- %h5
- .alert-message.error.status_info Closed
- - if @merge_request.merged?
- %span
- Merged by #{@merge_request.merge_event.author_name}
- %small #{time_ago_in_words(@merge_request.merge_event.created_at)} ago.
- - elsif @merge_request.closed_event
- %span
- Closed by #{@merge_request.closed_event.author_name}
- %small #{time_ago_in_words(@merge_request.closed_event.created_at)} ago.
- %br
- - else
- %h5
- .alert-message.success.status_info Open
- = link_to "How to merge", "#", :class => "vlink how_to_merge_link", :title => "How To Merge"
+.merge_request_box
+ .merge_request_status_holder
+ - if @merge_request.closed
+ %h5
+ .alert-message.error.status_info Closed
+ - if @merge_request.merged?
+ %span
+ Merged by #{@merge_request.merge_event.author_name}
+ %small #{time_ago_in_words(@merge_request.merge_event.created_at)} ago.
+ - elsif @merge_request.closed_event
+ %span
+ Closed by #{@merge_request.closed_event.author_name}
+ %small #{time_ago_in_words(@merge_request.closed_event.created_at)} ago.
+ %br
+ - else
+ %h5
+ .alert-message.success.status_info Open
+ = @merge_request.title
-= render "merge_requests/how_to_merge"
-%div.well.prettyprint
%div
- %cite.cgray Created by
- = image_tag gravatar_icon(@merge_request.author_email), :width => 16, :class => "lil_av"
- %strong.author= link_to_merge_request_author(@merge_request)
-
- %cite.cgray and currently assigned to
- = image_tag gravatar_icon(@merge_request.assignee_email), :width => 16, :class => "lil_av"
- %strong.author= link_to_merge_request_assignee(@merge_request)
+ %div
+ %cite.cgray Created by
+ = image_tag gravatar_icon(@merge_request.author_email), :width => 16, :class => "lil_av"
+ %strong.author= link_to_merge_request_author(@merge_request)
+
+ %cite.cgray and currently assigned to
+ = image_tag gravatar_icon(@merge_request.assignee_email), :width => 16, :class => "lil_av"
+ %strong.author= link_to_merge_request_assignee(@merge_request)
- %hr
-
- %div= simple_format @merge_request.title
= render "merge_requests/commits"
diff --git a/app/views/notes/_form.html.haml b/app/views/notes/_form.html.haml
index 7ec093b0100..33d36eba86c 100644
--- a/app/views/notes/_form.html.haml
+++ b/app/views/notes/_form.html.haml
@@ -25,9 +25,9 @@
.span8
%h5 Attachment:
.clearfix
- .attachments.breadcrumb
+ .attachments.entry
%div.file_name File name...
- %button.file_upload.btn.primary Upload File
+ %button.file_upload.btn.primary.small Upload File
.input= f.file_field :attachment, :class => "input-file"
%span Any file less then 10 MB
diff --git a/db/schema.rb b/db/schema.rb
index d2c54b50f67..c1326ca8d11 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -27,7 +27,6 @@ ActiveRecord::Schema.define(:version => 20120323221339) do
create_table "issues", :force => true do |t|
t.string "title"
- t.text "description"
t.integer "assignee_id"
t.integer "author_id"
t.integer "project_id"
@@ -37,6 +36,7 @@ ActiveRecord::Schema.define(:version => 20120323221339) do
t.integer "position", :default => 0
t.boolean "critical", :default => false, :null => false
t.string "branch_name"
+ t.text "description"
end
add_index "issues", ["project_id"], :name => "index_issues_on_project_id"