You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
diplomatic-quarter/lib/pages/ChildVaccines/vaccinationtable_page.dart

105 lines
4.0 KiB
Dart

import 'package:diplomaticquarterapp/core/viewModels/child_vaccines/vaccination_table_view_model.dart';
import 'package:diplomaticquarterapp/core/viewModels/medical/reports_monthly_view_model.dart';
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_html/flutter_html.dart';
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
import 'dialogs/SelectGenderDialog.dart';
class VaccinationTablePage extends StatelessWidget {
@override
Widget build(BuildContext context) {
var checkedValue;
return BaseView<VaccinationTableViewModel>(
onModelReady: (model) => model.getCreateVaccinationTable(),//getUserTermsAndConditions(),
builder: (_, model, w) => AppScaffold(
isShowAppBar: true,
baseViewModel: model,
appBarTitle: "Vaccination",
body: SingleChildScrollView(
child:Container(
margin: EdgeInsets.only(left: 15,right: 15,top: 70),
child: Column(
children: [//babyInformationModelList.length
...List.generate(model.creteVaccinationTableModelList.length, (index) =>
Container(
decoration: BoxDecoration(
shape: BoxShape.rectangle,
border: Border.all(color: Colors.white, width: 0.5),
borderRadius: BorderRadius.all(Radius.circular(5)),
color: Colors.white,
),
padding: EdgeInsets.all(12),
width: double.infinity,
child: Column(
children: [
Row(children: [
Text(model.creteVaccinationTableModelList[index].visit),
SizedBox(width: 10,),
Expanded(
child: Column(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Html(
// data:"<html><head><style type='text/css'>.Test {list-style-image:url('http://10.50.100.198:4444/Images/Bullet_List_Small.png');}</style></head><body><table><tr align='left'><td align='left'>BCG</td></tr><tr align='left'><td align='left'>HEPATITIS B</td></tr></table></body></html>"//model.creteVaccinationTableModelList[index].vaccinesDescription
data:model.creteVaccinationTableModelList[index].vaccinesDescription,
),
],),
),
Text(model.creteVaccinationTableModelList[index].givenAt),
],),
Divider(color:Colors.black ,),
],
)
)
)
],
),
),
),
bottomSheet: Container(
height: MediaQuery.of(context).size.height * 0.12,
width: double.infinity,
padding: EdgeInsets.all(12),
child: SecondaryButton(
textColor: Colors.white,
color: checkedValue== false ?Colors.white24:Color.fromRGBO(63, 72, 74, 1,),
label: "Send Email ",
//
onTap: () {
//SelectGenderDialog();
//===============
showDialog(
context: context,
child: SelectGenderDialog(
),
);
//=========
}
),
),
),
);
}
}