|
@@ -79,7 +79,15 @@ class ScheduleListState extends State<ScheduleList> {
|
|
|
customBorder: RoundedRectangleBorder(
|
|
|
borderRadius: BorderRadius.circular(5),
|
|
|
),
|
|
|
- onTap: () => print('点击了${scheduleType.typeName}'),
|
|
|
+ onTap: () {
|
|
|
+ ScaffoldMessenger.of(context).showSnackBar(
|
|
|
+ SnackBar(
|
|
|
+ backgroundColor: scheduleType.color,
|
|
|
+ duration: const Duration(milliseconds: 500),
|
|
|
+ content: Text('点击了${scheduleType.typeName}'),
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ },
|
|
|
hoverColor: const Color.fromARGB(255, 227, 228, 228),
|
|
|
child: Container(
|
|
|
height: widget.itemHeight,
|
|
@@ -122,7 +130,15 @@ class ScheduleListState extends State<ScheduleList> {
|
|
|
customBorder: RoundedRectangleBorder(
|
|
|
borderRadius: BorderRadius.circular(5),
|
|
|
),
|
|
|
- onTap: () => print('点击了更多'),
|
|
|
+ onTap: () {
|
|
|
+ /// 弹出提示
|
|
|
+ ScaffoldMessenger.of(context).showSnackBar(
|
|
|
+ const SnackBar(
|
|
|
+ duration: Duration(milliseconds: 500),
|
|
|
+ content: Text('前方正在施工'),
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ },
|
|
|
hoverColor: const Color.fromARGB(255, 227, 228, 228),
|
|
|
child: Container(
|
|
|
height: widget.itemHeight,
|