|
|
|
@ -1,4 +1,5 @@
|
|
|
|
|
import 'package:doctor_app_flutter/config/size_config.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/core/viewModel/project_view_model.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/icons_app/doctor_app_icons.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/models/patient/my_referral/PendingReferral.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/util/translations_delegate_base.dart';
|
|
|
|
@ -7,6 +8,7 @@ import 'package:doctor_app_flutter/widgets/shared/card_with_bg_widget.dart';
|
|
|
|
|
import 'package:flutter/cupertino.dart';
|
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
|
import 'package:font_awesome_flutter/font_awesome_flutter.dart';
|
|
|
|
|
import 'package:provider/provider.dart';
|
|
|
|
|
|
|
|
|
|
class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
final String patientName;
|
|
|
|
@ -39,6 +41,8 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
|
ProjectViewModel projectViewModel = Provider.of(context);
|
|
|
|
|
|
|
|
|
|
return Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 16.0, right: 16.0, top: 8.0),
|
|
|
|
|
child: Column(
|
|
|
|
@ -298,7 +302,8 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
: Colors.grey[500],
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
fontSize: 2.0 * SizeConfig.textMultiplier)),
|
|
|
|
|
fontSize:
|
|
|
|
|
2.0 * SizeConfig.textMultiplier)),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
@ -325,15 +330,15 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
SizedBox(
|
|
|
|
|
width: 4,
|
|
|
|
|
),
|
|
|
|
|
/*patient.gender*/1 == 1
|
|
|
|
|
/*patient.gender*/ 1 == 1
|
|
|
|
|
? Icon(
|
|
|
|
|
DoctorApp.male_2,
|
|
|
|
|
color: Colors.blue,
|
|
|
|
|
)
|
|
|
|
|
DoctorApp.male_2,
|
|
|
|
|
color: Colors.blue,
|
|
|
|
|
)
|
|
|
|
|
: Icon(
|
|
|
|
|
DoctorApp.female_1,
|
|
|
|
|
color: Colors.pink,
|
|
|
|
|
),
|
|
|
|
|
DoctorApp.female_1,
|
|
|
|
|
color: Colors.pink,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
@ -351,7 +356,8 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
color: Colors.black),
|
|
|
|
|
children: <TextSpan>[
|
|
|
|
|
new TextSpan(
|
|
|
|
|
text: TranslationBase.of(context).fileNumber,
|
|
|
|
|
text: TranslationBase.of(context)
|
|
|
|
|
.fileNumber,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 14, fontFamily: 'Poppins')),
|
|
|
|
|
new TextSpan(
|
|
|
|
@ -371,13 +377,17 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
color: Colors.black),
|
|
|
|
|
children: <TextSpan>[
|
|
|
|
|
new TextSpan(
|
|
|
|
|
text: TranslationBase.of(context).referredFrom,
|
|
|
|
|
text: TranslationBase.of(context)
|
|
|
|
|
.referredFrom,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 14, fontFamily: 'Poppins')),
|
|
|
|
|
fontSize: 14,
|
|
|
|
|
fontFamily: 'Poppins')),
|
|
|
|
|
new TextSpan(
|
|
|
|
|
text: isSameBranch
|
|
|
|
|
? TranslationBase.of(context).sameBranch
|
|
|
|
|
: TranslationBase.of(context).otherBranch,
|
|
|
|
|
? TranslationBase.of(context)
|
|
|
|
|
.sameBranch
|
|
|
|
|
: TranslationBase.of(context)
|
|
|
|
|
.otherBranch,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
@ -392,11 +402,12 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
/*patient.nationalityName ??
|
|
|
|
|
patient.nationality*/ "Saudi",
|
|
|
|
|
patient.nationality*/
|
|
|
|
|
"Saudi",
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
),
|
|
|
|
|
/* patient.nationality != null
|
|
|
|
|
/* patient.nationality != null
|
|
|
|
|
? ClipRRect(
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius
|
|
|
|
@ -418,7 +429,7 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
'No Image');
|
|
|
|
|
},
|
|
|
|
|
))*/
|
|
|
|
|
/*:*/ SizedBox()
|
|
|
|
|
/*:*/ SizedBox()
|
|
|
|
|
],
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
@ -445,32 +456,56 @@ class PatientReferralItemWidget extends StatelessWidget {
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
Column(
|
|
|
|
|
Row(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
RichText(
|
|
|
|
|
text: TextSpan(
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 2.0 * SizeConfig.textMultiplier,
|
|
|
|
|
color: Colors.black),
|
|
|
|
|
children: <TextSpan>[
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: TranslationBase.of(context)
|
|
|
|
|
.referralDoctor +
|
|
|
|
|
" : ",
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 14, fontFamily: 'Poppins')),
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: referralDoctorName,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
fontSize: 15)),
|
|
|
|
|
],
|
|
|
|
|
Container(
|
|
|
|
|
width: 30,
|
|
|
|
|
height: 30,
|
|
|
|
|
margin: EdgeInsets.only(
|
|
|
|
|
left: projectViewModel.isArabic ? 10 : 10 /*10:85*/,
|
|
|
|
|
right: projectViewModel.isArabic ? 10 : 10 /*85:10*/,
|
|
|
|
|
top: 5),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
|
border: Border(
|
|
|
|
|
bottom:
|
|
|
|
|
BorderSide(color: Colors.grey[400], width: 2.5),
|
|
|
|
|
left:
|
|
|
|
|
BorderSide(color: Colors.grey[400], width: 2.5),
|
|
|
|
|
)),
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
flex: 4,
|
|
|
|
|
child: Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 10, top: 25, right : 10, bottom: 0),
|
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
RichText(
|
|
|
|
|
text: TextSpan(
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 2.0 * SizeConfig.textMultiplier,
|
|
|
|
|
color: Colors.black),
|
|
|
|
|
children: <TextSpan>[
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: TranslationBase.of(context)
|
|
|
|
|
.referralDoctor +
|
|
|
|
|
" : ",
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 14, fontFamily: 'Poppins')),
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: referralDoctorName,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
fontSize: 15)),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|