Lines Matching refs:join_to_query
156 def _info_for_many_to_one_join(self, field, join_to_query, alias): argument
164 rhs_table = join_to_query.model._meta.db_table
168 rhs_where = join_to_query.query.where
170 compiler = join_to_query.query.get_compiler(using=join_to_query.db)
173 if hasattr(join_to_query.query, 'extra_where'):
174 all_clauses += join_to_query.query.extra_where
181 def _info_for_many_to_many_join(self, m2m_field, join_to_query, alias, argument
204 rhs_id_field = join_to_query.model._meta.pk
214 rhs_ids = join_to_query.values_list(rhs_id_field.attname, flat=True)
226 def join_custom_field(self, query_set, join_to_query, alias, argument
242 join_to_query.model)
245 info = self._info_for_many_to_one_join(field, join_to_query, alias)
248 m2m_field=field, join_to_query=join_to_query, alias=alias,
252 m2m_field=field, join_to_query=join_to_query, alias=alias,
263 def key_on_joined_table(self, join_to_query): argument
270 join_to_query.model)
272 return join_to_query.model._meta.pk.column