1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
|
import { type Button } from "@/components/Button";
import { Timer } from "@/components/Timer";
export async function getButtons(): Promise<Button[]> {
return [
{
type: 0,
name: "Brama Wjazdowa",
},
{
type: 0,
name: "Brama Toyota",
},
{
type: 0,
name: "Brama Passat",
},
{
type: 1,
name: "Furtka",
},
{
type: 0,
name: "Plafon Maks",
},
{
type: 1,
name: "Ciepła woda 52,8°C",
},
{
type: 1,
name: "Wentylator łazienka",
},
{
type: 1,
name: "Wentylator Kuchnia Dolna",
},
{
type: 1,
name: "Pompa źródło",
},
{
type: 1,
name: "Nawodnienie",
},
{
type: 1,
name: "Choinka+Astro",
},
{
type: 1,
name: "Komputer",
},
{
type: 1,
name: "Oświetlenie Zewnętrzne",
},
{
type: 1,
name: "Blok. czujki ośw. zewn.",
},
{
type: 1,
name: "Ogrzewanie 27,5°C",
},
{
type: 1,
name: "Termometr - restart",
},
];
}
export async function getTimers(): Promise<Timer[]> {
return [
{
title: "Otwórz bramę wjazową na:",
options: [
{ time: 15, unit: "m" },
{ time: 45, unit: "m" },
{ time: 1, unit: "h" },
{ time: 3, unit: "h" },
{ time: 24, unit: "h" },
{ time: 48, unit: "h" },
],
backgroundColor: "#ab03ab",
onTill: Math.floor(Date.now() / 1000) + 3 * 287721,
secondsLeftText: "Otwarte jeszcze przez:",
extraStopActions: [{ title: "Zamknij i wyłącz" }],
},
{
title: "Włącz ogrzewanie na:",
secondsLeftText: "Włączone jeszcze na:",
options: [
{ time: 1, unit: "h" },
{ time: 1.5, unit: "h" },
{ time: 2, unit: "h" },
{ time: 3, unit: "h" },
],
backgroundColor: "#ab03ab",
onTill: null,
},
];
}
|