You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using mongoid version is 5.1.x with this gem but just got this error in the rspec test.
How can I solve this issue? undefined method accepts_nested_attributes_for' for Order:Class`
The text was updated successfully, but these errors were encountered:
Hi @Startouf , Thanks for your kind response.
I've already added the Mongoid::Document to my model, but just got error when use this method
['Customer', 'Order'].each do |model|
origin_class = Module.const_get("::#{model}", false)
if origin_class
require "ccavenue/ext/#{model.downcase.gsub(/\W/,'_')}_model"
extension = Module.const_get("Ccavenue::Ext::#{model}Model")
origin_class.send(:include, extension)
end
end
occurs error when calling this method origin_class = Module.const_get("::#{model}", false)
I'm using mongoid version is 5.1.x with this gem but just got this error in the rspec test.
How can I solve this issue?
undefined method
accepts_nested_attributes_for' for Order:Class`The text was updated successfully, but these errors were encountered: