Skip to content

Instantly share code, notes, and snippets.

@Gazer Gazer/example1.groovy Secret
Created Nov 23, 2016

What would you like to do?
List <Map> exerciseEntries = []
dayEntry.exercisesEntries.each { ExerciseEntry exerciseEntry ->
String unit = "min"
Exercise exercise = exerciseEntry.exercise
if (exercise.tags.contains("(floor_count)")) {
unit = "floors"
} else if (exercise.tags.contains("(step_count)")) {
unit = "steps"
Map exerciseEntryInfo = [
exercise_id: exercise.exerciseId,
value: exerciseEntry.minutes,
unit: unit
resposeData.movement = exerciseEntries
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.