You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
77 lines
2.6 KiB
77 lines
2.6 KiB
import 'package:flutter/material.dart';
|
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
|
import 'package:get/get.dart';
|
|
import 'package:tdesign_flutter/tdesign_flutter.dart';
|
|
|
|
import '../../components/page_appbar.dart';
|
|
import '../../controller/setting/notification_controller.dart';
|
|
|
|
class NoticePage extends StatelessWidget {
|
|
NoticePage({super.key});
|
|
|
|
final NotificationController controller = Get.put(NotificationController());
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Scaffold(
|
|
backgroundColor: Color(0xffF5F5F5),
|
|
appBar: PageAppbar(title: "消息通知"),
|
|
body: Expanded(
|
|
child: SingleChildScrollView(
|
|
padding: EdgeInsetsGeometry.symmetric(vertical: 16.w),
|
|
child: Obx(() {
|
|
return Column(
|
|
children: [
|
|
TDCellGroup(
|
|
theme: TDCellGroupTheme.cardTheme,
|
|
cells: [
|
|
TDCell(
|
|
arrow: true,
|
|
title: '接受推送通知',
|
|
description: controller.getPermissionStatusText(),
|
|
onClick: (cell){
|
|
controller.openSettings();
|
|
},
|
|
),
|
|
TDCell(
|
|
arrow: false,
|
|
title: '接受推送通知',
|
|
description: '一段很长很长的内容文字',
|
|
rightIconWidget: TDSwitch(
|
|
isOn: false,
|
|
trackOnColor: const Color.fromRGBO(117, 98, 249, 1),
|
|
onChanged: (bool e){
|
|
return false;
|
|
},
|
|
)
|
|
),
|
|
],
|
|
),
|
|
const SizedBox(height: 12),
|
|
TDCellGroup(
|
|
theme: TDCellGroupTheme.cardTheme,
|
|
cells: [
|
|
TDCell(
|
|
arrow: false,
|
|
title: '后台播放',
|
|
description: '一段很长很长的内容文字',
|
|
rightIconWidget: TDSwitch(
|
|
isOn: true,
|
|
trackOnColor: const Color.fromRGBO(117, 98, 249, 1),
|
|
onChanged: (bool e){
|
|
return false;
|
|
},
|
|
)
|
|
),
|
|
],
|
|
),
|
|
],
|
|
);
|
|
}),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
|
|
}
|
|
|