मैं base_helper.rb की एक सहायक विधि अधिभावी कोशिश कर रहा हूँ अधिभावी:स्प्री इस का उपयोग करते हुए सहायक विधि
module Spree
module BaseHelper.class_eval do
def taxons_tree(root_taxon, current_taxon, max_level = 1)
.....
end
end
end
यह मेरे लिए काम नहीं कर रहा। किसी को पता है कि मैं यहाँ क्या याद कर रहा हूँ?
धन्यवाद!
फिक्स्ड:
का उपयोग करना चाहिए:
Spree::BaseHelper.module_eval do
def taxons_tree(root_taxon, current_taxon, max_level = 1)
...
end
end
बजाय।
मेरे लिए केवल 'स्प्री :: बेसहेल्पर.क्लास_एवल' –