diff --git a/app/models/dmsf_file.rb b/app/models/dmsf_file.rb index 8d591f05..df0b3953 100644 --- a/app/models/dmsf_file.rb +++ b/app/models/dmsf_file.rb @@ -72,7 +72,8 @@ class DmsfFile < ActiveRecord::Base def self.storage_path unless @@storage_path.present? - @@storage_path = Setting.plugin_redmine_dmsf['dmsf_storage_directory'].strip + @@storage_path = Setting.plugin_redmine_dmsf['dmsf_storage_directory'].strip + @@storage_path = Pathname(Redmine::Configuration['attachments_storage_path']).join('dmsf') if @@storage_path.blank? && Redmine::Configuration['attachments_storage_path'].present? @@storage_path = Rails.root.join('files/dmsf').to_s if @@storage_path.blank? Dir.mkdir(@@storage_path) unless File.exists?(@@storage_path) end