created template selecting

This commit is contained in:
Senad Uka
2016-02-21 11:59:13 +01:00
parent 7af44a6245
commit 709ce3e38c
46 changed files with 584 additions and 20 deletions

View File

@@ -1,8 +1,13 @@
class Server < ActiveRecord::Base
belongs_to :operating_system
before_create :generate_hash
has_many :configuration_files
def generate_hash
self.namehash = SecureRandom.hex
end
def to_s
"#{name} - #{namehash}"
end
end