From a1097341710b486ffe722b9c0a4a810079e13d42 Mon Sep 17 00:00:00 2001 From: Sikander Saleem Date: Mon, 27 Jul 2026 09:50:30 +0300 Subject: [PATCH] cleaner add button added. --- ...request_category_fragment_housekeeper.dart | 22 ++++++++++--------- .../pages/cleaner_search_form_view.dart | 17 +++++++------- 2 files changed, 20 insertions(+), 19 deletions(-) diff --git a/lib/dashboard_latest/widgets/request_category_fragment_housekeeper.dart b/lib/dashboard_latest/widgets/request_category_fragment_housekeeper.dart index 38f1e95a..6a7fd948 100644 --- a/lib/dashboard_latest/widgets/request_category_fragment_housekeeper.dart +++ b/lib/dashboard_latest/widgets/request_category_fragment_housekeeper.dart @@ -32,6 +32,7 @@ class _RequestCategoryFragmentHouseKeeperState extends State _headerFadeAnimation; late Animation _headerSlideAnimation; final ScrollController _scrollController = ScrollController(); + // int _selectedIndex = 0; // Default first tab @override @@ -75,7 +76,6 @@ class _RequestCategoryFragmentHouseKeeperState extends State(context, listen: false); List tabs = CategoryTabs.getTabs(userType: UsersTypes.houseKeeper, context: context); @@ -122,14 +122,17 @@ class _RequestCategoryFragmentHouseKeeperState extends State_toggleSort(dashboardProvider)), - ) + 'add_icon'.toSvgAsset(width: 24, height: 24).onPress(() { + Navigator.of(context).pushNamed('/cleaner_search'); + }), + // Transform.flip( + // flipY: isAscending, + // child: 'dashboard/sort_descending'.toSvgAsset( + // width: 24, + // height: 24, + // color: AppColor.headingTextColor(context), + // ).onPress(()=>_toggleSort(dashboardProvider)), + // ) ], ).paddingOnly(start: 16, end: 16), ), @@ -237,4 +240,3 @@ class _RequestCategoryFragmentHouseKeeperState extends State { child: SingleChildScrollView( child: Column( crossAxisAlignment: CrossAxisAlignment.start, - spacing: 8, + spacing: 12, children: [ // Task Type Dropdown SingleItemDropDownMenu( @@ -204,18 +204,17 @@ class _CleanerSearchFormViewState extends State { ), // Scan QR Code Button - 8.height, GestureDetector( onTap: selectedTaskType != null ? _onScanQRCode : null, child: Container( height: 50, alignment: Alignment.center, decoration: BoxDecoration( - color: selectedTaskType != null ? Colors.white : Colors.grey[300], - borderRadius: BorderRadius.circular(10), + color: selectedTaskType != null ? AppColor.background(context) : Colors.grey[300], + borderRadius: BorderRadius.circular(16), border: Border.all( - color: selectedTaskType != null ? AppColor.blueStatus(context) : Colors.grey, - width: 2, + color: selectedTaskType != null ? AppColor.borderColor(context) : Colors.grey, + width: 1, ), ), padding: EdgeInsets.symmetric(horizontal: 16.toScreenWidth, vertical: 8.toScreenHeight), @@ -225,16 +224,16 @@ class _CleanerSearchFormViewState extends State { "scan_asset".toSvgAsset( height: 22, fit: BoxFit.fitHeight, - color: selectedTaskType != null ? (context.isDark ? AppColor.neutral20 : AppColor.neutral120) : Colors.grey, + color: selectedTaskType != null ? AppColor.icon2Color(context) : Colors.grey, ), 8.width, //we can change the implementation when merge with uiux branch _scannedLocationData == null ? "Scan QR Code".bodyText(context).custom( - color: selectedTaskType != null ? (context.isDark ? AppColor.neutral20 : AppColor.black20) : Colors.grey, + color: selectedTaskType != null ? AppColor.icon2Color(context) : Colors.grey, ) : 'Re Scan QR Code'.bodyText(context).custom( - color: selectedTaskType != null ? (context.isDark ? AppColor.neutral20 : AppColor.black20) : Colors.grey, + color: selectedTaskType != null ? AppColor.icon2Color(context) : Colors.grey, ), ], ),