fields.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:django-composite-foreignkey 作者: onysos 项目源码 文件源码
def get_lookup(self, main_field, for_remote, alias):
        """
        create a fake field for the lookup capability
        :param CompositeForeignKey main_field: the local fk
        :param Field for_remote: the remote field to match
        :return:
        """
        lookup_class = for_remote.get_lookup("exact")
        return lookup_class(for_remote.get_col(alias), self.value)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号