|
|
|
|
@ -36,110 +36,124 @@ class _HospitalsLiveChatPageState extends State<HospitalsLiveChatPage> {
|
|
|
|
|
child: Container(
|
|
|
|
|
margin: EdgeInsets.only(left: 15, right: 15),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
height: 200,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
image: DecorationImage(
|
|
|
|
|
image: ExactAssetImage(
|
|
|
|
|
'assets/images/dashboard_top_bg.png'),
|
|
|
|
|
fit: BoxFit.cover),
|
|
|
|
|
),
|
|
|
|
|
child: Texts(
|
|
|
|
|
'You can now talk directly to the appointments department by chat or request a call back\n \nChoose Hospital :',
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
textAlign: TextAlign.center,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
///////////
|
|
|
|
|
...List.generate(
|
|
|
|
|
model.LiveChatModelList.length,
|
|
|
|
|
(index) => Container(
|
|
|
|
|
margin:
|
|
|
|
|
EdgeInsets.only(left: 20, right: 20, bottom: 20),
|
|
|
|
|
Stack(
|
|
|
|
|
children: [
|
|
|
|
|
Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
height: 200,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
|
border: Border.all(color: Colors.white, width: 0.5),
|
|
|
|
|
borderRadius: BorderRadius.all(Radius.circular(5)),
|
|
|
|
|
color: tappedIndex == index
|
|
|
|
|
? Colors.red
|
|
|
|
|
: Colors.white,
|
|
|
|
|
image: DecorationImage(
|
|
|
|
|
image: ExactAssetImage(
|
|
|
|
|
'assets/images/dashboard_top_bg.png'),
|
|
|
|
|
fit: BoxFit.cover),
|
|
|
|
|
),
|
|
|
|
|
child: Padding(
|
|
|
|
|
padding: const EdgeInsets.all(8.0),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
setState(() {
|
|
|
|
|
tappedIndex = index;
|
|
|
|
|
chat =
|
|
|
|
|
"http://chat.dshmg.com:7788/hmgchatapp/hmgchattest/Index.aspx?Name=${model.user.firstName}&PatientID=${model.user.patientID}&MobileNo=${model.user.mobileNumber}&Language=en&WorkGroup=${model.LiveChatModelList[index].value}";
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.end,
|
|
|
|
|
child: Texts(
|
|
|
|
|
'You can now talk directly to the appointments department by chat or request a call back\n \nChoose Hospital :',
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
textAlign: TextAlign.start,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(height: MediaQuery.of(context).size.height*0.85,),
|
|
|
|
|
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 100,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Positioned(
|
|
|
|
|
left: 13,
|
|
|
|
|
right: 13,
|
|
|
|
|
top:200,
|
|
|
|
|
child: Container(width: double.maxFinite,
|
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
...List.generate(
|
|
|
|
|
model.LiveChatModelList.length,
|
|
|
|
|
(index) => Container(
|
|
|
|
|
margin:
|
|
|
|
|
EdgeInsets.only(left: 0, right: 0, bottom: 20),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
|
border: Border.all(color: Colors.white, width: 0.5),
|
|
|
|
|
borderRadius: BorderRadius.all(Radius.circular(5)),
|
|
|
|
|
color: tappedIndex == index
|
|
|
|
|
? Colors.red
|
|
|
|
|
: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
child: Padding(
|
|
|
|
|
padding: const EdgeInsets.all(8.0),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Expanded(
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.spaceAround,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.center,
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
setState(() {
|
|
|
|
|
tappedIndex = index;
|
|
|
|
|
chat =
|
|
|
|
|
"http://chat.dshmg.com:7788/hmgchatapp/hmgchattest/Index.aspx?Name=${model.user.firstName}&PatientID=${model.user.patientID}&MobileNo=${model.user.mobileNumber}&Language=en&WorkGroup=${model.LiveChatModelList[index].value}";
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
child:Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
SizedBox(width: 20,),
|
|
|
|
|
Expanded(
|
|
|
|
|
flex: 4,
|
|
|
|
|
|
|
|
|
|
child: Container(
|
|
|
|
|
margin: EdgeInsets.only(
|
|
|
|
|
left: 5, right: 5),
|
|
|
|
|
child: Texts(
|
|
|
|
|
'${model.LiveChatModelList[index].projectName}',
|
|
|
|
|
color:
|
|
|
|
|
tappedIndex == index
|
|
|
|
|
? Colors.white
|
|
|
|
|
: Colors.black,
|
|
|
|
|
tappedIndex == index
|
|
|
|
|
? Colors.white
|
|
|
|
|
: Colors.black,
|
|
|
|
|
textAlign:
|
|
|
|
|
TextAlign.center,
|
|
|
|
|
TextAlign.center,
|
|
|
|
|
))), //model.cOCItemList[index].cOCTitl
|
|
|
|
|
Expanded(
|
|
|
|
|
flex: 1,
|
|
|
|
|
child: Row(
|
|
|
|
|
children: [
|
|
|
|
|
IconButton(
|
|
|
|
|
icon: Icon(
|
|
|
|
|
Icons
|
|
|
|
|
.arrow_forward_rounded,
|
|
|
|
|
color:
|
|
|
|
|
tappedIndex == index
|
|
|
|
|
? Colors.white
|
|
|
|
|
: Colors.black,
|
|
|
|
|
),
|
|
|
|
|
tooltip: '',
|
|
|
|
|
onPressed: () {
|
|
|
|
|
setState(() {});
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
IconButton(
|
|
|
|
|
icon: Icon(
|
|
|
|
|
Icons
|
|
|
|
|
.arrow_forward_rounded,
|
|
|
|
|
color:
|
|
|
|
|
tappedIndex == index
|
|
|
|
|
? Colors.white
|
|
|
|
|
: Colors.black,
|
|
|
|
|
),
|
|
|
|
|
tooltip: '',
|
|
|
|
|
onPressed: () {
|
|
|
|
|
setState(() {});
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 100,
|
|
|
|
|
),
|
|
|
|
|
)),
|
|
|
|
|
],
|
|
|
|
|
),),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
height: MediaQuery.of(context).size.height * 0.20,
|
|
|
|
|
width: double.maxFinite,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
@ -167,3 +181,7 @@ class _HospitalsLiveChatPageState extends State<HospitalsLiveChatPage> {
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|