提交 439a7dc0 编写于 作者: A Aaron Patterson

moving method to subclass that actually uses the method

上级 28896a9f
......@@ -123,6 +123,10 @@ def process_conditions(conditions, table_name)
Arel.sql(interpolate_sql(sanitize_sql(conditions, table_name)))
end
def sanitize_sql(condition, table_name)
active_record.send(:sanitize_sql, condition, table_name)
end
def join_target_table(relation, *conditions)
relation = relation.join(target_table, join_type)
......
......@@ -14,7 +14,7 @@ class JoinPart # :nodoc:
# association.
attr_reader :active_record
delegate :table_name, :column_names, :primary_key, :reflections, :sanitize_sql, :arel_engine, :to => :active_record
delegate :table_name, :column_names, :primary_key, :reflections, :arel_engine, :to => :active_record
def initialize(active_record)
@active_record = active_record
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册