From 4d5b71e84fdaefa819f04b7dab934fae9749139e Mon Sep 17 00:00:00 2001 From: FlutterFlow <140657486+FlutterFlowEng@users.noreply.github.com> Date: Thu, 13 Jun 2024 11:26:11 +0000 Subject: [PATCH] update drawer and onPeopleInThePropertyWidget --- ios/Runner.xcodeproj/project.pbxproj | 8 +- lib/actions/actions.dart | 2 +- lib/backend/schema/structs/action_struct.dart | 2 + lib/backend/schema/structs/device_struct.dart | 3 + .../view_visit_detail_widget.dart | 2 +- ...earch_modal_template_component_widget.dart | 3 + lib/flutter_flow/flutter_flow_data_table.dart | 341 ----- lib/flutter_flow/internationalization.dart | 8 - lib/flutter_flow/nav/serialization_util.dart | 36 +- lib/main.dart | 1 + lib/pages/home_page/home_page_widget.dart | 1251 +++++++++-------- .../people_on_the_property_page_model.dart | 4 - .../people_on_the_property_page_widget.dart | 232 +-- .../schedule_complete_visit_page_widget.dart | 16 +- ...chedule_provisional_visit_page_widget.dart | 6 + pubspec.yaml | 1 - web/index.html | 1 + 17 files changed, 763 insertions(+), 1154 deletions(-) delete mode 100644 lib/flutter_flow/flutter_flow_data_table.dart diff --git a/ios/Runner.xcodeproj/project.pbxproj b/ios/Runner.xcodeproj/project.pbxproj index 2a832a1e..0f5facb7 100644 --- a/ios/Runner.xcodeproj/project.pbxproj +++ b/ios/Runner.xcodeproj/project.pbxproj @@ -44,8 +44,8 @@ 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; - 6436409A27A31CDE00820AF7 /* pt */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pt; path = pt.lproj/InfoPlist.strings; sourceTree = ""; }; - 6436409E27A31CD600820AF7 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; + 6436409E27A31CD500820AF7 /* pt */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pt; path = pt.lproj/InfoPlist.strings; sourceTree = ""; }; + 6436409527A31CD900820AF7 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; /* End PBXFileReference section */ @@ -225,8 +225,8 @@ 6436409C27A31CD800820AF7 /* InfoPlist.strings */ = { isa = PBXVariantGroup; children = ( - 6436409A27A31CDE00820AF7 /* pt */, - 6436409E27A31CD600820AF7 /* en */, + 6436409E27A31CD500820AF7 /* pt */, + 6436409527A31CD900820AF7 /* en */, ); name = InfoPlist.strings; sourceTree = ""; diff --git a/lib/actions/actions.dart b/lib/actions/actions.dart index 0c391a94..25b9688f 100644 --- a/lib/actions/actions.dart +++ b/lib/actions/actions.dart @@ -51,7 +51,7 @@ Future repeatVisitScheduleAction( 'visitorJsonList': serializeParam( visitorJsonList, ParamType.JSON, - true, + isList: true, ), }.withoutNulls, extra: { diff --git a/lib/backend/schema/structs/action_struct.dart b/lib/backend/schema/structs/action_struct.dart index 8bdb04c8..9d004d21 100644 --- a/lib/backend/schema/structs/action_struct.dart +++ b/lib/backend/schema/structs/action_struct.dart @@ -16,12 +16,14 @@ class ActionStruct extends BaseStruct { String? _title; String get title => _title ?? ''; set title(String? val) => _title = val; + bool hasTitle() => _title != null; // "icon" field. String? _icon; String get icon => _icon ?? ''; set icon(String? val) => _icon = val; + bool hasIcon() => _icon != null; static ActionStruct fromMap(Map data) => ActionStruct( diff --git a/lib/backend/schema/structs/device_struct.dart b/lib/backend/schema/structs/device_struct.dart index 03db22f3..bf1d6bf9 100644 --- a/lib/backend/schema/structs/device_struct.dart +++ b/lib/backend/schema/structs/device_struct.dart @@ -18,18 +18,21 @@ class DeviceStruct extends BaseStruct { String? _devUUID; String get devUUID => _devUUID ?? ''; set devUUID(String? val) => _devUUID = val; + bool hasDevUUID() => _devUUID != null; // "version" field. String? _version; String get version => _version ?? ''; set version(String? val) => _version = val; + bool hasVersion() => _version != null; // "description" field. String? _description; String get description => _description ?? ''; set description(String? val) => _description = val; + bool hasDescription() => _description != null; static DeviceStruct fromMap(Map data) => DeviceStruct( diff --git a/lib/components/organism_components/view_visit_detail/view_visit_detail_widget.dart b/lib/components/organism_components/view_visit_detail/view_visit_detail_widget.dart index 1971cd09..a77958db 100644 --- a/lib/components/organism_components/view_visit_detail/view_visit_detail_widget.dart +++ b/lib/components/organism_components/view_visit_detail/view_visit_detail_widget.dart @@ -890,7 +890,7 @@ class _ViewVisitDetailWidgetState extends State { 'visitorJsonList': serializeParam( widget.visitorJsonList, ParamType.JSON, - true, + isList: true, ), }.withoutNulls, ); diff --git a/lib/components/templates_components/visitor_search_modal_template_component/visitor_search_modal_template_component_widget.dart b/lib/components/templates_components/visitor_search_modal_template_component/visitor_search_modal_template_component_widget.dart index 69126439..635571cd 100644 --- a/lib/components/templates_components/visitor_search_modal_template_component/visitor_search_modal_template_component_widget.dart +++ b/lib/components/templates_components/visitor_search_modal_template_component/visitor_search_modal_template_component_widget.dart @@ -95,6 +95,9 @@ class _VisitorSearchModalTemplateComponentWidgetState _model.textController.text, '69696777', ); + _model.textController?.selection = + TextSelection.collapsed( + offset: _model.textController!.text.length); }); _model.getVisitorByDoc = await PhpGroup.getVisitorByDocCall.call( diff --git a/lib/flutter_flow/flutter_flow_data_table.dart b/lib/flutter_flow/flutter_flow_data_table.dart deleted file mode 100644 index 55272241..00000000 --- a/lib/flutter_flow/flutter_flow_data_table.dart +++ /dev/null @@ -1,341 +0,0 @@ -import 'dart:math' as math; - -import 'package:data_table_2/data_table_2.dart'; -import 'package:flutter/material.dart'; - -export 'package:data_table_2/data_table_2.dart' show DataColumn2; - -const _kDataTableHorizontalMargin = 48.0; -const kDefaultColumnSpacing = 56.0; -const _kMinRowsPerPage = 5; - -typedef ColumnsBuilder = List Function(void Function(int, bool)); -typedef DataRowBuilder = DataRow? Function( - T, int, bool, void Function(bool?)?); - -class FlutterFlowDataTableController extends DataTableSource { - FlutterFlowDataTableController({ - List? initialData, - int? numRows, - PaginatorController? paginatorController, - bool selectable = false, - }) { - data = initialData?.toList() ?? []; - numRows = numRows; - this.paginatorController = paginatorController ?? PaginatorController(); - _selectable = selectable; - } - - DataRowBuilder? _dataRowBuilder; - late PaginatorController paginatorController; - List data = []; - int? _numRows; - List get selectedData => - selectedRows.where((i) => i < data.length).map(data.elementAt).toList(); - - bool _selectable = false; - final Set selectedRows = {}; - - int rowsPerPage = defaultRowsPerPage; - int? sortColumnIndex; - bool sortAscending = true; - - void init({ - DataRowBuilder? dataRowBuilder, - bool? selectable, - List? initialData, - int? initialNumRows, - }) { - _dataRowBuilder = dataRowBuilder ?? _dataRowBuilder; - _selectable = selectable ?? _selectable; - data = initialData?.toList() ?? data; - _numRows = initialNumRows; - } - - void updateData({ - List? data, - int? numRows, - bool notify = true, - }) { - this.data = data?.toList() ?? this.data; - _numRows = numRows ?? _numRows; - if (notify) { - notifyListeners(); - } - } - - void updateSort({ - required int columnIndex, - required bool ascending, - Function(int, bool)? onSortChanged, - }) { - sortColumnIndex = columnIndex; - sortAscending = ascending; - if (onSortChanged != null) { - onSortChanged(columnIndex, ascending); - } - notifyListeners(); - } - - @override - DataRow? getRow(int index) { - final row = data.elementAtOrNull(index); - return _dataRowBuilder != null && row != null - ? _dataRowBuilder!( - row, - index, - selectedRows.contains(index), - _selectable - ? (selected) { - if (selected == null) { - return; - } - selected - ? selectedRows.add(index) - : selectedRows.remove(index); - notifyListeners(); - } - : null, - ) - : null; - } - - @override - bool get isRowCountApproximate => false; - - @override - int get rowCount => _numRows ?? data.length; - - @override - int get selectedRowCount => selectedRows.length; -} - -class FlutterFlowDataTable extends StatefulWidget { - const FlutterFlowDataTable({ - super.key, - required this.controller, - required this.data, - this.numRows, - required this.columnsBuilder, - required this.dataRowBuilder, - this.emptyBuilder, - this.onPageChanged, - this.onSortChanged, - this.onRowsPerPageChanged, - this.paginated = true, - this.selectable = false, - this.hidePaginator = false, - this.showFirstLastButtons = false, - this.width, - this.height, - this.minWidth, - this.headingRowHeight = 56, - this.dataRowHeight = kMinInteractiveDimension, - this.columnSpacing = kDefaultColumnSpacing, - this.headingRowColor, - this.sortIconColor, - this.borderRadius, - this.addHorizontalDivider = true, - this.addTopAndBottomDivider = false, - this.hideDefaultHorizontalDivider = false, - this.addVerticalDivider = false, - this.horizontalDividerColor, - this.horizontalDividerThickness, - this.verticalDividerColor, - this.verticalDividerThickness, - this.checkboxUnselectedFillColor, - this.checkboxSelectedFillColor, - this.checkboxUnselectedBorderColor, - this.checkboxSelectedBorderColor, - this.checkboxCheckColor, - }); - - final FlutterFlowDataTableController controller; - final List data; - final int? numRows; - final ColumnsBuilder columnsBuilder; - final DataRowBuilder dataRowBuilder; - final Widget? Function()? emptyBuilder; - // Callback functions - final Function(int)? onPageChanged; - final Function(int, bool)? onSortChanged; - final Function(int)? onRowsPerPageChanged; - // Functionality options - final bool paginated; - final bool selectable; - final bool showFirstLastButtons; - final bool hidePaginator; - // Size and shape options - final double? width; - final double? height; - final double? minWidth; - final double headingRowHeight; - final double dataRowHeight; - final double columnSpacing; - // Table style options - final Color? headingRowColor; - final Color? sortIconColor; - final BorderRadius? borderRadius; - final bool addHorizontalDivider; - final bool addTopAndBottomDivider; - final bool hideDefaultHorizontalDivider; - final Color? horizontalDividerColor; - final double? horizontalDividerThickness; - final bool addVerticalDivider; - final Color? verticalDividerColor; - final double? verticalDividerThickness; - // Checkbox style options - final Color? checkboxUnselectedFillColor; - final Color? checkboxSelectedFillColor; - final Color? checkboxUnselectedBorderColor; - final Color? checkboxSelectedBorderColor; - final Color? checkboxCheckColor; - - @override - State> createState() => - _FlutterFlowDataTableState(); -} - -class _FlutterFlowDataTableState extends State> { - FlutterFlowDataTableController get controller => widget.controller; - int get rowCount => controller.rowCount; - - int get initialRowsPerPage => - rowCount > _kMinRowsPerPage ? defaultRowsPerPage : _kMinRowsPerPage; - - @override - void initState() { - super.initState(); - dataTableShowLogs = false; // Disables noisy DataTable2 debug statements. - controller.init( - dataRowBuilder: widget.dataRowBuilder, - selectable: widget.selectable, - initialData: widget.data, - initialNumRows: widget.numRows, - ); - // ignore: cascade_invocations - controller.addListener(() => setState(() {})); - } - - @override - void didUpdateWidget(FlutterFlowDataTable oldWidget) { - super.didUpdateWidget(oldWidget); - controller.updateData( - data: widget.data, - numRows: widget.numRows, - notify: true, - ); - } - - @override - Widget build(BuildContext context) { - final columns = widget.columnsBuilder( - (index, ascending) { - controller.updateSort( - columnIndex: index, - ascending: ascending, - onSortChanged: widget.onSortChanged, - ); - setState(() {}); - }, - ); - - final checkboxThemeData = CheckboxThemeData( - checkColor: MaterialStateProperty.all( - widget.checkboxCheckColor ?? Colors.black54, - ), - fillColor: MaterialStateProperty.resolveWith( - (states) => states.contains(MaterialState.selected) - ? widget.checkboxSelectedFillColor ?? Colors.white.withOpacity(0.01) - : widget.checkboxUnselectedFillColor ?? - Colors.white.withOpacity(0.01), - ), - side: MaterialStateBorderSide.resolveWith( - (states) => BorderSide( - width: 2.0, - color: states.contains(MaterialState.selected) - ? widget.checkboxSelectedBorderColor ?? Colors.black54 - : widget.checkboxUnselectedBorderColor ?? Colors.black54, - ), - ), - overlayColor: MaterialStateProperty.all(Colors.transparent), - ); - - final horizontalBorder = widget.addHorizontalDivider - ? BorderSide( - color: widget.horizontalDividerColor ?? Colors.transparent, - width: widget.horizontalDividerThickness ?? 1.0, - ) - : BorderSide.none; - - return ClipRRect( - borderRadius: widget.borderRadius ?? BorderRadius.zero, - child: SizedBox( - width: widget.width, - height: widget.height, - child: Theme( - data: Theme.of(context).copyWith( - iconTheme: widget.sortIconColor != null - ? IconThemeData(color: widget.sortIconColor) - : null, - ), - child: PaginatedDataTable2( - source: controller, - controller: - widget.paginated ? controller.paginatorController : null, - rowsPerPage: widget.paginated ? initialRowsPerPage : rowCount, - availableRowsPerPage: const [5, 10, 25, 50, 100], - onPageChanged: widget.onPageChanged != null - ? (index) => widget.onPageChanged!(index) - : null, - columnSpacing: widget.columnSpacing, - onRowsPerPageChanged: widget.paginated - ? (value) { - controller.rowsPerPage = value ?? initialRowsPerPage; - if (widget.onRowsPerPageChanged != null) { - widget.onRowsPerPageChanged!(controller.rowsPerPage); - } - } - : null, - columns: columns, - empty: widget.emptyBuilder != null ? widget.emptyBuilder!() : null, - sortColumnIndex: controller.sortColumnIndex, - sortAscending: controller.sortAscending, - showCheckboxColumn: widget.selectable, - datarowCheckboxTheme: checkboxThemeData, - headingCheckboxTheme: checkboxThemeData, - hidePaginator: !widget.paginated || widget.hidePaginator, - wrapInCard: false, - renderEmptyRowsInTheEnd: false, - border: TableBorder( - horizontalInside: horizontalBorder, - verticalInside: widget.addVerticalDivider - ? BorderSide( - color: widget.verticalDividerColor ?? Colors.transparent, - width: widget.verticalDividerThickness ?? 1.0, - ) - : BorderSide.none, - bottom: widget.addTopAndBottomDivider - ? horizontalBorder - : BorderSide.none, - ), - dividerThickness: widget.hideDefaultHorizontalDivider ? 0.0 : null, - headingRowColor: MaterialStateProperty.all(widget.headingRowColor), - headingRowHeight: widget.headingRowHeight, - dataRowHeight: widget.dataRowHeight, - showFirstLastButtons: widget.showFirstLastButtons, - minWidth: math.max(widget.minWidth ?? 0, _getColumnsWidth(columns)), - ), - ), - ), - ); - } - - // Return the total fixed width of all columns that have a specified width, - // plus one to make the data table scrollable if there is insufficient space. - double _getColumnsWidth(List columns) => - columns.where((c) => c is DataColumn2 && c.fixedWidth != null).fold( - ((widget.selectable ? 2 : 1) * _kDataTableHorizontalMargin) + 1, - (sum, col) => sum + (col as DataColumn2).fixedWidth!, - ); -} diff --git a/lib/flutter_flow/internationalization.dart b/lib/flutter_flow/internationalization.dart index f6d595a6..abc4ca05 100644 --- a/lib/flutter_flow/internationalization.dart +++ b/lib/flutter_flow/internationalization.dart @@ -562,14 +562,6 @@ final kTranslationsMap = >>[ }, // peopleOnThePropertyPage { - 'omjuk919': { - 'pt': 'Foto', - 'en': 'Photo', - }, - 'fli7tpz6': { - 'pt': 'Nome', - 'en': 'Name', - }, 'nsu13r5d': { 'pt': 'Pessoas na Propriedade', 'en': 'People on the Property', diff --git a/lib/flutter_flow/nav/serialization_util.dart b/lib/flutter_flow/nav/serialization_util.dart index 1de6e7b5..6b818a9c 100644 --- a/lib/flutter_flow/nav/serialization_util.dart +++ b/lib/flutter_flow/nav/serialization_util.dart @@ -32,54 +32,56 @@ String uploadedFileToString(FFUploadedFile uploadedFile) => String? serializeParam( dynamic param, - ParamType paramType, [ + ParamType paramType, { bool isList = false, -]) { +}) { try { if (param == null) { return null; } if (isList) { final serializedValues = (param as Iterable) - .map((p) => serializeParam(p, paramType, false)) + .map((p) => serializeParam(p, paramType, isList: false)) .where((p) => p != null) .map((p) => p!) .toList(); return json.encode(serializedValues); } + String? data; switch (paramType) { case ParamType.int: - return param.toString(); + data = param.toString(); case ParamType.double: - return param.toString(); + data = param.toString(); case ParamType.String: - return param; + data = param; case ParamType.bool: - return param ? 'true' : 'false'; + data = param ? 'true' : 'false'; case ParamType.DateTime: - return (param as DateTime).millisecondsSinceEpoch.toString(); + data = (param as DateTime).millisecondsSinceEpoch.toString(); case ParamType.DateTimeRange: - return dateTimeRangeToString(param as DateTimeRange); + data = dateTimeRangeToString(param as DateTimeRange); case ParamType.LatLng: - return (param as LatLng).serialize(); + data = (param as LatLng).serialize(); case ParamType.Color: - return (param as Color).toCssString(); + data = (param as Color).toCssString(); case ParamType.FFPlace: - return placeToString(param as FFPlace); + data = placeToString(param as FFPlace); case ParamType.FFUploadedFile: - return uploadedFileToString(param as FFUploadedFile); + data = uploadedFileToString(param as FFUploadedFile); case ParamType.JSON: - return json.encode(param); + data = json.encode(param); case ParamType.DataStruct: - return param is BaseStruct ? param.serialize() : null; + data = param is BaseStruct ? param.serialize() : null; case ParamType.Enum: - return (param is Enum) ? param.serialize() : null; + data = (param is Enum) ? param.serialize() : null; default: - return null; + data = null; } + return data; } catch (e) { print('Error serializing parameter: $e'); return null; diff --git a/lib/main.dart b/lib/main.dart index 9431af7c..8fc380a0 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -38,6 +38,7 @@ class MyApp extends StatefulWidget { class _MyAppState extends State { Locale? _locale = FFLocalizations.getStoredLocale(); + ThemeMode _themeMode = FlutterFlowTheme.themeMode; late AppStateNotifier _appStateNotifier; diff --git a/lib/pages/home_page/home_page_widget.dart b/lib/pages/home_page/home_page_widget.dart index bc0ff455..d4f33260 100644 --- a/lib/pages/home_page/home_page_widget.dart +++ b/lib/pages/home_page/home_page_widget.dart @@ -88,12 +88,11 @@ class _HomePageWidgetState extends State { ), child: Column( mainAxisSize: MainAxisSize.max, - crossAxisAlignment: CrossAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.center, children: [ Container( - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context).primary, - borderRadius: const BorderRadius.only( + decoration: const BoxDecoration( + borderRadius: BorderRadius.only( bottomLeft: Radius.circular(5.0), bottomRight: Radius.circular(5.0), topLeft: Radius.circular(0.0), @@ -101,22 +100,21 @@ class _HomePageWidgetState extends State { ), shape: BoxShape.rectangle, ), - child: Row( + child: Column( mainAxisSize: MainAxisSize.max, children: [ - Expanded( - child: Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 30.0, 0.0, 0.0), - child: Container( - width: 100.0, - height: 100.0, - decoration: const BoxDecoration(), - child: Padding( - padding: const EdgeInsets.all(12.0), + Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: MainAxisAlignment.spaceBetween, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Flexible( + child: Container( + width: double.infinity, + decoration: const BoxDecoration(), child: Row( mainAxisSize: MainAxisSize.min, - mainAxisAlignment: MainAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.start, children: [ Container( width: 50.0, @@ -133,73 +131,83 @@ class _HomePageWidgetState extends State { fit: BoxFit.cover, ), ), - Align( - alignment: const AlignmentDirectional(0.0, 0.0), - child: Container( - decoration: const BoxDecoration(), - child: Row( - mainAxisSize: MainAxisSize.max, - children: [ - Padding( - padding: const EdgeInsetsDirectional - .fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - 'lyiat6s2' /* NOME DO MORADOR */, - ), - style: FlutterFlowTheme.of( - context) - .bodyLarge - .override( - fontFamily: 'Nunito Sans', - color: - FlutterFlowTheme.of( - context) - .info, - letterSpacing: 0.0, - fontWeight: - FontWeight.normal, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito Sans'), - ), + Flexible( + child: Row( + mainAxisSize: MainAxisSize.max, + children: [ + Container( + decoration: const BoxDecoration(), + child: Text( + FFLocalizations.of(context) + .getText( + 'lyiat6s2' /* NOME DO MORADOR */, ), + style: FlutterFlowTheme.of( + context) + .bodyLarge + .override( + fontFamily: 'Nunito Sans', + color: FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 14.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.normal, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito Sans'), + ), ), - ], - ), + ), + ].divide(const SizedBox(width: 20.0)), ), ), - ], + ] + .divide(const SizedBox(width: 10.0)) + .addToStart(const SizedBox(width: 20.0)), ), ), ), - ), - ), - Container( - width: 100.0, - height: 100.0, - decoration: const BoxDecoration(), - child: FlutterFlowIconButton( - borderRadius: 100.0, - borderWidth: 1.0, - buttonSize: 1.0, - icon: Icon( - Icons.close_sharp, - color: FlutterFlowTheme.of(context).info, - size: 24.0, + Expanded( + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: MainAxisAlignment.end, + children: [ + Flexible( + child: Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 5.9, 40.0, 0.0), + child: FlutterFlowIconButton( + borderRadius: 100.0, + borderWidth: 1.0, + buttonSize: 0.0, + icon: Icon( + Icons.close_sharp, + color: FlutterFlowTheme.of(context) + .primary, + size: 20.0, + ), + onPressed: () async { + if (scaffoldKey + .currentState!.isDrawerOpen || + scaffoldKey.currentState! + .isEndDrawerOpen) { + Navigator.pop(context); + } + }, + ), + ), + ), + ], + ), ), - onPressed: () async { - if (scaffoldKey.currentState!.isDrawerOpen || - scaffoldKey.currentState!.isEndDrawerOpen) { - Navigator.pop(context); - } - }, - ), + ] + .divide(const SizedBox(width: 0.0)) + .around(const SizedBox(width: 0.0)), ), - ], + ].addToStart(const SizedBox(height: 30.0)), ), ), Padding( @@ -219,6 +227,7 @@ class _HomePageWidgetState extends State { autofocus: false, obscureText: false, decoration: InputDecoration( + isDense: true, labelStyle: FlutterFlowTheme.of(context) .labelMedium .override( @@ -248,30 +257,30 @@ class _HomePageWidgetState extends State { borderSide: BorderSide( color: FlutterFlowTheme.of(context) .customColor1, - width: 2.0, + width: 0.5, ), - borderRadius: BorderRadius.circular(6.0), + borderRadius: BorderRadius.circular(2.0), ), focusedBorder: UnderlineInputBorder( borderSide: BorderSide( color: FlutterFlowTheme.of(context).primary, - width: 2.0, + width: 0.5, ), - borderRadius: BorderRadius.circular(6.0), + borderRadius: BorderRadius.circular(2.0), ), errorBorder: UnderlineInputBorder( borderSide: BorderSide( color: FlutterFlowTheme.of(context).error, - width: 2.0, + width: 0.5, ), - borderRadius: BorderRadius.circular(6.0), + borderRadius: BorderRadius.circular(2.0), ), focusedErrorBorder: UnderlineInputBorder( borderSide: BorderSide( color: FlutterFlowTheme.of(context).error, - width: 2.0, + width: 0.5, ), - borderRadius: BorderRadius.circular(6.0), + borderRadius: BorderRadius.circular(2.0), ), prefixIcon: const Icon( Icons.search_sharp, @@ -293,566 +302,598 @@ class _HomePageWidgetState extends State { ), ), ), - ], + ] + .addToStart(const SizedBox(width: 30.0)) + .addToEnd(const SizedBox(width: 30.0)), ), ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB(10.0, 20.0, 10.0, 0.0), - child: ListView( - padding: EdgeInsets.zero, - scrollDirection: Axis.vertical, - children: [ - Column( - mainAxisSize: MainAxisSize.max, - children: [ - Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 1.0), - child: Container( - width: double.infinity, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(24.0), - ), - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Container( - width: 40.0, - height: 40.0, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: Icon( - FFIcons.kfast, - color: FlutterFlowTheme.of(context) - .primary, - size: 24.0, - ), - ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - 'dlaeicxd' /* Auto-Visita */, - ), - style: FlutterFlowTheme.of( - context) - .titleLarge - .override( - fontFamily: 'Nunito', - color: FlutterFlowTheme.of( - context) - .primaryText, - fontSize: 15.0, - letterSpacing: 0.0, - fontWeight: FontWeight.w500, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito'), - ), + Flexible( + child: Container( + width: double.infinity, + height: double.infinity, + decoration: const BoxDecoration(), + child: Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 10.0, 20.0, 10.0, 0.0), + child: Column( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Column( + mainAxisSize: MainAxisSize.max, + children: [ + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 0.0, 0.0, 1.0), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(24.0), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Container( + width: 40.0, + height: 40.0, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: Icon( + FFIcons.kfast, + color: + FlutterFlowTheme.of(context) + .primary, + size: 20.0, ), ), - ), - Icon( - Icons.chevron_right_rounded, - color: FlutterFlowTheme.of(context) - .customColor1, - size: 24.0, - ), - ], + Expanded( + child: Padding( + padding: const EdgeInsetsDirectional + .fromSTEB( + 10.0, 0.0, 0.0, 0.0), + child: Text( + FFLocalizations.of(context) + .getText( + 'dlaeicxd' /* Auto-Visita */, + ), + style: FlutterFlowTheme.of( + context) + .titleLarge + .override( + fontFamily: 'Nunito', + color: + FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 15.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.w500, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito'), + ), + ), + ), + ), + Icon( + Icons.chevron_right_rounded, + color: FlutterFlowTheme.of(context) + .customColor1, + size: 24.0, + ), + ], + ), ), ), ), - ), - Divider( - thickness: 1.0, - color: - FlutterFlowTheme.of(context).customColor1, - ), - Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 1.0), - child: Container( - width: double.infinity, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(24.0), - ), - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Container( - width: 40.0, - height: 40.0, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: Icon( - FFIcons.khome, - color: FlutterFlowTheme.of(context) - .primary, - size: 24.0, - ), - ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - '53jd930v' /* Condominio */, - ), - style: FlutterFlowTheme.of( - context) - .titleLarge - .override( - fontFamily: 'Nunito', - color: FlutterFlowTheme.of( - context) - .primaryText, - fontSize: 15.0, - letterSpacing: 0.0, - fontWeight: FontWeight.w500, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito'), - ), + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 0.0, 0.0, 1.0), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(24.0), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Container( + width: 40.0, + height: 40.0, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: Icon( + FFIcons.khome, + color: + FlutterFlowTheme.of(context) + .primary, + size: 24.0, ), ), - ), - Icon( - Icons.chevron_right_rounded, - color: FlutterFlowTheme.of(context) - .customColor1, - size: 24.0, - ), - ], + Expanded( + child: Padding( + padding: const EdgeInsetsDirectional + .fromSTEB( + 10.0, 0.0, 0.0, 0.0), + child: Text( + FFLocalizations.of(context) + .getText( + '53jd930v' /* Condominio */, + ), + style: FlutterFlowTheme.of( + context) + .titleLarge + .override( + fontFamily: 'Nunito', + color: + FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 15.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.w500, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito'), + ), + ), + ), + ), + Icon( + Icons.chevron_right_rounded, + color: FlutterFlowTheme.of(context) + .customColor1, + size: 24.0, + ), + ], + ), ), ), ), - ), - Divider( - thickness: 1.0, - color: - FlutterFlowTheme.of(context).customColor1, - ), - Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 1.0), - child: Container( - width: double.infinity, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(24.0), - ), - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Container( - width: 40.0, - height: 40.0, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: Icon( - FFIcons.kpets, - color: FlutterFlowTheme.of(context) - .primary, - size: 24.0, - ), - ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - 'ptsx0rln' /* Cadastrar Pet */, - ), - style: FlutterFlowTheme.of( - context) - .titleLarge - .override( - fontFamily: 'Nunito', - color: FlutterFlowTheme.of( - context) - .primaryText, - fontSize: 15.0, - letterSpacing: 0.0, - fontWeight: FontWeight.w500, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito'), - ), + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 0.0, 0.0, 1.0), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(24.0), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Container( + width: 40.0, + height: 40.0, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: Icon( + FFIcons.kpets, + color: + FlutterFlowTheme.of(context) + .primary, + size: 20.0, ), ), - ), - Icon( - Icons.chevron_right_rounded, - color: FlutterFlowTheme.of(context) - .customColor1, - size: 24.0, - ), - ], + Expanded( + child: Padding( + padding: const EdgeInsetsDirectional + .fromSTEB( + 10.0, 0.0, 0.0, 0.0), + child: Text( + FFLocalizations.of(context) + .getText( + 'ptsx0rln' /* Cadastrar Pet */, + ), + style: FlutterFlowTheme.of( + context) + .titleLarge + .override( + fontFamily: 'Nunito', + color: + FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 15.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.w500, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito'), + ), + ), + ), + ), + Icon( + Icons.chevron_right_rounded, + color: FlutterFlowTheme.of(context) + .customColor1, + size: 24.0, + ), + ], + ), ), ), ), - ), - Divider( - thickness: 1.0, - color: - FlutterFlowTheme.of(context).customColor1, - ), - Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 1.0), - child: Container( - width: double.infinity, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(24.0), - ), - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Container( - width: 40.0, - height: 40.0, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: Icon( - FFIcons.kvector1, - color: FlutterFlowTheme.of(context) - .primary, - size: 24.0, - ), - ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - 'rgxgw626' /* Cadastrar Visitante */, - ), - style: FlutterFlowTheme.of( - context) - .titleLarge - .override( - fontFamily: 'Nunito', - color: FlutterFlowTheme.of( - context) - .primaryText, - fontSize: 15.0, - letterSpacing: 0.0, - fontWeight: FontWeight.w500, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito'), - ), + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 0.0, 0.0, 1.0), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(24.0), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Container( + width: 40.0, + height: 40.0, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: Icon( + FFIcons.kvector1, + color: + FlutterFlowTheme.of(context) + .primary, + size: 22.0, ), ), - ), - Icon( - Icons.chevron_right_rounded, - color: FlutterFlowTheme.of(context) - .customColor1, - size: 24.0, - ), - ], + Expanded( + child: Padding( + padding: const EdgeInsetsDirectional + .fromSTEB( + 10.0, 0.0, 0.0, 0.0), + child: Text( + FFLocalizations.of(context) + .getText( + 'rgxgw626' /* Cadastrar Visitante */, + ), + style: FlutterFlowTheme.of( + context) + .titleLarge + .override( + fontFamily: 'Nunito', + color: + FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 15.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.w500, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito'), + ), + ), + ), + ), + Icon( + Icons.chevron_right_rounded, + color: FlutterFlowTheme.of(context) + .customColor1, + size: 24.0, + ), + ], + ), ), ), ), - ), - Divider( - thickness: 1.0, - color: - FlutterFlowTheme.of(context).customColor1, - ), - Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 1.0), - child: Container( - width: double.infinity, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(24.0), - ), - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Container( - width: 40.0, - height: 40.0, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: Icon( - FFIcons.kvector2, - color: FlutterFlowTheme.of(context) - .primary, - size: 24.0, - ), - ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - 'j2tn9lpw' /* QR Code de Acesso */, - ), - style: FlutterFlowTheme.of( - context) - .titleLarge - .override( - fontFamily: 'Nunito', - color: FlutterFlowTheme.of( - context) - .primaryText, - fontSize: 15.0, - letterSpacing: 0.0, - fontWeight: FontWeight.w500, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito'), - ), + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 0.0, 0.0, 1.0), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(24.0), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Container( + width: 40.0, + height: 40.0, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: Icon( + FFIcons.kvector2, + color: + FlutterFlowTheme.of(context) + .primary, + size: 20.0, ), ), - ), - Icon( - Icons.chevron_right_rounded, - color: FlutterFlowTheme.of(context) - .customColor1, - size: 24.0, - ), - ], + Expanded( + child: Padding( + padding: const EdgeInsetsDirectional + .fromSTEB( + 10.0, 0.0, 0.0, 0.0), + child: Text( + FFLocalizations.of(context) + .getText( + 'j2tn9lpw' /* QR Code de Acesso */, + ), + style: FlutterFlowTheme.of( + context) + .titleLarge + .override( + fontFamily: 'Nunito', + color: + FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 15.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.w500, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito'), + ), + ), + ), + ), + Icon( + Icons.chevron_right_rounded, + color: FlutterFlowTheme.of(context) + .customColor1, + size: 24.0, + ), + ], + ), ), ), ), - ), - Divider( - thickness: 1.0, - color: - FlutterFlowTheme.of(context).customColor1, - ), - Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 1.0), - child: Container( - width: double.infinity, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(24.0), - ), - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Container( - width: 40.0, - height: 40.0, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: Icon( - FFIcons.kvector3, - color: FlutterFlowTheme.of(context) - .primary, - size: 24.0, - ), - ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - '9weuwgs1' /* Histórico de Acesso */, - ), - style: FlutterFlowTheme.of( - context) - .titleLarge - .override( - fontFamily: 'Nunito', - color: FlutterFlowTheme.of( - context) - .primaryText, - fontSize: 15.0, - letterSpacing: 0.0, - fontWeight: FontWeight.w500, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito'), - ), + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 0.0, 0.0, 1.0), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(24.0), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Container( + width: 40.0, + height: 40.0, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: Icon( + FFIcons.kvector3, + color: + FlutterFlowTheme.of(context) + .primary, + size: 20.0, ), ), - ), - Icon( - Icons.chevron_right_rounded, - color: FlutterFlowTheme.of(context) - .customColor1, - size: 24.0, - ), - ], + Expanded( + child: Padding( + padding: const EdgeInsetsDirectional + .fromSTEB( + 10.0, 0.0, 0.0, 0.0), + child: Text( + FFLocalizations.of(context) + .getText( + '9weuwgs1' /* Histórico de Acesso */, + ), + style: FlutterFlowTheme.of( + context) + .titleLarge + .override( + fontFamily: 'Nunito', + color: + FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 15.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.w500, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito'), + ), + ), + ), + ), + Icon( + Icons.chevron_right_rounded, + color: FlutterFlowTheme.of(context) + .customColor1, + size: 24.0, + ), + ], + ), ), ), ), - ), - Divider( - thickness: 1.0, - color: - FlutterFlowTheme.of(context).customColor1, - ), - Padding( - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 1.0), - child: Container( - width: double.infinity, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(24.0), - ), - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Container( - width: 40.0, - height: 40.0, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: Icon( - FFIcons.kvector1, - color: FlutterFlowTheme.of(context) - .primary, - size: 24.0, - ), - ), - Expanded( - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB( - 10.0, 0.0, 0.0, 0.0), - child: Text( - FFLocalizations.of(context) - .getText( - 'vuk5bjau' /* Agendar Visita */, - ), - style: FlutterFlowTheme.of( - context) - .titleLarge - .override( - fontFamily: 'Nunito', - color: FlutterFlowTheme.of( - context) - .primaryText, - fontSize: 15.0, - letterSpacing: 0.0, - fontWeight: FontWeight.w500, - useGoogleFonts: - GoogleFonts.asMap() - .containsKey( - 'Nunito'), - ), + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + Padding( + padding: const EdgeInsetsDirectional.fromSTEB( + 0.0, 0.0, 0.0, 1.0), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(24.0), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Container( + width: 40.0, + height: 40.0, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: Icon( + FFIcons.kvector1, + color: + FlutterFlowTheme.of(context) + .primary, + size: 20.0, ), ), - ), - Icon( - Icons.chevron_right_rounded, - color: FlutterFlowTheme.of(context) - .customColor1, - size: 24.0, - ), - ], + Expanded( + child: Padding( + padding: const EdgeInsetsDirectional + .fromSTEB( + 10.0, 0.0, 0.0, 0.0), + child: Text( + FFLocalizations.of(context) + .getText( + 'vuk5bjau' /* Agendar Visita */, + ), + style: FlutterFlowTheme.of( + context) + .titleLarge + .override( + fontFamily: 'Nunito', + color: + FlutterFlowTheme.of( + context) + .primaryText, + fontSize: 15.0, + letterSpacing: 0.0, + fontWeight: + FontWeight.w500, + useGoogleFonts: + GoogleFonts.asMap() + .containsKey( + 'Nunito'), + ), + ), + ), + ), + Icon( + Icons.chevron_right_rounded, + color: FlutterFlowTheme.of(context) + .customColor1, + size: 24.0, + ), + ], + ), ), ), ), - ), - ], - ), - ], + Divider( + thickness: 0.1, + color: + FlutterFlowTheme.of(context).customColor1, + ), + ], + ), + ], + ), ), ), ), - Align( - alignment: const AlignmentDirectional(0.0, 1.0), - child: Padding( - padding: - const EdgeInsetsDirectional.fromSTEB(16.0, 12.0, 0.0, 0.0), - child: FFButtonWidget( - onPressed: () async { - FFAppState().isLogged = false; - setState(() {}); + FFButtonWidget( + onPressed: () async { + FFAppState().isLogged = false; + setState(() {}); - context.goNamed( - 'onBoardingPage', - extra: { - kTransitionInfoKey: const TransitionInfo( - hasTransition: true, - transitionType: PageTransitionType.scale, - alignment: Alignment.bottomCenter, - ), - }, - ); + context.goNamed( + 'onBoardingPage', + extra: { + kTransitionInfoKey: const TransitionInfo( + hasTransition: true, + transitionType: PageTransitionType.scale, + alignment: Alignment.bottomCenter, + ), }, - text: FFLocalizations.of(context).getText( - 'xx0db4wi' /* Sair */, - ), - options: FFButtonOptions( - height: 40.0, - padding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 0.0), - iconPadding: const EdgeInsetsDirectional.fromSTEB( - 0.0, 0.0, 0.0, 0.0), - color: const Color(0x00D70000), - textStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( + ); + }, + text: FFLocalizations.of(context).getText( + 'xx0db4wi' /* Sair */, + ), + options: FFButtonOptions( + height: 40.0, + padding: + const EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 0.0), + iconPadding: + const EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 0.0), + color: const Color(0x00D70000), + textStyle: + FlutterFlowTheme.of(context).labelMedium.override( fontFamily: 'Plus Jakarta Sans', color: FlutterFlowTheme.of(context).primaryText, fontSize: 14.0, @@ -861,13 +902,11 @@ class _HomePageWidgetState extends State { useGoogleFonts: GoogleFonts.asMap() .containsKey('Plus Jakarta Sans'), ), - elevation: 0.0, - borderSide: const BorderSide( - width: 0.0, - ), - borderRadius: BorderRadius.circular(50.0), - ), + elevation: 0.0, + borderSide: const BorderSide( + width: 0.0, ), + borderRadius: BorderRadius.circular(50.0), ), ), ].addToEnd(const SizedBox(height: 64.0)), diff --git a/lib/pages/people_on_the_property_page/people_on_the_property_page_model.dart b/lib/pages/people_on_the_property_page/people_on_the_property_page_model.dart index 28f33c72..31fed050 100644 --- a/lib/pages/people_on_the_property_page/people_on_the_property_page_model.dart +++ b/lib/pages/people_on_the_property_page/people_on_the_property_page_model.dart @@ -1,4 +1,3 @@ -import '/flutter_flow/flutter_flow_data_table.dart'; import '/flutter_flow/flutter_flow_util.dart'; import 'people_on_the_property_page_widget.dart' show PeopleOnThePropertyPageWidget; @@ -9,9 +8,6 @@ class PeopleOnThePropertyPageModel /// State fields for stateful widgets in this page. final unfocusNode = FocusNode(); - // State field(s) for PaginatedDataTable widget. - final paginatedDataTableController = - FlutterFlowDataTableController(); @override void initState(BuildContext context) {} diff --git a/lib/pages/people_on_the_property_page/people_on_the_property_page_widget.dart b/lib/pages/people_on_the_property_page/people_on_the_property_page_widget.dart index 65489440..81244b0f 100644 --- a/lib/pages/people_on_the_property_page/people_on_the_property_page_widget.dart +++ b/lib/pages/people_on_the_property_page/people_on_the_property_page_widget.dart @@ -1,5 +1,4 @@ import '/backend/api_requests/api_calls.dart'; -import '/flutter_flow/flutter_flow_data_table.dart'; import '/flutter_flow/flutter_flow_icon_button.dart'; import '/flutter_flow/flutter_flow_theme.dart'; import '/flutter_flow/flutter_flow_util.dart'; @@ -106,179 +105,72 @@ class _PeopleOnThePropertyPageWidgetState ); } final columnGetPessoasLocalResponse = snapshot.data!; - return Column( - mainAxisSize: MainAxisSize.min, - mainAxisAlignment: MainAxisAlignment.start, - children: [ - Expanded( - child: Builder( - builder: (context) { - final getPessoaLocal = PhpGroup.getPessoasLocalCall - .pessoas( - columnGetPessoasLocalResponse.jsonBody, - ) - ?.toList() ?? - []; - return FlutterFlowDataTable( - controller: _model.paginatedDataTableController, - data: getPessoaLocal, - columnsBuilder: (onSortChanged) => [ - DataColumn2( - label: DefaultTextStyle.merge( - softWrap: true, - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Text( - FFLocalizations.of(context).getText( - 'omjuk919' /* Foto */, - ), - textAlign: TextAlign.center, - style: FlutterFlowTheme.of(context) - .labelLarge - .override( - fontFamily: - FlutterFlowTheme.of(context) - .labelLargeFamily, - color: FlutterFlowTheme.of(context) - .primaryText, - letterSpacing: 0.0, - useGoogleFonts: GoogleFonts.asMap() - .containsKey( - FlutterFlowTheme.of(context) - .labelLargeFamily), - ), - ), - ], + return Builder( + builder: (context) { + final getPoepleProperty = PhpGroup.getPessoasLocalCall + .pessoas( + columnGetPessoasLocalResponse.jsonBody, + ) + ?.toList() ?? + []; + return Column( + mainAxisSize: MainAxisSize.min, + mainAxisAlignment: MainAxisAlignment.start, + children: List.generate(getPoepleProperty.length, + (getPoeplePropertyIndex) { + final getPoeplePropertyItem = + getPoepleProperty[getPoeplePropertyIndex]; + return Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: MainAxisAlignment.start, + children: [ + Padding( + padding: const EdgeInsets.all(4.0), + child: Container( + width: 50.0, + height: 50.0, + clipBehavior: Clip.antiAlias, + decoration: const BoxDecoration( + shape: BoxShape.circle, + ), + child: CachedNetworkImage( + fadeInDuration: const Duration(milliseconds: 500), + fadeOutDuration: const Duration(milliseconds: 500), + imageUrl: valueOrDefault( + 'https://freaccess.com.br/freaccess/getImage.php?devUUID=${FFAppState().devUUID}&userUUID=${FFAppState().userUUID}&cliID=${FFAppState().cliUUID}&atividade=getFoto&Documento=&tipo=E&Email=${getJsonField( + getPoeplePropertyItem, + r'''$.USU_EMAIL''', + ).toString()}', + 'https://storage.googleapis.com/flutterflow-io-6f20.appspot.com/projects/flutter-freaccess-hub-0xgz9q/assets/7ftdetkzc3s0/360_F_64676383_LdbmhiNM6Ypzb3FM4PPuFP9rHe7ri8Ju.jpg', ), + fit: BoxFit.cover, ), ), - DataColumn2( - label: DefaultTextStyle.merge( - softWrap: true, - child: Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Text( - FFLocalizations.of(context).getText( - 'fli7tpz6' /* Nome */, - ), - style: FlutterFlowTheme.of(context) - .labelLarge - .override( - fontFamily: - FlutterFlowTheme.of(context) - .labelLargeFamily, - color: FlutterFlowTheme.of(context) - .primaryText, - letterSpacing: 0.0, - useGoogleFonts: GoogleFonts.asMap() - .containsKey( - FlutterFlowTheme.of(context) - .labelLargeFamily), - ), - ), - ], - ), - ), - ), - ], - dataRowBuilder: (getPessoaLocalItem, - getPessoaLocalIndex, - selected, - onSelectChanged) => - DataRow( - color: MaterialStateProperty.all( - getPessoaLocalIndex % 2 == 0 - ? FlutterFlowTheme.of(context) - .primaryBackground - : FlutterFlowTheme.of(context) - .primaryBackground, - ), - cells: [ - Row( - mainAxisSize: MainAxisSize.max, - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Padding( - padding: const EdgeInsets.all(4.0), - child: Container( - width: 100.0, - height: 100.0, - clipBehavior: Clip.antiAlias, - decoration: const BoxDecoration( - shape: BoxShape.circle, - ), - child: CachedNetworkImage( - fadeInDuration: - const Duration(milliseconds: 500), - fadeOutDuration: - const Duration(milliseconds: 500), - imageUrl: valueOrDefault( - 'https://freaccess.com.br/freaccess/getImage.php?devUUID=${FFAppState().devUUID}&userUUID=${FFAppState().userUUID}&cliID=${FFAppState().cliUUID}&atividade=getFoto&Documento=&tipo=E&Email=${getJsonField( - getPessoaLocalItem, - r'''$.USU_EMAIL''', - ).toString()}', - 'https://storage.googleapis.com/flutterflow-io-6f20.appspot.com/projects/flutter-freaccess-hub-0xgz9q/assets/7ftdetkzc3s0/360_F_64676383_LdbmhiNM6Ypzb3FM4PPuFP9rHe7ri8Ju.jpg', - ), - fit: BoxFit.cover, - ), - ), - ), - ], - ), - Container( - width: 500.0, - height: 21.0, - decoration: const BoxDecoration(), - alignment: const AlignmentDirectional(-1.0, 0.0), - child: Text( - getJsonField( - getPessoaLocalItem, - r'''$.USU_NOME''', - ).toString(), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: FlutterFlowTheme.of(context) - .bodyMediumFamily, - fontSize: 14.0, - letterSpacing: 0.0, - useGoogleFonts: GoogleFonts.asMap() - .containsKey( - FlutterFlowTheme.of(context) - .bodyMediumFamily), - ), - ), - ), - ].map((c) => DataCell(c)).toList(), ), - paginated: true, - selectable: false, - hidePaginator: false, - showFirstLastButtons: false, - width: MediaQuery.sizeOf(context).width * 1.0, - height: MediaQuery.sizeOf(context).height * 1.0, - headingRowHeight: 56.0, - dataRowHeight: 48.0, - columnSpacing: 20.0, - headingRowColor: - FlutterFlowTheme.of(context).primaryBackground, - borderRadius: BorderRadius.circular(0.0), - addHorizontalDivider: true, - addTopAndBottomDivider: true, - hideDefaultHorizontalDivider: false, - horizontalDividerColor: - FlutterFlowTheme.of(context).customColor5, - horizontalDividerThickness: 0.3, - addVerticalDivider: false, - ); - }, - ), - ), - ], + Text( + getJsonField( + getPoeplePropertyItem, + r'''$.USU_NOME''', + ).toString(), + style: FlutterFlowTheme.of(context) + .bodyMedium + .override( + fontFamily: FlutterFlowTheme.of(context) + .bodyMediumFamily, + fontSize: 14.0, + letterSpacing: 0.0, + useGoogleFonts: GoogleFonts.asMap() + .containsKey(FlutterFlowTheme.of(context) + .bodyMediumFamily), + ), + ), + ] + .divide(const SizedBox(width: 20.0)) + .addToStart(const SizedBox(width: 40.0)), + ); + }).divide(const SizedBox(height: 3.0)), + ); + }, ); }, ), diff --git a/lib/pages/schedule_complete_visit_page/schedule_complete_visit_page_widget.dart b/lib/pages/schedule_complete_visit_page/schedule_complete_visit_page_widget.dart index 5a7c986f..7f94a91d 100644 --- a/lib/pages/schedule_complete_visit_page/schedule_complete_visit_page_widget.dart +++ b/lib/pages/schedule_complete_visit_page/schedule_complete_visit_page_widget.dart @@ -72,7 +72,7 @@ class _ScheduleCompleteVisitPageWidgetState getJsonField( e, r'''$.VTE_DOCUMENTO''', - )) + ).toString().toString()) .toList() .toList() .cast(); @@ -1010,6 +1010,13 @@ class _ScheduleCompleteVisitPageWidgetState context) .languageCode, ); + _model.textController1 + ?.selection = + TextSelection.collapsed( + offset: _model + .textController1! + .text + .length); }); }, child: Container( @@ -1397,6 +1404,13 @@ class _ScheduleCompleteVisitPageWidgetState context) .languageCode, ); + _model.textController2 + ?.selection = + TextSelection.collapsed( + offset: _model + .textController2! + .text + .length); }); }, child: Container( diff --git a/lib/pages/schedule_provisional_visit_page/schedule_provisional_visit_page_widget.dart b/lib/pages/schedule_provisional_visit_page/schedule_provisional_visit_page_widget.dart index 0697e8c1..a9a373ef 100644 --- a/lib/pages/schedule_provisional_visit_page/schedule_provisional_visit_page_widget.dart +++ b/lib/pages/schedule_provisional_visit_page/schedule_provisional_visit_page_widget.dart @@ -506,6 +506,12 @@ class _ScheduleProvisionalVisitPageWidgetState locale: FFLocalizations.of(context) .languageCode, ); + _model.textController1?.selection = + TextSelection.collapsed( + offset: _model + .textController1! + .text + .length); }); }, child: Container( diff --git a/pubspec.yaml b/pubspec.yaml index 9b64a3d6..19887d02 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -29,7 +29,6 @@ dependencies: cached_network_image: 3.3.1 collection: 1.18.0 crop_your_image: 1.0.0 - data_table_2: 2.5.10 device_info_plus: 9.1.2 dropdown_button2: 2.3.9 easy_debounce: 2.0.1 diff --git a/web/index.html b/web/index.html index 4001623d..b91b568b 100644 --- a/web/index.html +++ b/web/index.html @@ -47,6 +47,7 @@ +