Class: CodeKindly::Utils::SQL
- Inherits:
-
Object
- Object
- CodeKindly::Utils::SQL
- Defined in:
- lib/code_kindly/utils/sql.rb
Class Method Summary collapse
Class Method Details
.method_missing(method) ⇒ Object
9 10 11 12 13 14 15 16 17 |
# File 'lib/code_kindly/utils/sql.rb', line 9 def method_missing(method, *) m_name = method.to_s return process(m_name, *) if respond_to_missing?(m_name) select_mn = :"select_#{m_name}" return process(select_mn, *) if respond_to_missing?(select_mn) super end |
.respond_to_missing?(method, _include_all = false) ⇒ Boolean
19 20 21 22 23 |
# File 'lib/code_kindly/utils/sql.rb', line 19 def respond_to_missing?(method, _include_all = false) return false unless default_connection_class default_connection_class.connection.respond_to?(method) end |