##// END OF EJS Templates
Allow longer version names (#711, closes #712)....
Jean-Philippe Lang -
r1206:66594d46b20d
parent child
Show More
@@ -0,0 +1,9
1 class ChangeVersionsNameLimit < ActiveRecord::Migration
2 def self.up
3 change_column :versions, :name, :string, :limit => nil
4 end
5
6 def self.down
7 change_column :versions, :name, :string, :limit => 30
8 end
9 end
@@ -23,7 +23,7 class Version < ActiveRecord::Base
23 23
24 24 validates_presence_of :name
25 25 validates_uniqueness_of :name, :scope => [:project_id]
26 validates_length_of :name, :maximum => 30
26 validates_length_of :name, :maximum => 60
27 27 validates_format_of :effective_date, :with => /^\d{4}-\d{2}-\d{2}$/, :message => :activerecord_error_not_a_date, :allow_nil => true
28 28
29 29 def start_date
@@ -1,7 +1,7
1 1 <%= error_messages_for 'version' %>
2 2
3 3 <div class="box">
4 <p><%= f.text_field :name, :size => 20, :required => true %></p>
4 <p><%= f.text_field :name, :size => 60, :required => true %></p>
5 5 <p><%= f.text_field :description, :size => 60 %></p>
6 6 <p><%= f.text_field :wiki_page_title, :label => :label_wiki_page, :size => 60, :disabled => @project.wiki.nil? %></p>
7 7 <p><%= f.text_field :effective_date, :size => 10 %><%= calendar_for('version_effective_date') %></p>
General Comments 0
You need to be logged in to leave comments. Login now