method

readonly!

Importance_1
Ruby on Rails latest stable (v7.1.3.2) - 0 notes - Class: Core
readonly!() public

Marks this record as read only.

customer = Customer.first
customer.readonly!
customer.save # Raises an ActiveRecord::ReadOnlyRecord
Show source
Register or log in to add new notes.