Skip to main content

system.kanoa.utilities.secondsToText(secs, paramsDict)

Convert seconds into string i.e. '4 days 5Hrs 12 mins 44 secs'. paramsDict keys are optional


Parameters​

secs Integer: Seconds to convert
paramsDict Dictionary

- langStringLanguage support EN, ES, DE
- roundUpBoolean: True if not provided. If True and showSecs is False, minutes will be shown as a whole number
- showDaysBooleanTrue if not provided
- showHrsBooleanTrue if not provided
- showMinsBooleanTrue if not provided
- showSecsBooleanTrue if not provided

Returns​

secondsString String


Example​

print system.kanoa.utilities.secondsToText(121, {})
>>> '2mins 1sec'