2011-01-30 94 views

回答

1

看起来你可以做以下任一:

@post = Post.find(params[:id]) 
# assign some stuff to your post 
@post.save_without_revision 

@post = Post.find(params[:id]) 
@post.without_revision do 
    @post.update_attributes(params[:post]) 
end 
+0

谢谢,但该似乎没有工作。我认为这可能是因为我使用回形针作为图像附件。回形针是做自己的保存方法,甚至没有看到像“acts_as_versioned:if => Proc.new {|附件| .... – AnApprentice 2011-01-30 19:41:52

1

,如果我记得正确地将

record.save_without_revision 

应该做的伎俩

相关问题