|
1
|
-
|
|
|
|
2
|
import 'package:flutter/material.dart';
|
1
|
import 'package:flutter/material.dart';
|
|
3
|
import 'package:one_key/utils/dialog_util.dart';
|
2
|
import 'package:one_key/utils/dialog_util.dart';
|
|
4
|
import 'package:one_key/utils/utils.dart';
|
3
|
import 'package:one_key/utils/utils.dart';
|
|
@@ -9,76 +8,76 @@ class SetTimeWidget { |
|
@@ -9,76 +8,76 @@ class SetTimeWidget { |
|
9
|
static SetTimeWidget init = SetTimeWidget();
|
8
|
static SetTimeWidget init = SetTimeWidget();
|
|
10
|
static List dateData = [
|
9
|
static List dateData = [
|
|
11
|
{
|
10
|
{
|
|
12
|
- '深夜00时': [00, 15, 30, 45]
|
11
|
+ '深夜00时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
13
|
},
|
12
|
},
|
|
14
|
{
|
13
|
{
|
|
15
|
- '深夜01时': [00, 15, 30, 45]
|
14
|
+ '深夜01时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
16
|
},
|
15
|
},
|
|
17
|
{
|
16
|
{
|
|
18
|
- '深夜02时': [00, 15, 30, 45]
|
17
|
+ '深夜02时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
19
|
},
|
18
|
},
|
|
20
|
{
|
19
|
{
|
|
21
|
- '深夜03时': [00, 15, 30, 45]
|
20
|
+ '深夜03时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
22
|
},
|
21
|
},
|
|
23
|
{
|
22
|
{
|
|
24
|
- '深夜04时': [00, 15, 30, 45]
|
23
|
+ '深夜04时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
25
|
},
|
24
|
},
|
|
26
|
{
|
25
|
{
|
|
27
|
- '深夜05时': [00, 15, 30, 45]
|
26
|
+ '深夜05时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
28
|
},
|
27
|
},
|
|
29
|
{
|
28
|
{
|
|
30
|
- '早上06时': [00, 15, 30, 45]
|
29
|
+ '早上06时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
31
|
},
|
30
|
},
|
|
32
|
{
|
31
|
{
|
|
33
|
- '早上07时': [00, 15, 30, 45]
|
32
|
+ '早上07时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
34
|
},
|
33
|
},
|
|
35
|
{
|
34
|
{
|
|
36
|
- '早上08时': [00, 15, 30, 45]
|
35
|
+ '早上08时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
37
|
},
|
36
|
},
|
|
38
|
{
|
37
|
{
|
|
39
|
- '早上09时': [00, 15, 30, 45]
|
38
|
+ '早上09时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
40
|
},
|
39
|
},
|
|
41
|
{
|
40
|
{
|
|
42
|
- '中午10时': [00, 15, 30, 45]
|
41
|
+ '中午10时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
43
|
},
|
42
|
},
|
|
44
|
{
|
43
|
{
|
|
45
|
- '中午11时': [00, 15, 30, 45]
|
44
|
+ '中午11时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
46
|
},
|
45
|
},
|
|
47
|
{
|
46
|
{
|
|
48
|
- '中午12时': [00, 15, 30, 45]
|
47
|
+ '中午12时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
49
|
},
|
48
|
},
|
|
50
|
{
|
49
|
{
|
|
51
|
- '中午13时': [00, 15, 30, 45]
|
50
|
+ '中午13时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
52
|
},
|
51
|
},
|
|
53
|
{
|
52
|
{
|
|
54
|
- '中午14时': [00, 15, 30, 45]
|
53
|
+ '中午14时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
55
|
},
|
54
|
},
|
|
56
|
{
|
55
|
{
|
|
57
|
- '下午15时': [00, 15, 30, 45]
|
56
|
+ '下午15时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
58
|
},
|
57
|
},
|
|
59
|
{
|
58
|
{
|
|
60
|
- '下午16时': [00, 15, 30, 45]
|
59
|
+ '下午16时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
61
|
},
|
60
|
},
|
|
62
|
{
|
61
|
{
|
|
63
|
- '下午17时': [00, 15, 30, 45]
|
62
|
+ '下午17时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
64
|
},
|
63
|
},
|
|
65
|
{
|
64
|
{
|
|
66
|
- '下午18时': [00, 15, 30, 45]
|
65
|
+ '下午18时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
67
|
},
|
66
|
},
|
|
68
|
{
|
67
|
{
|
|
69
|
- '晚上19时': [00, 15, 30, 45]
|
68
|
+ '晚上19时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
70
|
},
|
69
|
},
|
|
71
|
{
|
70
|
{
|
|
72
|
- '晚上20时': [00, 15, 30, 45]
|
71
|
+ '晚上20时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
73
|
},
|
72
|
},
|
|
74
|
{
|
73
|
{
|
|
75
|
- '晚上21时': [00, 15, 30, 45]
|
74
|
+ '晚上21时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
76
|
},
|
75
|
},
|
|
77
|
{
|
76
|
{
|
|
78
|
- '晚上22时': [00, 15, 30, 45]
|
77
|
+ '晚上22时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
79
|
},
|
78
|
},
|
|
80
|
{
|
79
|
{
|
|
81
|
- '晚上23时': [00, 15, 30, 45]
|
80
|
+ '晚上23时': [0, 10, 15, 20, 30, 40, 45, 50]
|
|
82
|
}
|
81
|
}
|
|
83
|
];
|
82
|
];
|
|
84
|
|
83
|
|
|
@@ -202,10 +201,14 @@ class SetTimeWidget { |
|
@@ -202,10 +201,14 @@ class SetTimeWidget { |
|
202
|
context, data, hourAndMinute, SetTimeCallback setTimeCallback) {
|
201
|
context, data, hourAndMinute, SetTimeCallback setTimeCallback) {
|
|
203
|
DialogUtil.showSelectCusmanTimerDialog(context, data, (value) {
|
202
|
DialogUtil.showSelectCusmanTimerDialog(context, data, (value) {
|
|
204
|
setTimeCallback(value);
|
203
|
setTimeCallback(value);
|
|
205
|
- }, selecteds:hourAndMinute == null?[]: [
|
|
|
|
206
|
- _getFirSelected(hourAndMinute, data),
|
|
|
|
207
|
- _getSecSelected(hourAndMinute, data)
|
|
|
|
208
|
- ]).then((value) {
|
204
|
+ },
|
|
|
|
205
|
+ selecteds: hourAndMinute == null
|
|
|
|
206
|
+ ? []
|
|
|
|
207
|
+ : [
|
|
|
|
208
|
+ _getFirSelected(hourAndMinute, data),
|
|
|
|
209
|
+ _getSecSelected(hourAndMinute, data)
|
|
|
|
210
|
+ ])
|
|
|
|
211
|
+ .then((value) {
|
|
209
|
print(value);
|
212
|
print(value);
|
|
210
|
});
|
213
|
});
|
|
211
|
}
|
214
|
}
|