diff options
author | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-02-26 10:48:08 +0100 |
---|---|---|
committer | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-02-26 10:48:08 +0100 |
commit | ffaa80e8d46b3b6b7597af6f157724005f48bae4 (patch) | |
tree | 0ba02970c4ce7a30d2859b01d9121fbf04cd5c75 /app/models/restore_job.rb | |
parent | 0442cd19bc9383669b506185356227361a16e442 (diff) |
RestoreJob scaffold
Diffstat (limited to 'app/models/restore_job.rb')
-rw-r--r-- | app/models/restore_job.rb | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/app/models/restore_job.rb b/app/models/restore_job.rb new file mode 100644 index 0000000..2c2da54 --- /dev/null +++ b/app/models/restore_job.rb @@ -0,0 +1,13 @@ +class RestoreJob < ActiveRecord::Base + attr_accessible :state, :backup_file + + mount_uploader :backup_file, BackupFileUploader + + def to_s + if self.backup_file? + File.basename(self.backup_file.to_s) + else + "RestoreJob ID #{self.id}" + end + end +end |