添加 绿化管理 卫生管理详情页

hmxc
张萌 4 years ago
parent 02cf6543d9
commit 42b89c3f83

@ -1,6 +1,7 @@
// Flutter imports: // Flutter imports:
import 'package:aku_community_manager/const/api.dart'; import 'package:aku_community_manager/const/api.dart';
import 'package:aku_community_manager/models/manager/green_manage/green_manage_list_model.dart'; import 'package:aku_community_manager/models/manager/green_manage/green_manage_list_model.dart';
import 'package:aku_community_manager/ui/manage_pages/green_manage/green_manage_details_page.dart';
import 'package:aku_community_manager/utils/network/base_model.dart'; import 'package:aku_community_manager/utils/network/base_model.dart';
import 'package:aku_community_manager/utils/network/net_util.dart'; import 'package:aku_community_manager/utils/network/net_util.dart';
import 'package:bot_toast/bot_toast.dart'; import 'package:bot_toast/bot_toast.dart';
@ -9,6 +10,7 @@ import 'package:flutter/material.dart';
// Package imports: // Package imports:
import 'package:aku_ui/common_widgets/aku_button.dart'; import 'package:aku_ui/common_widgets/aku_button.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
import 'package:velocity_x/velocity_x.dart'; import 'package:velocity_x/velocity_x.dart';
// Project imports: // Project imports:
@ -34,7 +36,7 @@ class _GreenManageCardState extends State<GreenManageCard> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return AkuButton( return AkuButton(
onPressed: () { onPressed: () {
// Get.to(GreenManageDetailsPage(cardModel)); Get.to(GreenManageDetailsPage(widget.model));
}, },
child: Container( child: Container(
width: double.infinity, width: double.infinity,

@ -1,4 +1,5 @@
// Flutter imports: // Flutter imports:
import 'package:aku_community_manager/models/manager/green_manage/green_manage_list_model.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
// Package imports: // Package imports:
@ -7,13 +8,13 @@ import 'package:flutter_screenutil/flutter_screenutil.dart';
// Project imports: // Project imports:
import 'package:aku_community_manager/const/resource.dart'; import 'package:aku_community_manager/const/resource.dart';
import 'package:aku_community_manager/mock_models/manage_models/manage_model.dart';
import 'package:aku_community_manager/style/app_style.dart'; import 'package:aku_community_manager/style/app_style.dart';
import 'package:aku_community_manager/tools/widget_tool.dart'; import 'package:aku_community_manager/tools/widget_tool.dart';
import 'package:aku_community_manager/ui/widgets/common/aku_scaffold.dart'; import 'package:aku_community_manager/ui/widgets/common/aku_scaffold.dart';
class GreenManageDetailsPage extends StatelessWidget { class GreenManageDetailsPage extends StatelessWidget {
final GreenManageCardModel cardModel;
final GreenManageListModel cardModel;
GreenManageDetailsPage(this.cardModel); GreenManageDetailsPage(this.cardModel);
@ -43,7 +44,7 @@ class GreenManageDetailsPage extends StatelessWidget {
height: 93.w, height: 93.w,
alignment: Alignment.centerLeft, alignment: Alignment.centerLeft,
child: Text( child: Text(
cardModel.title, cardModel.greenAreaName,
style: TextStyle( style: TextStyle(
color: AppStyle.primaryTextColor, color: AppStyle.primaryTextColor,
fontSize: 32.w, fontSize: 32.w,
@ -69,7 +70,7 @@ class GreenManageDetailsPage extends StatelessWidget {
)), )),
Spacer(), Spacer(),
Text( Text(
cardModel.task, cardModel.content,
style: AppStyle().primaryStyle, style: AppStyle().primaryStyle,
), ),
], ],
@ -89,7 +90,7 @@ class GreenManageDetailsPage extends StatelessWidget {
fontSize: 28.sp)), fontSize: 28.sp)),
Spacer(), Spacer(),
Text( Text(
'${cardModel.timestart}${cardModel.timeend}', '${cardModel.createDateString}${cardModel.endDateString}',
style: AppStyle().primaryStyle, style: AppStyle().primaryStyle,
), ),
], ],
@ -110,7 +111,7 @@ class GreenManageDetailsPage extends StatelessWidget {
)), )),
Spacer(), Spacer(),
Text( Text(
cardModel.name, cardModel.directorName,
style: AppStyle().primaryStyle, style: AppStyle().primaryStyle,
), ),
], ],
@ -135,7 +136,7 @@ class GreenManageDetailsPage extends StatelessWidget {
fontWeight: FontWeight.bold)), fontWeight: FontWeight.bold)),
AkuBox.h(16), AkuBox.h(16),
Text( Text(
cardModel.body, cardModel.content,
style: TextStyle( style: TextStyle(
color: AppStyle.primaryTextColor, fontSize: 28.w), color: AppStyle.primaryTextColor, fontSize: 28.w),
), ),

@ -1,6 +1,7 @@
// Flutter imports: // Flutter imports:
import 'package:aku_community_manager/const/api.dart'; import 'package:aku_community_manager/const/api.dart';
import 'package:aku_community_manager/models/manager/hygience_manage/heygience_list_model.dart'; import 'package:aku_community_manager/models/manager/hygience_manage/heygience_list_model.dart';
import 'package:aku_community_manager/ui/manage_pages/hygience_manage/hygience_manage_detail_page.dart';
import 'package:aku_community_manager/utils/network/base_model.dart'; import 'package:aku_community_manager/utils/network/base_model.dart';
import 'package:aku_community_manager/utils/network/net_util.dart'; import 'package:aku_community_manager/utils/network/net_util.dart';
import 'package:bot_toast/bot_toast.dart'; import 'package:bot_toast/bot_toast.dart';
@ -8,6 +9,7 @@ import 'package:flutter/material.dart';
// Package imports: // Package imports:
import 'package:aku_ui/common_widgets/aku_button.dart'; import 'package:aku_ui/common_widgets/aku_button.dart';
import 'package:get/get.dart';
import 'package:velocity_x/velocity_x.dart'; import 'package:velocity_x/velocity_x.dart';
// Project imports: // Project imports:
@ -33,7 +35,7 @@ class _HyginecManageCardState extends State<HyginecManageCard> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return AkuButton( return AkuButton(
onPressed: () { onPressed: () {
// Get.to(GreenManageDetailsPage(cardModel)); Get.to(HygienceManageDetailPage(cardModel: widget.model));
}, },
child: Container( child: Container(
width: double.infinity, width: double.infinity,

@ -0,0 +1,151 @@
import 'package:aku_community_manager/models/manager/hygience_manage/heygience_list_model.dart';
import 'package:aku_community_manager/style/app_style.dart';
import 'package:aku_community_manager/tools/widget_tool.dart';
import 'package:aku_community_manager/ui/widgets/common/aku_scaffold.dart';
import 'package:aku_ui/common_widgets/aku_button.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:aku_community_manager/const/resource.dart';
class HygienceManageDetailPage extends StatefulWidget {
final HygienceListModel cardModel;
HygienceManageDetailPage({Key key, this.cardModel}) : super(key: key);
@override
_HygienceManageDetailPageState createState() =>
_HygienceManageDetailPageState();
}
class _HygienceManageDetailPageState extends State<HygienceManageDetailPage> {
HygienceListModel get cardModel => widget.cardModel;
@override
Widget build(BuildContext context) {
return AkuScaffold(
title: '详情',
body: Column(
children: [
AkuBox.h(16),
AkuButton(
onPressed: () {},
child: Container(
height: 302.w,
width: double.infinity,
padding: EdgeInsets.only(
left: 32.w,
right: 32.w,
bottom: 40.w,
),
color: Color(0xFFFFFFFF),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
height: 93.w,
alignment: Alignment.centerLeft,
child: Text(
cardModel.hygieneAreaName,
style: TextStyle(
color: AppStyle.primaryTextColor,
fontSize: 32.w,
fontWeight: FontWeight.bold),
),
),
// Divider(
// height: 1.w,
// ),
AkuBox.h(24),
Row(
children: [
Image.asset(
R.ASSETS_MANAGE_IC_RENWU_PNG,
width: 40.w,
height: 40.w,
),
AkuBox.w(4),
Text('任务概要',
style: TextStyle(
color: AppStyle.primaryTextColor,
fontSize: 28.sp,
)),
Spacer(),
Text(
cardModel.content,
style: AppStyle().primaryStyle,
),
],
),
Spacer(),
Row(
children: [
Image.asset(
R.ASSETS_MANAGE_IC_TIME_PNG,
width: 40.w,
height: 40.w,
),
AkuBox.w(4),
Text('时间期限',
style: TextStyle(
color: AppStyle.primaryTextColor,
fontSize: 28.sp)),
Spacer(),
Text(
'${cardModel.createDateString}${cardModel.endDateString}',
style: AppStyle().primaryStyle,
),
],
),
Spacer(),
Row(
children: [
Image.asset(
R.ASSETS_MESSAGE_IC_PEOPLE_PNG,
width: 40.w,
height: 40.w,
),
AkuBox.w(4),
Text('负责人员',
style: TextStyle(
color: AppStyle.primaryTextColor,
fontSize: 28.sp,
)),
Spacer(),
Text(
cardModel.directorName,
style: AppStyle().primaryStyle,
),
],
),
],
),
),
),
AkuBox.h(16),
Expanded(
child: Container(
alignment: Alignment.centerLeft,
width: double.infinity,
color: Color(0xFFFFFFFF),
padding: EdgeInsets.only(top: 16.w, left: 32.w, right: 32.w),
child: Column(
children: [
Text('详细描述',
style: TextStyle(
color: AppStyle.primaryTextColor,
fontSize: 32.w,
fontWeight: FontWeight.bold)),
AkuBox.h(16),
Text(
cardModel.content,
style: TextStyle(
color: AppStyle.primaryTextColor, fontSize: 28.w),
),
],
),
)),
],
),
);
}
}
Loading…
Cancel
Save