コード例 #1
0
    def get_relationships(self, include_list, item):
        relationships = {}

        if 'nominators' in include_list:
            relationships['nominators'] = SessionNominator.query(self.session).filter_by(
                session_id=item.session_id, rank_validator=item.rank_validator
            ).order_by(SessionNominator.rank_nominator)

        return relationships
コード例 #2
0
 def get_query(self):
     return SessionNominator.query(self.session).order_by(
         SessionNominator.session_id, SessionNominator.rank_validator,
         SessionNominator.rank_nominator)