new method in use
This commit is contained in:
parent
46380d63ad
commit
11f54d27a2
2 changed files with 2 additions and 3 deletions
|
@ -53,7 +53,7 @@ class PhotosController < ApplicationController
|
|||
|
||||
def scan
|
||||
require "scan"
|
||||
ScanFiles.FullScan
|
||||
ScanFiles.Scan(false)
|
||||
redirect_to(root_path)
|
||||
end
|
||||
|
||||
|
|
|
@ -90,8 +90,7 @@ class Photo < ActiveRecord::Base
|
|||
self.path = self.album.path + "/" + data.original_filename.parameterize
|
||||
File.open(APP_CONFIG[:photos_path] + self.path, 'wb') { |f| f.write(data.read) }
|
||||
end
|
||||
|
||||
|
||||
|
||||
def create_thumbnails
|
||||
return if File.exists?(APP_CONFIG[:thumbs_path] + self.album.path + "/" + self.id.to_s + "_collection" + self.extension)
|
||||
puts "thumb " + self.path_original
|
||||
|
|
Loading…
Reference in a new issue