diff --git a/lib/mock_models/decoration/decoration_model.dart b/lib/mock_models/decoration/decoration_model.dart index 4b0738b..729584b 100644 --- a/lib/mock_models/decoration/decoration_model.dart +++ b/lib/mock_models/decoration/decoration_model.dart @@ -52,6 +52,7 @@ Map checkAssetMap = { CHECK_TYPE.DOOR_AND_WINDOWS: R.ASSETS_MANAGE_WINDOW_PNG, CHECK_TYPE.SECURITY: R.ASSETS_MANAGE_SECURITY_PNG, }; + @Deprecated('under should be removed') class DecorationModel { DecorationType type; @@ -81,7 +82,9 @@ class DecorationModel { this.checkInfomations, }); } + @Deprecated('under should be removed') + ///用户家庭信息 class UserHomeModel { String plot; @@ -95,7 +98,9 @@ class UserHomeModel { this.phone, }); } + @Deprecated('under should be removed') + ///装修队伍信息 class DecorationTeamModel { String name; @@ -107,7 +112,9 @@ class DecorationTeamModel { this.phone, }); } + @Deprecated('under should be removed') + ///周期检查 class CycleCheck { FixerModel authPerson; @@ -129,6 +136,7 @@ class CycleCheck { this.checkDetails, }); } + @Deprecated('under should be removed') class WorkFinishCheck { FixerModel authPerson; @@ -140,7 +148,9 @@ class WorkFinishCheck { this.checkDetails, }); } + @Deprecated('under should be removed') + ///周期检查细节 class CheckInfomation { DateTime checkDate; @@ -162,6 +172,7 @@ class CheckInfomation { return true; } } + @Deprecated('under should be removed') class CheckDetail { CHECK_TYPE type; diff --git a/lib/ui/home/application/applications_page.dart b/lib/ui/home/application/applications_page.dart index c28eff5..f76ca6f 100644 --- a/lib/ui/home/application/applications_page.dart +++ b/lib/ui/home/application/applications_page.dart @@ -86,7 +86,8 @@ class _ApplicationPageState extends State '包裹管理', R.ASSETS_HOME_PACKAGE_PNG, () => PackagesManagePage()), AppApplication('钥匙管理', R.ASSETS_HOME_KEY_PNG, () => KeyManagePage()), AppApplication('规程管理', R.ASSETS_HOME_RULES_PNG, () => RulesManagePage()), - AppApplication('卫生管理', R.ASSETS_PLACEHOLDER_WEBP, () => HygienceManagePage()) + AppApplication( + '卫生管理', R.ASSETS_PLACEHOLDER_WEBP, () => HygienceManagePage()) ]; @override diff --git a/lib/ui/manage_pages/green_manage/green_manage_card.dart b/lib/ui/manage_pages/green_manage/green_manage_card.dart index caaa565..07f42f6 100644 --- a/lib/ui/manage_pages/green_manage/green_manage_card.dart +++ b/lib/ui/manage_pages/green_manage/green_manage_card.dart @@ -127,7 +127,7 @@ class _GreenManageCardState extends State { ); } - List _buttomButtons() { + List _buttomButtons() { return widget.index != 0 ? [SizedBox()] : [ diff --git a/lib/ui/manage_pages/green_manage/green_manage_page.dart b/lib/ui/manage_pages/green_manage/green_manage_page.dart index 75e16fa..83da589 100644 --- a/lib/ui/manage_pages/green_manage/green_manage_page.dart +++ b/lib/ui/manage_pages/green_manage/green_manage_page.dart @@ -17,29 +17,39 @@ class GreenManagePage extends StatefulWidget { _GreenManagePageState createState() => _GreenManagePageState(); } -class _GreenManagePageState extends State with TickerProviderStateMixin { - List _tabs=['待处理','未完成','已完成']; +class _GreenManagePageState extends State + with TickerProviderStateMixin { + List _tabs = ['待处理', '未完成', '已完成']; TabController _tabController; @override - void initState() { + void initState() { super.initState(); - _tabController=TabController(length: _tabs.length, vsync: this); + _tabController = TabController(length: _tabs.length, vsync: this); } @override - void dispose() { + void dispose() { _tabController.dispose(); super.dispose(); } + @override Widget build(BuildContext context) { return AkuScaffold( title: '绿化管理', - appBarBottom: PreferredSize(preferredSize: Size.fromHeight(88.w), child: AkuTabBar(controller: _tabController, tabs: _tabs)), - body: TabBarView(controller: _tabController, children: List.generate(_tabs.length, (index) => GreenManageView( - index:index, - ),),), + appBarBottom: PreferredSize( + preferredSize: Size.fromHeight(88.w), + child: AkuTabBar(controller: _tabController, tabs: _tabs)), + body: TabBarView( + controller: _tabController, + children: List.generate( + _tabs.length, + (index) => GreenManageView( + index: index, + ), + ), + ), ); } } diff --git a/lib/ui/manage_pages/green_manage/green_manage_view.dart b/lib/ui/manage_pages/green_manage/green_manage_view.dart index 16b4071..0f48590 100644 --- a/lib/ui/manage_pages/green_manage/green_manage_view.dart +++ b/lib/ui/manage_pages/green_manage/green_manage_view.dart @@ -16,7 +16,11 @@ class _GreenManageViewState extends State { @override Widget build(BuildContext context) { return ListView( - children: [GreenManageCard(index: widget.index,)], + children: [ + GreenManageCard( + index: widget.index, + ) + ], ); } } diff --git a/lib/ui/manage_pages/hygience_manage/hygience_manage_view.dart b/lib/ui/manage_pages/hygience_manage/hygience_manage_view.dart index 06a0256..397f1c1 100644 --- a/lib/ui/manage_pages/hygience_manage/hygience_manage_view.dart +++ b/lib/ui/manage_pages/hygience_manage/hygience_manage_view.dart @@ -17,7 +17,9 @@ class _HygienceManageViewState extends State { Widget build(BuildContext context) { return ListView( children: [ - HyginecManageCard(index: widget.index,) + HyginecManageCard( + index: widget.index, + ) ], ); } diff --git a/lib/ui/sub_pages/decoration_manager/decoration_manager_card.dart b/lib/ui/sub_pages/decoration_manager/decoration_manager_card.dart index fe49614..650ec88 100644 --- a/lib/ui/sub_pages/decoration_manager/decoration_manager_card.dart +++ b/lib/ui/sub_pages/decoration_manager/decoration_manager_card.dart @@ -84,7 +84,8 @@ class _DecorationManagerCardState extends State { alignment: Alignment.centerRight, child: AkuMaterialButton( onPressed: () { - Get.to(DecorationManagerDetailPage(decorationModel: widget.model)); + Get.to( + DecorationManagerDetailPage(decorationModel: widget.model)); }, height: 64.w, minWidth: 160.w, diff --git a/lib/ui/sub_pages/decoration_manager/decoration_manager_detail_page.dart b/lib/ui/sub_pages/decoration_manager/decoration_manager_detail_page.dart index 9527b81..a51b363 100644 --- a/lib/ui/sub_pages/decoration_manager/decoration_manager_detail_page.dart +++ b/lib/ui/sub_pages/decoration_manager/decoration_manager_detail_page.dart @@ -48,7 +48,7 @@ class _DecorationManagerDetailStatePage padding: EdgeInsets.symmetric(vertical: 16.w), children: [ _buildInfo(), - widget.decorationModel.status>3 + widget.decorationModel.status > 3 ? SizedBox() : _buildFinishWorkCheck(), _buildCycleCheck(), @@ -61,11 +61,7 @@ class _DecorationManagerDetailStatePage if (UserTool.userProvider.infoModel.canOperation) { switch (widget.decorationModel.operationStatus) { case 1: - return AkuBottomButton( - title: '立即安排', - onTap:() { - } - ); + return AkuBottomButton(title: '立即安排', onTap: () {}); break; default: return SizedBox(); @@ -111,7 +107,7 @@ class _DecorationManagerDetailStatePage phone: UserTool.userProvider.profileModel.tel, rightTopWidget: Transform.rotate( angle: pi / 4, - child: widget.decorationModel.operationStatus==3 + child: widget.decorationModel.operationStatus == 3 ? Image.asset(R.ASSETS_MANAGE_IC_WANCHENG_PNG) : Image.asset(R.ASSETS_MANAGE_IC_ZHUANGXIU_PNG), ), @@ -244,7 +240,8 @@ class _DecorationManagerDetailStatePage ], ); } -///完工检查 + + ///完工检查 _buildFinishWorkCheck() { return AkuTitleBox( title: '完工检查', @@ -293,7 +290,8 @@ class _DecorationManagerDetailStatePage ], ); } -///周期检查 + + ///周期检查 _buildCycleCheck() { return AkuTitleBox( title: '周期检查', @@ -362,9 +360,7 @@ class _DecorationManagerDetailStatePage Container( height: 500.w, child: CupertinoDatePicker( - onDateTimeChanged: (dateTime) { - - }, + onDateTimeChanged: (dateTime) {}, ), ), ], @@ -453,7 +449,6 @@ class _DecorationManagerDetailStatePage realValue = 30; break; } - }, ), ), @@ -485,15 +480,14 @@ class _DecorationManagerDetailStatePage CHECK_TYPE.DOOR_AND_WINDOWS, CHECK_TYPE.SECURITY, ], - onChange: (details) { - - }, + onChange: (details) {}, canTap: UserTool.userProvider.infoModel.canOperation, ) ], ); } -///执行信息 + + ///执行信息 _buildCheckDetail() { return AkuTitleBox( title: '执行信息', @@ -530,7 +524,7 @@ class _DecorationManagerDetailStatePage ), Spacer(), Text( - 3>2? '正常' : '异常', + 3 > 2 ? '正常' : '异常', style: TextStyle( color: e.checkAllResult ? Color(0xFF32B814)