|
|
|
@ -9,6 +9,7 @@ import 'package:doctor_app_flutter/util/translations_delegate_base.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/Text.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/TextFields.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/master_key_checkbox_search_widget.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/network_base_view.dart';
|
|
|
|
|
import 'package:eva_icons_flutter/eva_icons_flutter.dart';
|
|
|
|
@ -49,28 +50,60 @@ class _UpdateHistoryWidgetState extends State<UpdateHistoryWidget>
|
|
|
|
|
ProjectViewModel projectViewModel = Provider.of(context);
|
|
|
|
|
return Column(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 10, right: 10, top: 15),
|
|
|
|
|
child: TextFields(
|
|
|
|
|
hintText: TranslationBase.of(context).addHistory,
|
|
|
|
|
borderColor: HexColor('#707070'),
|
|
|
|
|
borderWidth: 0.30,
|
|
|
|
|
fontSize: 13.5,
|
|
|
|
|
borderRadius: 12,
|
|
|
|
|
onTapTextFields: () {
|
|
|
|
|
openHistoryList(context);
|
|
|
|
|
},
|
|
|
|
|
suffixIcon: EvaIcons.plusCircleOutline,
|
|
|
|
|
suffixIconColor: Color(0xFF2B353E),
|
|
|
|
|
readOnly: true,
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
// controller: messageController,
|
|
|
|
|
validator: (value) {
|
|
|
|
|
if (value == null)
|
|
|
|
|
return TranslationBase.of(context).emptyMessage;
|
|
|
|
|
else
|
|
|
|
|
return null;
|
|
|
|
|
}),
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
openHistoryList(context);
|
|
|
|
|
},
|
|
|
|
|
child: Container(
|
|
|
|
|
padding: EdgeInsets.symmetric(
|
|
|
|
|
vertical: 8, horizontal: 8.0),
|
|
|
|
|
margin:
|
|
|
|
|
EdgeInsets.symmetric(vertical: 8),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
border: Border.all(
|
|
|
|
|
color: Colors.grey.shade400,
|
|
|
|
|
width: 0.5),
|
|
|
|
|
borderRadius: BorderRadius.all(
|
|
|
|
|
Radius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.spaceBetween,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.center,
|
|
|
|
|
children: [
|
|
|
|
|
Expanded(
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
"${TranslationBase.of(context).addHistory}",
|
|
|
|
|
fontSize: SizeConfig
|
|
|
|
|
.textMultiplier *
|
|
|
|
|
1.8,
|
|
|
|
|
color: Colors.black,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
"${TranslationBase.of(context).searchHere}",
|
|
|
|
|
fontSize: SizeConfig
|
|
|
|
|
.textMultiplier *
|
|
|
|
|
1.8,
|
|
|
|
|
color: Colors.grey.shade700,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
)),
|
|
|
|
|
Icon(
|
|
|
|
|
Icons.add_box_rounded,
|
|
|
|
|
size: 25,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
@ -143,10 +176,6 @@ class _UpdateHistoryWidgetState extends State<UpdateHistoryWidget>
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
removeHistory(MasterKeyModel historyKey) {
|
|
|
|
|
// Iterable<MasterKeyModel> history = widget.myHistoryList.where((element) =>
|
|
|
|
|
// masterKey.id == element.id && masterKey.typeId == element.typeId);
|
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
List<MySelectedHistory> history =
|
|
|
|
|
// ignore: missing_return
|
|
|
|
|
widget.myHistoryList.where((element) =>
|
|
|
|
|