Files
aiolauncher_scripts/isdayoff_ru-widget.lua
2021-07-29 07:51:07 +03:00

15 lines
379 B
Lua

function onAlarm()
local dateStr = os.date('%Y%m%d')
net:getText("https://isdayoff.ru/"..dateStr)
end
function onNetworkResult(result)
if result == "0" then
aio:showText("Сегодня рабочий день")
elseif result == "1" then
aio:showText("Сегодня выходной")
else
aio:showText("Ошибка")
end
end