parent
dfe149b8c9
commit
032bba7c7c
@ -1,8 +1,14 @@
|
||||
|
||||
import 'package:aku_community_manager/mock_models/manage_models/green_manage_model.dart';
|
||||
import 'package:aku_community_manager/mock_models/manage_models/manage_model.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
class GreenManageProvider extends ChangeNotifier{
|
||||
List<GreenManageCardModel> _greenManageModel =GreenManageCardModel.initList();
|
||||
List<GreenManageCardModel> get greenManageModels => _greenManageModel;
|
||||
notifyListeners();
|
||||
}
|
||||
|
||||
class InspectionManageProvider extends ChangeNotifier{
|
||||
List<InspectionManageCardModel> _inspectionManageModel=InspectionManageCardModel.initList();
|
||||
List<InspectionManageCardModel> get inspectionManageModels => _inspectionManageModel;
|
||||
notifyListeners();
|
||||
}
|
@ -0,0 +1,13 @@
|
||||
import 'package:aku_community_manager/ui/widgets/common/aku_scaffold.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class InspectionManageDetailsPage extends StatelessWidget {
|
||||
const InspectionManageDetailsPage({Key key}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return AkuScaffold(
|
||||
|
||||
);
|
||||
}
|
||||
}
|
@ -0,0 +1,151 @@
|
||||
import 'package:aku_community_manager/mock_models/manage_models/manage_model.dart';
|
||||
import 'package:aku_community_manager/provider/manage_provider.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_common_widgets.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:aku_community_manager/const/resource.dart';
|
||||
|
||||
class InspectionManagePage extends StatefulWidget {
|
||||
InspectionManagePage({Key key}) : super(key: key);
|
||||
|
||||
@override
|
||||
_InspectionManagePageState createState() => _InspectionManagePageState();
|
||||
}
|
||||
|
||||
class _InspectionManagePageState extends State<InspectionManagePage> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final _inspectionManageModel =
|
||||
Provider.of<InspectionManageProvider>(context);
|
||||
return AkuScaffold(
|
||||
title: '巡检管理',
|
||||
body: ListView(
|
||||
padding: EdgeInsets.only(left: 32.w, right: 32.w),
|
||||
children: _inspectionManageModel.inspectionManageModels
|
||||
.map((e) => _inspectionManageCard(e))
|
||||
.toList(),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Widget _inspectionManageCard(InspectionManageCardModel cardModel) {
|
||||
TextStyle _textstyle =
|
||||
TextStyle(color: AppStyle.minorTextColor, fontSize: 28.sp);
|
||||
return Column(
|
||||
children: [
|
||||
AkuBox.h(16),
|
||||
AkuButton(
|
||||
onPressed: () {
|
||||
|
||||
},
|
||||
child: Container(
|
||||
alignment: Alignment.centerLeft,
|
||||
padding: EdgeInsets.only(left: 24.w, right: 24.w, bottom: 48.w),
|
||||
width: 686.w,
|
||||
height: 362.w,
|
||||
color: Color(0xFFFFFFFF),
|
||||
child: Column(children: [
|
||||
Container(
|
||||
height: 93.w,
|
||||
width: double.infinity,
|
||||
alignment: Alignment.centerLeft,
|
||||
child: Text(
|
||||
cardModel.title,
|
||||
style: TextStyle(
|
||||
color: AppStyle.primaryTextColor,
|
||||
fontSize: 32.sp,
|
||||
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,
|
||||
),
|
||||
Spacer(),
|
||||
Text(
|
||||
cardModel.date,
|
||||
style: AppStyle().primaryStyle,
|
||||
)
|
||||
],
|
||||
),
|
||||
Spacer(),
|
||||
Row(
|
||||
children: [
|
||||
Image.asset(
|
||||
R.ASSETS_HOME_IC_NEWS_PNG,
|
||||
width: 40.w,
|
||||
height: 40.w,
|
||||
),
|
||||
AkuBox.w(4),
|
||||
Text('巡检周期', style: _textstyle),
|
||||
Spacer(),
|
||||
Text(
|
||||
cardModel.cycle,
|
||||
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,
|
||||
),
|
||||
Spacer(),
|
||||
Text(
|
||||
cardModel.time,
|
||||
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,
|
||||
),
|
||||
Spacer(),
|
||||
Text(
|
||||
cardModel.persons.length > 2
|
||||
? '${cardModel.persons[0]}、${cardModel.persons[1]}等'
|
||||
: cardModel.persons[0],
|
||||
style: AppStyle().primaryStyle,
|
||||
),
|
||||
],
|
||||
),
|
||||
]),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
}
|
Loading…
Reference in new issue