Update API to update patient. Update mytextfield to table is editable paramiter. add edit page to edit user information.

This commit is contained in:
2024-06-20 10:07:52 +02:00
parent deda00c955
commit 5a3f62c1ff
19 changed files with 375 additions and 26 deletions

View File

@@ -3,19 +3,30 @@ import 'package:flutter/material.dart';
class MyTextField extends StatelessWidget {
final controller;
final String hintText;
final bool editable;
const MyTextField({
super.key,
required this.controller,
required this.hintText,
required this.editable,
});
bool makeEditable() {
if (editable) {
return false;
} else {
return true;
}
}
@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.symmetric(horizontal: 25.0),
child: TextField(
controller: controller,
readOnly: makeEditable(),
obscureText: false,
decoration: InputDecoration(
fillColor: Colors.white,