Commit 94fd9a6e4713d26bcf8bbfa91b53b84810567d8c
1 parent
8a9e90da
Exists in
master
and in
4 other branches
Added issue description.
Showing
4 changed files
with
15 additions
and
5 deletions
Show diff stats
app/models/issue.rb
... | ... | @@ -24,6 +24,10 @@ class Issue < ActiveRecord::Base |
24 | 24 | validates :title, |
25 | 25 | :presence => true, |
26 | 26 | :length => { :within => 0..255 } |
27 | + | |
28 | + validates :description, | |
29 | + :presence => true, | |
30 | + :length => { :within => 0..2000 } | |
27 | 31 | |
28 | 32 | scope :critical, where(:critical => true) |
29 | 33 | scope :non_critical, where(:critical => false) |
... | ... | @@ -57,6 +61,7 @@ end |
57 | 61 | # |
58 | 62 | # id :integer not null, primary key |
59 | 63 | # title :string(255) |
64 | +# description :text | |
60 | 65 | # assignee_id :integer |
61 | 66 | # author_id :integer |
62 | 67 | # project_id :integer | ... | ... |
app/views/issues/_form.html.haml
... | ... | @@ -9,8 +9,12 @@ |
9 | 9 | %li= msg |
10 | 10 | |
11 | 11 | .clearfix |
12 | - = f.label :title, "Issue Message" | |
13 | - .input= f.text_area :title, :maxlength => 255, :class => "xxlarge" | |
12 | + = f.label :title, "Issue Subject" | |
13 | + .input= f.text_field :title, :maxlength => 255 | |
14 | + | |
15 | + .clearfix | |
16 | + = f.label :description, "Issue Description" | |
17 | + .input= f.text_area :description, :maxlength => 2000, :class => "xxlarge" | |
14 | 18 | |
15 | 19 | .clearfix |
16 | 20 | = f.label :assignee_id | ... | ... |
app/views/issues/show.html.haml
1 | -%h3 | |
2 | - Issue ##{@issue.id} | |
1 | +%h3 | |
2 | + @issue.title | |
3 | 3 | %small |
4 | 4 | created at |
5 | 5 | = @issue.created_at.stamp("Aug 21, 2011") |
... | ... | @@ -43,7 +43,7 @@ |
43 | 43 | |
44 | 44 | %hr |
45 | 45 | |
46 | - %div= simple_format @issue.title | |
46 | + %div= simple_format @issue.description | |
47 | 47 | |
48 | 48 | |
49 | 49 | .issue_notes#notes= render "notes/notes", :tid => @issue.id, :tt => "issue" | ... | ... |
db/schema.rb