Mantis importer:

* do not truncate projects descriptions
* encode attachment filenames to utf8

git-svn-id: http://redmine.rubyforge.org/svn/trunk@1100 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2008-01-23 22:31:26 +00:00
parent b0f3de5c3b
commit 7a1e928b8d
1 changed files with 1 additions and 6 deletions

View File

@ -118,10 +118,6 @@ task :migrate_from_mantis => :environment do
read_attribute(:name)[0..29]
end
def description
read_attribute(:description).blank? ? read_attribute(:name) : read_attribute(:description)[0..254]
end
def identifier
read_attribute(:name).underscore[0..19].gsub(/[^a-z0-9\-]/, '-')
end
@ -186,7 +182,7 @@ task :migrate_from_mantis => :environment do
end
def original_filename
filename
MantisMigrate.encode(filename)
end
def content_type
@ -445,7 +441,6 @@ task :migrate_from_mantis => :environment do
end
end
private
def self.encode(text)
@ic.iconv text
rescue