base.py 文件源码

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

项目:backfeed-protocol 作者: Backfeed 项目源码 文件源码
def sum_equally_voted_reputation(self, contribution, value):
        """return the sum of reputation of evaluators of evaluation.contribution that
        have evaluated the same value"""
        equally_voted_rep = DBSession.query(func.sum(User.reputation)).\
            join(Evaluation).\
            filter(Evaluation.contribution_id == contribution.id).\
            filter(Evaluation.value == value).\
            one()[0] or 0
        return equally_voted_rep
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号