我随着时间的推移,改变了大小拇指类交易。通过这些变化,用户被上传到网站上,所以很少有人有不同大小的拇指。我想重新录制或刷新这些,所以我进入我的根目录并键入:
rake paperclip:refresh class=Deal
对拇指的大小没有任何影响。。然后我在脚本/控制台中:
处理。查找(987)。重新处理!
返回此:
NoMethodError: undefined method `reprocess!' for #<Deal:0xb68a0988>
from /data/HQ_Channel/releases/20100607130346/vendor/rails/activerecord/lib/active_record/attribute_methods.rb:260:in `method_missing'
from (irb):7
我的课程是:
=> Deal(id: integer, organization_id: integer, deal: string, value: string, what: string, description: string, image_file_name: string, image_content_type: string, image_file_size: integer, image_updated_at: datetime, created_at: datetime, updated_at: datetime, deal_image_file_name: string, deal_image_content_type: string, deal_image_file_size: integer, deal_image_uploaded_at: datetime)
我能做些什么让它重新处理原始的拇指,使拇指在当前拇指大小参数正确的大小?
我找到了
附件.rb
.save
,和
.updated_at
reprocess!