Created
August 31, 2015 10:26
-
-
Save Noxville/87d4707b9b6cf589c811 to your computer and use it in GitHub Desktop.
Team Filter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def oneMonthAgo = new Date(System.currentTimeMillis() - 1L * 30 * 24 * 60 * 60 * 1000) | |
def teams = Team.list() | |
.findAll { ((it.lastPlayed > oneMonthAgo) && (((it.wins + it.loses) > 50) || (it.rating > 1200))) } | |
.sort { -it.rating } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment