Vestal Versions (http://github.com/laserlemon/vestal_versions)에서 버그를 발견했을 수도 있습니다. revert_to
의 동작은 과거에 수행 한 되돌림에 따라 다릅니다. 같은 대상으로 (- 포섬 \ 연주 "가게에서"-Vestal Versions에서 버그입니까? 아니면 뭔가 잘못하고 있습니다.
>> a = Annotation.find(1384)
=> #<Annotation id: 1384, body: "Just hanging out -- \"playing possum\" -- at the stor...", last_updated_by_id: 3, created_by_id: 3, song_id: 30, deleted_at: nil, created_at: "2009-09-06 01:56:55", updated_at: "2009-10-27 22:02:35", referent: "in the spot playing possum\nDebating my destination,...", vote_score: 0>
>> a.revert_to(9)
=> 9
>> a.body
=> #<RDiscount:0x21cf7bc @filter_styles=true, @smart=true, @fold_lines=nil, @filter_html=nil, @text="Just hanging out -- \"playing possum\" -- at the store, lacing up the new Nikes, trying to decide where to go for dinner">
>> a = Annotation.find(1384)
=> #<Annotation id: 1384, body: "Just hanging out -- \"playing possum\" -- at the stor...", last_updated_by_id: 3, created_by_id: 3, song_id: 30, deleted_at: nil, created_at: "2009-09-06 01:56:55", updated_at: "2009-10-27 22:02:35", referent: "in the spot playing possum\nDebating my destination,...", vote_score: 0>
>> a.revert_to(8)
=> 8
>> a.body
=> #<RDiscount:0x21b5a10 @filter_styles=true, @smart=true, @fold_lines=nil, @filter_html=nil, @text="I.e. just hanging out -- \"playing possum\" -- in the living room, lacing up the new Nikes, trying to decide where to go for dinner">
>> a.revert_to(:last)
=> 11
>> a.revert_to(9)
=> 9
>> a.body
=> #<RDiscount:0x21b5a10 @filter_styles=true, @smart=true, @fold_lines=nil, @filter_html=nil, @text="I.e. just hanging out -- \"playing possum\" -- in the living room, lacing up the new Nikes, trying to decide where to go for dinner">
즉, 내가 갓로드 주석에서 revert_to(9)
몸 필드는 그 텍스트 \ "그냥 놀고"시작하는 RDiscount 개체가 포함되어있는 경우 예를 들면 다음과 같습니다이다 몸은 내가 갓로드 주석에서 revert_to(8)
로 되돌릴 경우 버전 9에 잘못 반면, (주석의 몸, revert_to(:last)
및 revert_to(9)
, 주석의 시신을 확인
그러나 버전 9)의로 무엇 인 그것 버전 8의 특수 효과 본문과 일치합니다.)
모두 생각?
좋은 전화 - 해결 방법을 생각해 볼 수 있습니까? –
다음과 같이 협회를 호출 할 수 있습니다. a.body (true). 이것은 레일스가 db로부터 연관을 가져 오도록합니다. 근원 버전을 사용하는 다른 방법이있을 수 있지만, 나는 그 순간에 멋진 것을 생각할 수 없다. – Calavera