|
|
|
|
@ -89,7 +89,10 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
},
|
|
|
|
|
child: AppScaffold(
|
|
|
|
|
baseViewModel: model2,
|
|
|
|
|
isShowAppBar: false,
|
|
|
|
|
appBarTitle: widget.isExtended == true
|
|
|
|
|
? TranslationBase.of(context).extendSickLeave
|
|
|
|
|
: TranslationBase.of(context).addSickLeave,
|
|
|
|
|
isShowAppBar: true,
|
|
|
|
|
body: Center(
|
|
|
|
|
child: Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10),
|
|
|
|
|
@ -97,29 +100,40 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
widthFactor: 0.9,
|
|
|
|
|
child: ListView(
|
|
|
|
|
children: [
|
|
|
|
|
Padding(
|
|
|
|
|
child: AppText(
|
|
|
|
|
widget.isExtended == true
|
|
|
|
|
? TranslationBase.of(context)
|
|
|
|
|
.extendSickLeave
|
|
|
|
|
: TranslationBase.of(context)
|
|
|
|
|
.addSickLeave,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
),
|
|
|
|
|
padding: EdgeInsets.all(10)),
|
|
|
|
|
// Padding(
|
|
|
|
|
// child: AppText(
|
|
|
|
|
// widget.isExtended == true
|
|
|
|
|
// ? TranslationBase.of(context)
|
|
|
|
|
// .extendSickLeave
|
|
|
|
|
// : TranslationBase.of(context)
|
|
|
|
|
// .addSickLeave,
|
|
|
|
|
// fontWeight: FontWeight.bold,
|
|
|
|
|
// ),
|
|
|
|
|
// padding: EdgeInsets.all(10)),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 10, right: 10),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.all(Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0,
|
|
|
|
|
color: HexColor("#CCCCCC"))),
|
|
|
|
|
width: 1.0,
|
|
|
|
|
color: HexColor("#CCCCCC"),
|
|
|
|
|
),
|
|
|
|
|
color: Colors.white),
|
|
|
|
|
padding: EdgeInsets.all(5),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
|
top: 5, left: 10, right: 10),
|
|
|
|
|
child: AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.sickLeave +
|
|
|
|
|
' ' +
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.days)),
|
|
|
|
|
AppTextFormField(
|
|
|
|
|
borderColor: Colors.white,
|
|
|
|
|
onChanged: (value) {
|
|
|
|
|
@ -132,8 +146,7 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
hintText: widget.extendedData != null
|
|
|
|
|
? widget.extendedData.noOfDays
|
|
|
|
|
.toString()
|
|
|
|
|
: TranslationBase.of(context)
|
|
|
|
|
.sickLeaveDays,
|
|
|
|
|
: '',
|
|
|
|
|
// validator: (value) {
|
|
|
|
|
// return TextValidator().validateName(value);
|
|
|
|
|
// },
|
|
|
|
|
@ -146,25 +159,28 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 10, right: 10),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
borderRadius: BorderRadius.all(
|
|
|
|
|
Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0,
|
|
|
|
|
color: HexColor("#CCCCCC"))),
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.all(Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0, color: HexColor("#CCCCCC")),
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
padding: EdgeInsets.all(5),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
// AppText(
|
|
|
|
|
// TranslationBase.of(context).sickLeaveDate,
|
|
|
|
|
// fontSize: 10,
|
|
|
|
|
// ),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
|
top: 5, left: 10, right: 10),
|
|
|
|
|
child: AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.sickLeaveDate,
|
|
|
|
|
)),
|
|
|
|
|
AppTextFormField(
|
|
|
|
|
hintText: widget.extendedData != null
|
|
|
|
|
? widget.extendedData.startDate
|
|
|
|
|
: TranslationBase.of(context)
|
|
|
|
|
.sickLeaveDate,
|
|
|
|
|
: '',
|
|
|
|
|
borderColor: Colors.white,
|
|
|
|
|
prefix: IconButton(
|
|
|
|
|
icon: Icon(Icons.calendar_today)),
|
|
|
|
|
@ -188,11 +204,12 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
margin: EdgeInsets.only(
|
|
|
|
|
top: 10, left: 10, right: 10),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
borderRadius: BorderRadius.all(
|
|
|
|
|
Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0,
|
|
|
|
|
color: HexColor("#CCCCCC"))),
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.all(Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0, color: HexColor("#CCCCCC")),
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
child: Padding(
|
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
|
@ -205,10 +222,12 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
// AppText(
|
|
|
|
|
// TranslationBase.of(context).clinicName,
|
|
|
|
|
// fontSize: 10,
|
|
|
|
|
// ),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.only(top: 5),
|
|
|
|
|
child: AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.clinicName,
|
|
|
|
|
)),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisSize: MainAxisSize.max,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
@ -291,19 +310,23 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 10, right: 10),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.all(Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0,
|
|
|
|
|
color: HexColor("#CCCCCC"))),
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.all(Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0, color: HexColor("#CCCCCC")),
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
padding: EdgeInsets.all(5),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
// AppText(
|
|
|
|
|
// TranslationBase.of(context).doctorName,
|
|
|
|
|
// fontSize: 10,
|
|
|
|
|
// ),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
|
top: 5, left: 10, right: 10),
|
|
|
|
|
child: AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.doctorName,
|
|
|
|
|
)),
|
|
|
|
|
new IgnorePointer(
|
|
|
|
|
ignoring: true,
|
|
|
|
|
child: AppTextFormField(
|
|
|
|
|
@ -324,19 +347,22 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 10, right: 10),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.all(Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0,
|
|
|
|
|
color: HexColor("#CCCCCC"))),
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.all(Radius.circular(6.0)),
|
|
|
|
|
border: Border.all(
|
|
|
|
|
width: 1.0, color: HexColor("#CCCCCC")),
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
padding: EdgeInsets.all(5),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
// AppText(
|
|
|
|
|
// TranslationBase.of(context).remarks,
|
|
|
|
|
// fontSize: 10,
|
|
|
|
|
// ),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
|
top: 5, left: 10, right: 10),
|
|
|
|
|
child: AppText(
|
|
|
|
|
TranslationBase.of(context).remarks,
|
|
|
|
|
)),
|
|
|
|
|
TextField(
|
|
|
|
|
maxLines: 3,
|
|
|
|
|
decoration: InputDecoration(
|
|
|
|
|
@ -344,8 +370,7 @@ class _SickLeaveScreenState extends State<SickLeaveScreen> {
|
|
|
|
|
border: InputBorder.none,
|
|
|
|
|
hintText: widget.extendedData != null
|
|
|
|
|
? widget.extendedData.remarks
|
|
|
|
|
: TranslationBase.of(context)
|
|
|
|
|
.remarks),
|
|
|
|
|
: ''),
|
|
|
|
|
onChanged: (value) {
|
|
|
|
|
addSickLeave.remarks = value;
|
|
|
|
|
if (widget.extendedData != null) {
|
|
|
|
|
|