fix: ScheduleCompleteVisitPageModel => ScheduleCompleteVisit
This commit is contained in:
parent
14d2c2f19e
commit
57bfbe33d9
|
@ -41,11 +41,9 @@ class _VisitorNotFoundComponentWidgetState
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Container(
|
||||
width: 350.0,
|
||||
height: 350.0,
|
||||
return Container(
|
||||
width: MediaQuery.of(context).size.height * 0.5,
|
||||
height: MediaQuery.of(context).size.height * 0.4,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context).primaryBackground,
|
||||
borderRadius: const BorderRadius.only(
|
||||
|
@ -62,8 +60,7 @@ class _VisitorNotFoundComponentWidgetState
|
|||
Align(
|
||||
alignment: const AlignmentDirectional(1.0, -1.0),
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(0.0, 5.0, 5.0, 0.0),
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(0.0, 5.0, 5.0, 0.0),
|
||||
child: FlutterFlowIconButton(
|
||||
borderRadius: 20.0,
|
||||
borderWidth: 1.0,
|
||||
|
@ -85,8 +82,7 @@ class _VisitorNotFoundComponentWidgetState
|
|||
size: 72.0,
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(0.0, 16.0, 0.0, 0.0),
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(0.0, 16.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'1p9mykbj' /* Usuário não encontrado */,
|
||||
|
@ -101,15 +97,13 @@ class _VisitorNotFoundComponentWidgetState
|
|||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(10.0, 4.0, 10.0, 0.0),
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(20.0, 4.0, 20.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'kt937sp6' /* O documento inserido não corre... */,
|
||||
),
|
||||
style: FlutterFlowTheme.of(context).labelMedium.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context).labelMediumFamily,
|
||||
fontFamily: FlutterFlowTheme.of(context).labelMediumFamily,
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 14.0,
|
||||
letterSpacing: 0.0,
|
||||
|
@ -130,6 +124,7 @@ class _VisitorNotFoundComponentWidgetState
|
|||
backgroundColor: Colors.transparent,
|
||||
enableDrag: true,
|
||||
useSafeArea: true,
|
||||
isDismissible: true,
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return Padding(
|
||||
|
@ -137,24 +132,22 @@ class _VisitorNotFoundComponentWidgetState
|
|||
child: SizedBox(
|
||||
width: double.infinity,
|
||||
height: MediaQuery.of(context).size.height * 0.9,
|
||||
child:
|
||||
const RegisiterVistorTemplateComponentWidget(
|
||||
child: const RegisiterVistorTemplateComponentWidget(
|
||||
source: 'VisitorNotFoundComponent',
|
||||
)),
|
||||
);
|
||||
},
|
||||
).then((value) => safeSetState(() {}));
|
||||
},
|
||||
text: FFLocalizations.of(context).getText(
|
||||
'y2x4nfcn' /* Adicionar */,
|
||||
),
|
||||
text: FFLocalizations.of(context)
|
||||
.getVariableText(enText: 'Add', ptText: 'Adicionar'),
|
||||
options: FFButtonOptions(
|
||||
width: double.infinity,
|
||||
height: 30.0,
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
24.0, 0.0, 24.0, 0.0),
|
||||
iconPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 0.0),
|
||||
iconPadding:
|
||||
const EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 0.0),
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
textStyle: FlutterFlowTheme.of(context).titleSmall.override(
|
||||
fontFamily:
|
||||
|
@ -181,7 +174,6 @@ class _VisitorNotFoundComponentWidgetState
|
|||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
import 'package:hub/backend/api_requests/api_manager.dart';
|
||||
import 'dart:developer';
|
||||
|
||||
import 'package:hub/backend/api_requests/api_manager.dart';
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hub/components/organism_components/schedule_visit_detail/schedule_visit_detail_widget.dart';
|
||||
import 'package:hub/flutter_flow/flutter_flow_model.dart';
|
||||
import 'package:intl/intl.dart';
|
||||
|
||||
class ScheduleVisitDetailModel
|
||||
extends FlutterFlowModel<ScheduleVisitDetailWidget> {
|
||||
|
@ -36,6 +38,36 @@ class ScheduleVisitDetailModel
|
|||
// Stores action output result for [Backend Call - API (postScheduleVisit)] action in Icon widget.
|
||||
ApiCallResponse? postScheduleVisit;
|
||||
|
||||
String convertDateFormat(String dateStr) {
|
||||
try {
|
||||
log('Received date string: $dateStr');
|
||||
|
||||
// Formato original
|
||||
DateFormat originalFormat = DateFormat('d/M/y H:mm:ss');
|
||||
// Novo formato
|
||||
DateFormat newFormat = DateFormat('y-M-d H:mm:ss');
|
||||
|
||||
// Validate the input string format
|
||||
if (!RegExp(r'^\d{1,2}/\d{1,2}/\d{4} \d{1,2}:\d{2}:\d{2}$')
|
||||
.hasMatch(dateStr)) {
|
||||
log('Invalid date format: $dateStr');
|
||||
return 'Invalid date format';
|
||||
}
|
||||
|
||||
// Converte a string para DateTime
|
||||
DateTime dateTime = originalFormat.parse(dateStr);
|
||||
|
||||
// Converte DateTime para a nova string formatada
|
||||
String formattedDate = newFormat.format(dateTime);
|
||||
log('Formatted date: $formattedDate');
|
||||
return formattedDate;
|
||||
} catch (e) {
|
||||
// Handle the exception by returning an error message or a default value
|
||||
log('Error parsing date: $e');
|
||||
return 'Invalid date format';
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
void initState(BuildContext context) {}
|
||||
|
||||
|
|
|
@ -13,6 +13,7 @@ import 'package:hub/flutter_flow/flutter_flow_icon_button.dart';
|
|||
import 'package:hub/flutter_flow/flutter_flow_model.dart';
|
||||
import 'package:hub/flutter_flow/flutter_flow_theme.dart';
|
||||
import 'package:hub/flutter_flow/flutter_flow_util.dart';
|
||||
import 'package:hub/flutter_flow/flutter_flow_widgets.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
class ScheduleVisitDetailWidget extends StatefulWidget {
|
||||
|
@ -46,6 +47,7 @@ class ScheduleVisitDetailWidget extends StatefulWidget {
|
|||
|
||||
class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
||||
late ScheduleVisitDetailModel _model;
|
||||
late FocusNode _focusNode;
|
||||
|
||||
@override
|
||||
void setState(VoidCallback callback) {
|
||||
|
@ -56,6 +58,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
_focusNode = FocusNode();
|
||||
_model = createModel(context, () => ScheduleVisitDetailModel());
|
||||
|
||||
_model.textController1 ??= TextEditingController(text: widget.visitTempStr);
|
||||
|
@ -83,19 +86,33 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
@override
|
||||
void dispose() {
|
||||
_model.maybeDispose();
|
||||
_focusNode.dispose();
|
||||
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
void _requestFocus() {
|
||||
if (mounted) {
|
||||
_focusNode.requestFocus();
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
context.watch<FFAppState>();
|
||||
final visitorsData = widget.visitorJsonList!.toList().take(2).toList();
|
||||
final visitorsDataItem = visitorsData[0];
|
||||
|
||||
return Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(0.0, 35.0, 0.0, 0.0),
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 0.0),
|
||||
child: GestureDetector(
|
||||
onTap: () {
|
||||
_requestFocus();
|
||||
},
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
height: double.infinity,
|
||||
// color: FlutterFlowTheme.of(context).primaryBackground,
|
||||
width: MediaQuery.of(context).size.width,
|
||||
height: MediaQuery.of(context).size.height * 0.6,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context).primaryBackground,
|
||||
borderRadius: const BorderRadius.only(
|
||||
|
@ -109,13 +126,11 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, -1.0),
|
||||
child: Container(
|
||||
Container(
|
||||
width: double.infinity,
|
||||
height: 35.0,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
color: FlutterFlowTheme.of(context).primaryBackground,
|
||||
borderRadius: const BorderRadius.only(
|
||||
bottomLeft: Radius.circular(0.0),
|
||||
bottomRight: Radius.circular(0.0),
|
||||
|
@ -137,7 +152,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
buttonSize: 40.0,
|
||||
icon: Icon(
|
||||
Icons.keyboard_return,
|
||||
color: FlutterFlowTheme.of(context).primaryBackground,
|
||||
color: FlutterFlowTheme.of(context).accent1,
|
||||
size: 24.0,
|
||||
),
|
||||
onPressed: () async {
|
||||
|
@ -148,90 +163,21 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Container(
|
||||
decoration: const BoxDecoration(
|
||||
shape: BoxShape.rectangle,
|
||||
),
|
||||
child: Stack(
|
||||
children: [
|
||||
Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
mainAxisAlignment: MainAxisAlignment.end,
|
||||
children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, -1.0),
|
||||
child: Padding(
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
5.0, 0.0, 5.0, 20.0),
|
||||
child: Container(
|
||||
child: SizedBox(
|
||||
width: 100.0,
|
||||
decoration: const BoxDecoration(),
|
||||
child: Builder(
|
||||
builder: (context) {
|
||||
final visitorsData = widget.visitorJsonList!
|
||||
.toList()
|
||||
.take(1)
|
||||
.toList();
|
||||
|
||||
return SingleChildScrollView(
|
||||
scrollDirection: Axis.horizontal,
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: List.generate(visitorsData.length,
|
||||
(visitorsDataIndex) {
|
||||
final visitorsDataItem =
|
||||
visitorsData[visitorsDataIndex];
|
||||
return Container(
|
||||
decoration: BoxDecoration(
|
||||
borderRadius:
|
||||
BorderRadius.circular(100.0),
|
||||
),
|
||||
child: Align(
|
||||
alignment: const AlignmentDirectional(
|
||||
1.0, -1.0),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
// Navigator.pop(context);
|
||||
// await showModalBottomSheet(
|
||||
// isScrollControlled: true,
|
||||
// backgroundColor:
|
||||
// Colors.transparent,
|
||||
// useSafeArea: true,
|
||||
// context: context,
|
||||
// builder: (context) {
|
||||
// return Padding(
|
||||
// padding:
|
||||
// MediaQuery.viewInsetsOf(
|
||||
// context),
|
||||
// child:
|
||||
// VisitorDetailsModalTemplateComponentWidget(
|
||||
// visitorImageURL: '',
|
||||
// visitorEmail: '',
|
||||
// visitorName: '',
|
||||
// visitorPhone: '',
|
||||
// visitorType: '',
|
||||
// ),
|
||||
// );
|
||||
// },
|
||||
// ).then((value) =>
|
||||
// safeSetState(() {}));
|
||||
},
|
||||
child: ClipRRect(
|
||||
borderRadius:
|
||||
BorderRadius.circular(100.0),
|
||||
borderRadius: BorderRadius.circular(100.0),
|
||||
child: CachedNetworkImage(
|
||||
fadeInDuration: const Duration(
|
||||
milliseconds: 500),
|
||||
fadeOutDuration: const Duration(
|
||||
milliseconds: 500),
|
||||
imageUrl:
|
||||
valueOrDefault<String>(
|
||||
fadeInDuration: const Duration(milliseconds: 500),
|
||||
fadeOutDuration: const Duration(milliseconds: 500),
|
||||
imageUrl: valueOrDefault<String>(
|
||||
"https://freaccess.com.br/freaccess/getImage.php?devUUID=${FFAppState().devUUID}&userUUID=${FFAppState().userUUID}&cliID=${FFAppState().cliUUID}&atividade=getFoto&Documento=${getJsonField(
|
||||
visitorsDataItem,
|
||||
r'''$.VTE_DOCUMENTO''',
|
||||
|
@ -245,15 +191,6 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}),
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
|
@ -266,11 +203,11 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
controller: _model.textController1,
|
||||
focusNode: _model.textFieldFocusNode1,
|
||||
autofocus: false,
|
||||
readOnly: true,
|
||||
obscureText: false,
|
||||
decoration: InputDecoration(
|
||||
isDense: false,
|
||||
labelText:
|
||||
FFLocalizations.of(context).getText(
|
||||
isDense: true,
|
||||
labelText: FFLocalizations.of(context).getText(
|
||||
'7w4fohoa' /* Encerramento da Visita */,
|
||||
),
|
||||
labelStyle: FlutterFlowTheme.of(context)
|
||||
|
@ -301,16 +238,14 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color:
|
||||
FlutterFlowTheme.of(context).accent1,
|
||||
color: FlutterFlowTheme.of(context).accent1,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color:
|
||||
FlutterFlowTheme.of(context).primary,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
|
@ -337,8 +272,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.containsKey(FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
validator: _model.textController1Validator
|
||||
|
@ -355,18 +289,20 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
children: [
|
||||
Expanded(
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
8.0, 0.0, 8.0, 0.0),
|
||||
child: TextFormField(
|
||||
controller: _model.textController2,
|
||||
focusNode: _model.textFieldFocusNode2,
|
||||
autofocus: false,
|
||||
obscureText: false,
|
||||
readOnly: true,
|
||||
decoration: InputDecoration(
|
||||
labelText:
|
||||
FFLocalizations.of(context).getText(
|
||||
'snah4iet' /* Início */,
|
||||
isDense: true,
|
||||
labelText: FFLocalizations.of(context)
|
||||
.getVariableText(
|
||||
enText: 'Start',
|
||||
ptText: 'Início',
|
||||
),
|
||||
labelStyle: FlutterFlowTheme.of(context)
|
||||
.labelMedium
|
||||
|
@ -374,15 +310,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
hintText:
|
||||
|
@ -395,15 +328,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
|
@ -412,8 +342,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.accent1,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
|
@ -421,35 +350,32 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.primary,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
errorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedErrorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
fontSize: 12,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
|
@ -463,15 +389,16 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
),
|
||||
Expanded(
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
8.0, 0.0, 8.0, 0.0),
|
||||
child: TextFormField(
|
||||
controller: _model.textController3,
|
||||
focusNode: _model.textFieldFocusNode3,
|
||||
autofocus: false,
|
||||
obscureText: false,
|
||||
readOnly: true,
|
||||
decoration: InputDecoration(
|
||||
isDense: true,
|
||||
labelText:
|
||||
FFLocalizations.of(context).getText(
|
||||
'abppdgz3' /* Término */,
|
||||
|
@ -482,15 +409,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
hintText:
|
||||
|
@ -503,15 +427,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
|
@ -520,8 +441,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.accent1,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
|
@ -529,35 +449,32 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.primary,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
errorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedErrorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
fontSize: 12,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
|
@ -581,15 +498,16 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
children: [
|
||||
Expanded(
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
8.0, 0.0, 8.0, 0.0),
|
||||
child: TextFormField(
|
||||
controller: _model.textController4,
|
||||
focusNode: _model.textFieldFocusNode4,
|
||||
autofocus: false,
|
||||
obscureText: false,
|
||||
readOnly: true,
|
||||
decoration: InputDecoration(
|
||||
isDense: true,
|
||||
labelText:
|
||||
FFLocalizations.of(context).getText(
|
||||
'xjxhzqqm' /* Motivo da Visita */,
|
||||
|
@ -600,15 +518,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
hintText:
|
||||
|
@ -621,15 +536,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
|
@ -638,8 +550,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.accent1,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
|
@ -647,33 +558,29 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.primary,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
errorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedErrorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
|
@ -689,15 +596,16 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
),
|
||||
Expanded(
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
8.0, 0.0, 8.0, 0.0),
|
||||
child: TextFormField(
|
||||
controller: _model.textController5,
|
||||
focusNode: _model.textFieldFocusNode5,
|
||||
autofocus: false,
|
||||
obscureText: false,
|
||||
readOnly: true,
|
||||
decoration: InputDecoration(
|
||||
isDense: true,
|
||||
labelText:
|
||||
FFLocalizations.of(context).getText(
|
||||
'2ujg7u18' /* Nível de Acesso */,
|
||||
|
@ -708,15 +616,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
hintText:
|
||||
|
@ -729,15 +634,12 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily,
|
||||
color:
|
||||
FlutterFlowTheme.of(context)
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts
|
||||
.asMap()
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(
|
||||
context)
|
||||
FlutterFlowTheme.of(context)
|
||||
.labelMediumFamily),
|
||||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
|
@ -746,8 +648,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.accent1,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
|
@ -755,33 +656,29 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.primary,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
errorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedErrorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.error,
|
||||
color:
|
||||
FlutterFlowTheme.of(context).error,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
|
@ -808,9 +705,10 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
focusNode: _model.textFieldFocusNode6,
|
||||
autofocus: false,
|
||||
obscureText: false,
|
||||
readOnly: true,
|
||||
decoration: InputDecoration(
|
||||
labelText:
|
||||
FFLocalizations.of(context).getText(
|
||||
isDense: true,
|
||||
labelText: FFLocalizations.of(context).getText(
|
||||
'ritce5uw' /* Observações da Visita */,
|
||||
),
|
||||
labelStyle: FlutterFlowTheme.of(context)
|
||||
|
@ -841,16 +739,14 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color:
|
||||
FlutterFlowTheme.of(context).accent1,
|
||||
color: FlutterFlowTheme.of(context).accent1,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color:
|
||||
FlutterFlowTheme.of(context).primary,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
width: 0.5,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
|
@ -877,8 +773,7 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.containsKey(FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
validator: _model.textController6Validator
|
||||
|
@ -888,50 +783,10 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
),
|
||||
],
|
||||
),
|
||||
Container(
|
||||
width: double.infinity,
|
||||
height: 22.0,
|
||||
decoration: BoxDecoration(
|
||||
color:
|
||||
FlutterFlowTheme.of(context).secondaryBackground,
|
||||
borderRadius: const BorderRadius.only(
|
||||
bottomLeft: Radius.circular(25.0),
|
||||
bottomRight: Radius.circular(25.0),
|
||||
topLeft: Radius.circular(0.0),
|
||||
topRight: Radius.circular(0.0),
|
||||
].divide(const SizedBox(height: 0.0)),
|
||||
),
|
||||
),
|
||||
),
|
||||
]
|
||||
.divide(const SizedBox(height: 30.0))
|
||||
.addToStart(const SizedBox(height: 100.0)),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, 1.0),
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(0.0, 6.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
height: 35.0,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
borderRadius: const BorderRadius.only(
|
||||
bottomLeft: Radius.circular(0.0),
|
||||
bottomRight: Radius.circular(0.0),
|
||||
topLeft: Radius.circular(0.0),
|
||||
topRight: Radius.circular(0.0),
|
||||
),
|
||||
),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
IconButton(
|
||||
onPressed: () async {
|
||||
_model.postScheduleVisit =
|
||||
await PhpGroup.postScheduleVisitCall.call(
|
||||
devUUID: FFAppState().devUUID,
|
||||
|
@ -939,8 +794,9 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
atividade: 'putVisita',
|
||||
devDesc: widget.visitObsStr,
|
||||
idVisitante: widget.visitorStrList,
|
||||
dtInicio: widget.visitStartDate,
|
||||
dtFim: widget.visitEndDate,
|
||||
dtInicio:
|
||||
_model.convertDateFormat(widget.visitStartDate ?? ''),
|
||||
dtFim: _model.convertDateFormat(widget.visitEndDate ?? ''),
|
||||
unica: widget.visitTempStr,
|
||||
idMotivo: extractIdToStr(widget.visitResonStr!),
|
||||
idNAC: extractIdToStr(widget.visitLevelStr!),
|
||||
|
@ -974,18 +830,16 @@ class _ScheduleVisitDetailWidgetState extends State<ScheduleVisitDetailWidget> {
|
|||
|
||||
setState(() {});
|
||||
},
|
||||
child: Icon(
|
||||
Icons.save_alt,
|
||||
color: FlutterFlowTheme.of(context).secondaryText,
|
||||
size: 24.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
icon: Icon(
|
||||
Icons.check,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
size: 15.0,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -485,9 +485,9 @@ class _RegisiterVistorTemplateComponentWidgetState
|
|||
final selectedMedia =
|
||||
await selectMediaWithSourceBottomSheet(
|
||||
context: context,
|
||||
maxWidth: 300.00,
|
||||
maxHeight: 300.00,
|
||||
imageQuality: 0,
|
||||
// maxWidth: 300.00,
|
||||
// maxHeight: 300.00,
|
||||
imageQuality: 100,
|
||||
allowPhoto: true,
|
||||
includeDimensions: true,
|
||||
);
|
||||
|
@ -567,7 +567,7 @@ class _RegisiterVistorTemplateComponentWidgetState
|
|||
),
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).accent1,
|
||||
width: 0.5,
|
||||
width: 0.2,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
|
@ -915,7 +915,7 @@ class _RegisiterVistorTemplateComponentWidgetState
|
|||
options: FFButtonOptions(
|
||||
width: 250.0,
|
||||
height: 36.0,
|
||||
disabledColor: FlutterFlowTheme.of(context).customColor6,
|
||||
disabledColor: FlutterFlowTheme.of(context).customColor5,
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
80.0, 0.0, 80.0, 0.0),
|
||||
iconPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
|
|
|
@ -1,6 +1,3 @@
|
|||
|
||||
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hub/components/organism_components/schedule_visit_detail/schedule_visit_detail_widget.dart';
|
||||
import 'package:hub/components/templates_components/view_visit_detail/view_visit_detail_widget.dart';
|
||||
|
@ -74,9 +71,7 @@ class _VisitDetailsModalTemplateComponentWidgetState
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Align(
|
||||
alignment: const AlignmentDirectional(0.0, 1.0),
|
||||
child: Builder(
|
||||
return Builder(
|
||||
builder: (context) {
|
||||
if (widget.visitStatusStr != null && widget.visitStatusStr != '') {
|
||||
return wrapWithModel(
|
||||
|
@ -117,7 +112,6 @@ class _VisitDetailsModalTemplateComponentWidgetState
|
|||
);
|
||||
}
|
||||
},
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -109,16 +109,20 @@ class _VisitorSearchModalTemplateComponentWidgetState
|
|||
_model.addToDocs(_model.textController.text);
|
||||
setState(() {});
|
||||
} else {
|
||||
await showModalBottomSheet(
|
||||
isScrollControlled: true,
|
||||
enableDrag: true,
|
||||
isDismissible: true,
|
||||
backgroundColor: Colors.transparent,
|
||||
await showAdaptiveDialog(
|
||||
useSafeArea: true,
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return Padding(
|
||||
return Dialog(
|
||||
child: Padding(
|
||||
padding: MediaQuery.viewInsetsOf(context),
|
||||
child: const VisitorNotFoundComponentWidget(),
|
||||
child: Container(
|
||||
color: Colors.transparent,
|
||||
// width: MediaQuery.of(context).size.height * 0.1,
|
||||
// height:
|
||||
// MediaQuery.of(context).size.height * 0.4,
|
||||
child: const VisitorNotFoundComponentWidget()),
|
||||
),
|
||||
);
|
||||
},
|
||||
).then((value) => safeSetState(() {}));
|
||||
|
|
|
@ -91,7 +91,9 @@ Future<List<SelectedFile>?> selectMediaWithSourceBottomSheet({
|
|||
textAlign: TextAlign.center,
|
||||
style: GoogleFonts.getFont(
|
||||
pickerFontFamily,
|
||||
color: FlutterFlowTheme.of(context).primaryText.withOpacity(0.65),
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText
|
||||
.withOpacity(0.65),
|
||||
fontWeight: FontWeight.w500,
|
||||
fontSize: 20,
|
||||
),
|
||||
|
@ -360,14 +362,22 @@ void showUploadMessage(
|
|||
child: CircularProgressIndicator(
|
||||
valueColor: Theme.of(context).brightness == Brightness.dark
|
||||
? AlwaysStoppedAnimation<Color>(
|
||||
FlutterFlowTheme.of(context).accent4)
|
||||
FlutterFlowTheme.of(context).info)
|
||||
: null,
|
||||
),
|
||||
),
|
||||
Text(message),
|
||||
Text(message, style: FlutterFlowTheme.of(context).bodyMedium),
|
||||
],
|
||||
),
|
||||
duration: showLoading ? const Duration(days: 1) : const Duration(seconds: 4),
|
||||
backgroundColor: FlutterFlowTheme.of(context).primary,
|
||||
shape: const RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.only(
|
||||
topLeft: Radius.circular(15),
|
||||
topRight: Radius.circular(15),
|
||||
),
|
||||
),
|
||||
duration:
|
||||
showLoading ? const Duration(days: 1) : const Duration(seconds: 4),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
|
@ -83,6 +83,12 @@ class ScheduleCompleteVisitPageModel
|
|||
enText: 'Start date must be before end date.',
|
||||
);
|
||||
}
|
||||
if (startDate.isBefore(DateTime.now())) {
|
||||
return FFLocalizations.of(context).getVariableText(
|
||||
enText: 'Start date must be after current date.',
|
||||
ptText: 'A data de início deve ser posterior à data atual.',
|
||||
);
|
||||
}
|
||||
} catch (e) {
|
||||
return '$e';
|
||||
}
|
||||
|
@ -113,6 +119,12 @@ class ScheduleCompleteVisitPageModel
|
|||
ptText: 'A data de término deve ser posterior à data de início.',
|
||||
);
|
||||
}
|
||||
if (endDate.isBefore(DateTime.now())) {
|
||||
return FFLocalizations.of(context).getVariableText(
|
||||
enText: 'End date must be after current date.',
|
||||
ptText: 'A data de término deve ser posterior à data atual.',
|
||||
);
|
||||
}
|
||||
} catch (e) {
|
||||
return '$e';
|
||||
}
|
||||
|
|
|
@ -269,300 +269,12 @@ Widget scheduleVisit(
|
|||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
|
||||
children: [
|
||||
Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(-1.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
20.0, 30.0, 0.0, 30.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'u0jocx7e' /* Quais visitantes você deseja c... */,
|
||||
),
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context).bodyMedium.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context).bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.bold,
|
||||
useGoogleFonts: GoogleFonts.asMap().containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
if (_model.visitorJsonList.isNotEmpty)
|
||||
Builder(
|
||||
builder: (context) {
|
||||
final visitorListView =
|
||||
_model.visitorJsonList.map((e) => e).toList();
|
||||
return ListView.separated(
|
||||
padding: const EdgeInsets.fromLTRB(
|
||||
0,
|
||||
0,
|
||||
20,
|
||||
20,
|
||||
),
|
||||
shrinkWrap: true,
|
||||
scrollDirection: Axis.vertical,
|
||||
itemCount: visitorListView.length,
|
||||
separatorBuilder: (_, __) =>
|
||||
const SizedBox(height: 5.0),
|
||||
itemBuilder: (context, visitorListViewIndex) {
|
||||
final visitorListViewItem =
|
||||
visitorListView[visitorListViewIndex];
|
||||
return InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
// await showModalBottomSheet(
|
||||
// isScrollControlled: true,
|
||||
// backgroundColor: Colors.transparent,
|
||||
// enableDrag: false,
|
||||
// context: context,
|
||||
// builder: (context) {
|
||||
// return GestureDetector(
|
||||
// onTap: () => _model
|
||||
// .unfocusNode.canRequestFocus
|
||||
// ? FocusScope.of(context)
|
||||
// .requestFocus(_model.unfocusNode)
|
||||
// : FocusScope.of(context).unfocus(),
|
||||
// child: Padding(
|
||||
// padding:
|
||||
// MediaQuery.viewInsetsOf(context),
|
||||
// child:
|
||||
// const VisitorDetailsModalTemplateComponentWidget(
|
||||
// visitorImageURL: '',
|
||||
// visitorEmail: '',
|
||||
// visitorName: '',
|
||||
// visitorPhone: '',
|
||||
// visitorType: '',
|
||||
// ),
|
||||
// ),
|
||||
// );
|
||||
// },
|
||||
// ).then((value) => safeSetState(() {}));
|
||||
},
|
||||
onLongPress: () async {
|
||||
// _model.removeFromVisitorJsonList(
|
||||
// visitorListViewItem);
|
||||
// setState(() {});
|
||||
},
|
||||
child: Container(
|
||||
width: MediaQuery.of(context).size.width,
|
||||
height: 70.0,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
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:
|
||||
"https://freaccess.com.br/freaccess/getImage.php?devUUID=${FFAppState().devUUID}&userUUID=${FFAppState().userUUID}&cliID=${FFAppState().cliUUID}&atividade=getFoto&Documento=${getJsonField(
|
||||
visitorListViewItem,
|
||||
r'''$.VTE_DOCUMENTO''',
|
||||
).toString()}&tipo=E",
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
),
|
||||
Text(
|
||||
getJsonField(
|
||||
visitorListViewItem,
|
||||
r'''$.VTE_NOME''',
|
||||
).toString(),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.end,
|
||||
children: [
|
||||
IconButton(
|
||||
onPressed: () async {
|
||||
_model
|
||||
.removeFromVisitorJsonList(
|
||||
visitorListViewItem);
|
||||
setState(() {});
|
||||
},
|
||||
icon: const Icon(Icons.close)),
|
||||
],
|
||||
),
|
||||
),
|
||||
]
|
||||
.divide(const SizedBox(width: 30.0))
|
||||
.addToStart(const SizedBox(width: 30.0)),
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
);
|
||||
},
|
||||
),
|
||||
Stack(
|
||||
children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.01, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 20.0),
|
||||
child: FFButtonWidget(
|
||||
onPressed: () async {
|
||||
await showModalBottomSheet(
|
||||
isScrollControlled: true,
|
||||
isDismissible: true,
|
||||
backgroundColor: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
enableDrag: true,
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return GestureDetector(
|
||||
onTap: () => _model
|
||||
.unfocusNode.canRequestFocus
|
||||
? FocusScope.of(context)
|
||||
.requestFocus(_model.unfocusNode)
|
||||
: FocusScope.of(context).unfocus(),
|
||||
child: SizedBox(
|
||||
height:
|
||||
MediaQuery.of(context).size.height *
|
||||
0.9,
|
||||
width: MediaQuery.of(context).size.width,
|
||||
child: Padding(
|
||||
padding:
|
||||
MediaQuery.viewInsetsOf(context),
|
||||
child:
|
||||
VisitorSearchModalTemplateComponentWidget(
|
||||
getVisitors: (visitorsParam) async {
|
||||
_model.visitorJsonList =
|
||||
visitorsParam!
|
||||
.toList()
|
||||
.cast<dynamic>();
|
||||
setState(() {});
|
||||
},
|
||||
getDocs: (docsParam) async {
|
||||
_model.visitorStrList =
|
||||
strListToStr(
|
||||
docsParam!.toList());
|
||||
setState(() {});
|
||||
},
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
).then((value) => safeSetState(() {}));
|
||||
},
|
||||
text: '',
|
||||
icon: Icon(
|
||||
Icons.add,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
size: 30.0,
|
||||
),
|
||||
options: FFButtonOptions(
|
||||
width: MediaQuery.sizeOf(context).width * 0.8,
|
||||
height: 80.0,
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 0.0),
|
||||
iconPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
14.0, 0.0, 0.0, 20.0),
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
textStyle: FlutterFlowTheme.of(context)
|
||||
.titleSmall
|
||||
.override(
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.titleSmallFamily,
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
fontSize: 16.0,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.titleSmallFamily),
|
||||
),
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).accent4,
|
||||
width: 1.0,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 50.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: MediaQuery.sizeOf(context).width * 0.8,
|
||||
height: 20.0,
|
||||
decoration: const BoxDecoration(),
|
||||
child: Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: AutoSizeText(
|
||||
FFLocalizations.of(context).getText(
|
||||
'r8soavtz' /* Clique para adicionar um visit... */,
|
||||
),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
Column(mainAxisSize: MainAxisSize.max, children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(-1.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
20.0, 24.0, 0.0, 24.0),
|
||||
20.0, 30.0, 0.0, 24.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'98evnbbe' /* Qual o período de validade da ... */,
|
||||
|
@ -1079,6 +791,294 @@ Widget scheduleVisit(
|
|||
]
|
||||
// .divide(const SizedBox(height: 0.0)),
|
||||
),
|
||||
Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(-1.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
20.0, 24.0, 0.0, 30.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'u0jocx7e' /* Quais visitantes você deseja c... */,
|
||||
),
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context).bodyMedium.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context).bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.bold,
|
||||
useGoogleFonts: GoogleFonts.asMap().containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
if (_model.visitorJsonList.isNotEmpty)
|
||||
Builder(
|
||||
builder: (context) {
|
||||
final visitorListView =
|
||||
_model.visitorJsonList.map((e) => e).toList();
|
||||
return ListView.separated(
|
||||
padding: const EdgeInsets.fromLTRB(
|
||||
0,
|
||||
0,
|
||||
20,
|
||||
20,
|
||||
),
|
||||
shrinkWrap: true,
|
||||
scrollDirection: Axis.vertical,
|
||||
itemCount: visitorListView.length,
|
||||
separatorBuilder: (_, __) =>
|
||||
const SizedBox(height: 5.0),
|
||||
itemBuilder: (context, visitorListViewIndex) {
|
||||
final visitorListViewItem =
|
||||
visitorListView[visitorListViewIndex];
|
||||
return InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
// await showModalBottomSheet(
|
||||
// isScrollControlled: true,
|
||||
// backgroundColor: Colors.transparent,
|
||||
// enableDrag: false,
|
||||
// context: context,
|
||||
// builder: (context) {
|
||||
// return GestureDetector(
|
||||
// onTap: () => _model
|
||||
// .unfocusNode.canRequestFocus
|
||||
// ? FocusScope.of(context)
|
||||
// .requestFocus(_model.unfocusNode)
|
||||
// : FocusScope.of(context).unfocus(),
|
||||
// child: Padding(
|
||||
// padding:
|
||||
// MediaQuery.viewInsetsOf(context),
|
||||
// child:
|
||||
// const VisitorDetailsModalTemplateComponentWidget(
|
||||
// visitorImageURL: '',
|
||||
// visitorEmail: '',
|
||||
// visitorName: '',
|
||||
// visitorPhone: '',
|
||||
// visitorType: '',
|
||||
// ),
|
||||
// ),
|
||||
// );
|
||||
// },
|
||||
// ).then((value) => safeSetState(() {}));
|
||||
},
|
||||
onLongPress: () async {
|
||||
// _model.removeFromVisitorJsonList(
|
||||
// visitorListViewItem);
|
||||
// setState(() {});
|
||||
},
|
||||
child: Container(
|
||||
width: MediaQuery.of(context).size.width,
|
||||
height: 70.0,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
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:
|
||||
"https://freaccess.com.br/freaccess/getImage.php?devUUID=${FFAppState().devUUID}&userUUID=${FFAppState().userUUID}&cliID=${FFAppState().cliUUID}&atividade=getFoto&Documento=${getJsonField(
|
||||
visitorListViewItem,
|
||||
r'''$.VTE_DOCUMENTO''',
|
||||
).toString()}&tipo=E",
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
),
|
||||
Text(
|
||||
getJsonField(
|
||||
visitorListViewItem,
|
||||
r'''$.VTE_NOME''',
|
||||
).toString(),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.end,
|
||||
children: [
|
||||
IconButton(
|
||||
onPressed: () async {
|
||||
_model
|
||||
.removeFromVisitorJsonList(
|
||||
visitorListViewItem);
|
||||
setState(() {});
|
||||
},
|
||||
icon: const Icon(Icons.close)),
|
||||
],
|
||||
),
|
||||
),
|
||||
]
|
||||
.divide(const SizedBox(width: 30.0))
|
||||
.addToStart(const SizedBox(width: 30.0)),
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
);
|
||||
},
|
||||
),
|
||||
Stack(
|
||||
children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.01, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 20.0),
|
||||
child: FFButtonWidget(
|
||||
onPressed: () async {
|
||||
await showModalBottomSheet(
|
||||
isScrollControlled: true,
|
||||
isDismissible: true,
|
||||
backgroundColor: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
enableDrag: true,
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return GestureDetector(
|
||||
onTap: () => _model
|
||||
.unfocusNode.canRequestFocus
|
||||
? FocusScope.of(context)
|
||||
.requestFocus(_model.unfocusNode)
|
||||
: FocusScope.of(context).unfocus(),
|
||||
child: SizedBox(
|
||||
height:
|
||||
MediaQuery.of(context).size.height *
|
||||
0.7,
|
||||
width: MediaQuery.of(context).size.width,
|
||||
child: Padding(
|
||||
padding:
|
||||
MediaQuery.viewInsetsOf(context),
|
||||
child:
|
||||
VisitorSearchModalTemplateComponentWidget(
|
||||
getVisitors: (visitorsParam) async {
|
||||
_model.visitorJsonList =
|
||||
visitorsParam!
|
||||
.toList()
|
||||
.cast<dynamic>();
|
||||
setState(() {});
|
||||
},
|
||||
getDocs: (docsParam) async {
|
||||
_model.visitorStrList =
|
||||
strListToStr(
|
||||
docsParam!.toList());
|
||||
setState(() {});
|
||||
},
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
).then((value) => safeSetState(() {}));
|
||||
},
|
||||
text: '',
|
||||
icon: Icon(
|
||||
Icons.add,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
size: 30.0,
|
||||
),
|
||||
options: FFButtonOptions(
|
||||
width: MediaQuery.sizeOf(context).width * 0.8,
|
||||
height: 80.0,
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 0.0),
|
||||
iconPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
14.0, 0.0, 0.0, 20.0),
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
textStyle: FlutterFlowTheme.of(context)
|
||||
.titleSmall
|
||||
.override(
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.titleSmallFamily,
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
fontSize: 16.0,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.titleSmallFamily),
|
||||
),
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).accent4,
|
||||
width: 1.0,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 50.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: MediaQuery.sizeOf(context).width * 0.8,
|
||||
height: 20.0,
|
||||
decoration: const BoxDecoration(),
|
||||
child: Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: AutoSizeText(
|
||||
FFLocalizations.of(context).getText(
|
||||
'r8soavtz' /* Clique para adicionar um visit... */,
|
||||
),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily,
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
letterSpacing: 0.0,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMediumFamily),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
|
@ -1146,6 +1146,8 @@ Widget scheduleVisit(
|
|||
dropDownGetDadosResponse.jsonBody,
|
||||
);
|
||||
return FlutterFlowDropDown<String>(
|
||||
fillColor: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
controller:
|
||||
_model.dropDownValueController1 ??=
|
||||
FormFieldController<String>(
|
||||
|
@ -1326,6 +1328,8 @@ Widget scheduleVisit(
|
|||
const EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 0.0, 16.0, 0.0),
|
||||
hidesUnderline: true,
|
||||
fillColor: FlutterFlowTheme.of(context)
|
||||
.primaryBackground,
|
||||
isOverButton: true,
|
||||
isSearchable: false,
|
||||
isMultiSelect: false,
|
||||
|
@ -1602,13 +1606,13 @@ Widget scheduleVisit(
|
|||
),
|
||||
),
|
||||
FFButtonWidget(
|
||||
text: 'Schedule',
|
||||
text: FFLocalizations.of(context).getVariableText(
|
||||
enText: 'Schedule',
|
||||
ptText: 'Agendar',
|
||||
),
|
||||
onPressed: _model.isValid()
|
||||
? () async {
|
||||
await showDialog(
|
||||
// isScrollControlled: true,
|
||||
// backgroundColor: Colors.transparent,
|
||||
// enableDrag: false,
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return GestureDetector(
|
||||
|
@ -1619,8 +1623,8 @@ Widget scheduleVisit(
|
|||
child: Dialog(
|
||||
alignment: Alignment.topCenter,
|
||||
child: SizedBox(
|
||||
width: MediaQuery.of(context).size.width,
|
||||
height: MediaQuery.of(context).size.height * 0.5,
|
||||
// width: MediaQuery.of(context).size.width,
|
||||
// height: MediaQuery.of(context).size.height * 0.7,
|
||||
child: VisitDetailsModalTemplateComponentWidget(
|
||||
visitStartDateStr: _model.textController1.text,
|
||||
visitEndDateStr: _model.textController2.text,
|
||||
|
@ -1645,6 +1649,12 @@ Widget scheduleVisit(
|
|||
height: MediaQuery.of(context).size.height * 0.05,
|
||||
width: MediaQuery.of(context).size.height * 0.2,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
borderRadius: const BorderRadius.only(
|
||||
bottomLeft: Radius.circular(15.0),
|
||||
bottomRight: Radius.circular(15.0),
|
||||
topLeft: Radius.circular(15.0),
|
||||
topRight: Radius.circular(15.0),
|
||||
),
|
||||
disabledColor: FlutterFlowTheme.of(context).customColor5),
|
||||
showLoadingIndicator: true,
|
||||
),
|
||||
|
|
Loading…
Reference in New Issue