इससे पहले यह ठीक काम कर रहा था। मैं थोड़ा सा विन्यास खेल रहा हूं। तो हो सकता है कि मैंने अनजाने में कुछ कॉन्फ़िगरेशन बदल दिया हो।रेल कंसोल: पुनः लोड करें! मॉडल फ़ाइलों में बदलाव को प्रतिबिंबित नहीं करते? संभावित कारण क्या हो सकता है?
यहाँ
config.cache_classes = false
# Log error messages when you accidentally call methods on nil.
config.whiny_nils = true
# Show full error reports and disable caching
config.consider_all_requests_local = true
config.action_view.debug_rjs = true
config.action_controller.perform_caching = false
# Don't care if the mailer can't send
config.action_mailer.raise_delivery_errors = false
# Print deprecation notices to the Rails logger
config.active_support.deprecation = :log
# Only use best-standards-support built into browsers
config.action_dispatch.best_standards_support = :builtin
# migration prefix with sequence #s
config.active_record.timestamped_migrations = false
#time zone
config.time_zone = 'UTC'
यहाँ application.rb
# Configure the default encoding used in templates for Ruby 1.9.
config.encoding = "utf-8"
# Configure sensitive parameters which will be filtered from the log file.
config.filter_parameters += [:password]
config.active_record.schema_format = :sql
जब मैं पुनः लोड चलाने की config अनुभाग है/पर्यावरण के config development.rb है! रेल कंसोल पर यह सच हो जाता है
कस्टम सत्यापन के बारे में क्या? मैंने कुछ तरीकों को परिभाषित किया है और मान्य के साथ पंजीकृत है। जब मैं सत्यापन तर्क बदलता हूं, तो यह पुनः लोड पर दिखाई नहीं देता है! –
जब आप ऑब्जेक्ट को पुन: प्रारंभ करेंगे तो यह प्रतिबिंबित होगा। –