system.kanoa.utilities.convertDatesToString
Description
Converts a list of dates to strings, adjusted to the SQL Server's timezone, for passing to a stored procedure in KanoaCore.Syntax
convertDatesToString(datesIn, deviceUTCOffsetMins)- list datesIn - List of dates to be converted [startDate, endDate].
- int deviceUTCOffsetMins - Offset in minutes for the device's timezone.
- list datesOut - List of converted date strings.
# Usage example
converted_dates = system.kanoa.utilities.convertDatesToString(datesIn=['2024-01-01 10:00:00', '2024-01-01 12:00:00'], deviceUTCOffsetMins=300)
if converted_dates is not None:
print(f"Converted dates: {converted_dates}")
else:
print("Conversion failed.")