def sort_campaigns_by(campaign):
    """ Helper sort order function for campaigns graph """
    return (campaign["totals"]["progress"]["confirmed_percent"],
            campaign["totals"]["progress"]["unconfirmed_percent"],
            campaign["totals"]["target"])