class MondayScreen extends StatefulWidget {
static final String id = 'monday_screen';
final User user;
MondayScreen({this.user});
@override
_MondayScreenState createState() => _MondayScreenState();
}
class _MondayScreenState extends State<MondayScreen> {
final _formKey = GlobalKey<FormState>();
String _alOne = '';
@override
void initState() {
super.initState();
_alOne = widget.user.alOne;
}
_submit() async {
if (_formKey.currentState.validate()) {
_formKey.currentState.save();
User user = User(
id: widget.user.id,
alOne: _alOne,
);
DatabaseService.updateUser(user);
Navigator.pop(context);
}
}
class User(
final String id;
final String name;
final String profileImageUrl;
final String email;
final String alOne;
)
User({
this.id;
this.name;
this.profileImageUrl;
this.email;
this.bio;
this.alOne;
)}
--
You received this message because you are subscribed to the Google Groups "Flutter Development (flutter-dev)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flutter-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/flutter-dev/f83d41e9-a73b-4bdf-9175-d77c6ec1ba04%40googlegroups.com.
TextFormField(
initialValue: _alOne,
style: TextStyle(fontSize: 18.0),
decoration: InputDecoration(
labelText: 'Alternativ',
),
validator: (input) => input.trim().length > 100
? 'Please enter a valid name'
: null,
onSaved: (input) => _alOne = input),
To unsubscribe from this group and stop receiving emails from it, send an email to flutt...@googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Flutter Development (flutter-dev)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flutter-dev...@googlegroups.com.
_alOne = widget.user.alOne;
To unsubscribe from this group and stop receiving emails from it, send an email to flutt...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to flutter-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/flutter-dev/65da6678-941d-4df2-a4db-7500b909f6dd%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to flutter-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/flutter-dev/65da6678-941d-4df2-a4db-7500b909f6dd%40googlegroups.com.
Thank you guys, Suzuki 🙌🏼 Solved
To view this discussion on the web visit https://groups.google.com/d/msgid/flutter-dev/CAHWORbouk7ba%3DcYN7duEpo5c4pNcq63Hhfeu9c%2Bu8axeb5%3D1Pw%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "Flutter Development (flutter-dev)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flutter-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/flutter-dev/f83d41e9-a73b-4bdf-9175-d77c6ec1ba04%40googlegroups.com.