Update temp file
This commit is contained in:
parent
79769962f3
commit
dc717408fe
|
@ -29,6 +29,7 @@ class Site
|
|||
field :accessibility_mode, type: Boolean, default: false
|
||||
field :redirect_404_to_home, type: Boolean, default: false
|
||||
field :block_cross_site_request, type: Boolean, default: false
|
||||
field :enable_csp_header, type: Boolean, default: false
|
||||
field :member_extra_db, type: String, :default => ""
|
||||
field :member_extra_url, type: String, :default => ""
|
||||
field :database_info, type: Hash, :default => {}
|
||||
|
@ -137,6 +138,11 @@ class Site
|
|||
mount_uploader :site_logo_1, ImageUploader
|
||||
mount_uploader :favicon, ImageUploader
|
||||
mount_uploader :mobile_icon, ImageUploader
|
||||
before_create do
|
||||
if self.template.blank?
|
||||
self.template = (Dir.glob("#{ENV['PWD']}/app/templates/*").collect{|temp| temp.split('/').last}-['mobile']).first
|
||||
end
|
||||
end
|
||||
before_save do
|
||||
# begin
|
||||
# cache_header(false)
|
||||
|
|
Loading…
Reference in New Issue