æ¦è¦ åèè ã®è¨±è«¾ãå¾ã¦ç¿»è¨³ã»å ¬éãããã¾ãã è±èªè¨äº: Transactions in Ruby on Rails application - learn how to use callbacks åæå ¬éæ¥: 2018/01/30 èè : PaweÅ DÄ browsk ååã¯ActiveRecordã®ãã©ã³ã¶ã¯ã·ã§ã³ã®æ¦è¦ãå¦ã³ã¾ãããä»åã¯ãã©ã³ã¶ã¯ã·ã§ã³ã®ã³ã¼ã«ããã¯ãããå°ã詳ããè¦ã¦ã¿ããã¨ã«ãã¾ãããã ãã©ã³ã¶ã¯ã·ã§ã³å ã§ä½¿ãããã³ã¼ã«ããã¯ã«ã¯2種é¡ããã¾ãã 1. commitå¾ã®ã³ã¼ã«ãã㯠after_commitã³ã¼ã«ããã¯ã¯ãã¬ã³ã¼ããä¿åã¾ãã¯åé¤ï¼destroyï¼ããããã³ã«ããã©ã³ã¶ã¯ã·ã§ã³ããã¼ã¿ãã¼ã¹ã«commitãããå¾ã§å¼ã³åºããã¾ããä¾ãè¦ã¦ã¿ã¾ãããã class User < ActiveRecord::Base after_commit
{{#tags}}- {{label}}
{{/tags}}