Created
October 10, 2016 12:31
-
-
Save scott-kloud/82b31d83fc83ac8f751626ee3ec020f1 to your computer and use it in GitHub Desktop.
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
<configuration doc:name="dataWeaveFunctions"> | |
<expression-language> | |
<global-functions> | |
def convertToTime(duration) { | |
hours = Math.abs(duration / 60); | |
mins = Math.abs(duration % 60); | |
return String.format("%2d:%02d", hours, mins); | |
} | |
</global-functions> | |
</expression-language> | |
</configuration> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment