UI_TCKT_MASTER
This commit is contained in:
parent
027e8942d3
commit
160b46652e
@ -297,7 +297,8 @@ class _claimtracklistformState extends State<claimtracklist> {
|
||||
right: 10),
|
||||
child: Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.center,
|
||||
CrossAxisAlignment.start,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
mainAxisAlignment:
|
||||
@ -353,58 +354,23 @@ class _claimtracklistformState extends State<claimtracklist> {
|
||||
height: Responsive.isDesktop(context)
|
||||
? 20
|
||||
: 20), // Space between rows
|
||||
Column(
|
||||
children: [
|
||||
Responsive.isDesktop(context)
|
||||
? buildDesktopLayout(context)
|
||||
: buildMobileLayout(context)
|
||||
],
|
||||
Container(
|
||||
child: Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.start,
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.start,
|
||||
children: [
|
||||
Responsive.isDesktop(context)
|
||||
? buildDesktopLayout(context)
|
||||
: buildMobileLayout(context)
|
||||
],
|
||||
),
|
||||
), // Space between rows
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(height: 15),
|
||||
Container(
|
||||
decoration: BoxDecoration(
|
||||
color: Color(
|
||||
0xFFFFFCE5), // Set background color for the container
|
||||
borderRadius: BorderRadius.circular(
|
||||
10), // Set border radius for the container
|
||||
),
|
||||
padding: Responsive.isDesktop(context)
|
||||
? EdgeInsets.only(
|
||||
top: 20,
|
||||
bottom: 20,
|
||||
left: 10,
|
||||
right: 10)
|
||||
: EdgeInsets.only(
|
||||
top: 10,
|
||||
bottom: 10,
|
||||
left: 10,
|
||||
right: 10),
|
||||
child: Column(
|
||||
children: [
|
||||
Row(
|
||||
children: [
|
||||
buildExpandedColumn(context,
|
||||
'Subject', policySubject),
|
||||
],
|
||||
),
|
||||
|
||||
SizedBox(
|
||||
height: 15,
|
||||
),
|
||||
Row(
|
||||
children: [
|
||||
buildExpandedColumn(context,
|
||||
'Message', policyMessage),
|
||||
],
|
||||
),
|
||||
// Add more rows as needed
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(height: 15),
|
||||
Container(
|
||||
decoration: BoxDecoration(
|
||||
// color: Color(
|
||||
@ -756,168 +722,259 @@ class _claimtracklistformState extends State<claimtracklist> {
|
||||
return formattedDate;
|
||||
}
|
||||
|
||||
// Widget buildDesktopLayout(BuildContext context) {
|
||||
// return Container(
|
||||
// color: Colors.redAccent.shade100,
|
||||
// child: Column(
|
||||
// // mainAxisAlignment: MainAxisAlignment.center,
|
||||
// // crossAxisAlignment: CrossAxisAlignment.center,
|
||||
// children: [
|
||||
// Container(
|
||||
// color: Colors.yellowAccent.shade100,
|
||||
// child: Row(
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Ticket No', policyTickID),
|
||||
// if (policyType != "Sales")
|
||||
// buildExpandedColumn(context, 'Policy No', policyName),
|
||||
// // buildExpandedColumn(context, 'Ticket Type', policyType),
|
||||
// buildExpandedColumn(context, 'Status', policyStatus),
|
||||
// // buildExpandedColumn(context, 'Message', policyMessage),
|
||||
// ],
|
||||
// ),
|
||||
// ),
|
||||
// if (departmentID == '4') // Conditional check for policy_type
|
||||
// Column(
|
||||
// children: [
|
||||
// SizedBox(height: 20),
|
||||
// Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Member', member),
|
||||
// buildExpandedColumn(context, 'Hospital Name', hospitalName),
|
||||
// buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
// ],
|
||||
// ),
|
||||
// SizedBox(height: 20),
|
||||
// Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Admit Date', admitDate),
|
||||
// buildExpandedColumn(
|
||||
// context, 'Discharge Date', dischargeDate),
|
||||
// buildExpandedColumn(context, '', ''),
|
||||
// ],
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// if (departmentID == '3') // Conditional check for policy_type
|
||||
// Column(
|
||||
// children: [
|
||||
// SizedBox(height: 20),
|
||||
// Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Member', member),
|
||||
// buildExpandedColumn(context, 'Accident Date', accidentDate),
|
||||
// buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
// ],
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// );
|
||||
// }
|
||||
|
||||
Widget buildDesktopLayout(BuildContext context) {
|
||||
return Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
Row(
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Ticket No', policyTickID),
|
||||
if (policyType != "Sales")
|
||||
buildExpandedColumn(context, 'Policy No', policyName),
|
||||
// buildExpandedColumn(context, 'Ticket Type', policyType),
|
||||
buildExpandedColumn(context, 'Status', policyStatus),
|
||||
// buildExpandedColumn(context, 'Message', policyMessage),
|
||||
],
|
||||
),
|
||||
if (departmentID == '4') // Conditional check for policy_type
|
||||
Column(
|
||||
children: [
|
||||
SizedBox(height: 20),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Member', member),
|
||||
buildExpandedColumn(context, 'Hospital Name', hospitalName),
|
||||
buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
],
|
||||
),
|
||||
SizedBox(height: 20),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Admit Date', admitDate),
|
||||
buildExpandedColumn(context, 'Discharge Date', dischargeDate),
|
||||
buildExpandedColumn(context, '', ''),
|
||||
],
|
||||
),
|
||||
],
|
||||
return Container(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Ticket No', policyTickID),
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
if (departmentID == '3') // Conditional check for policy_type
|
||||
Column(
|
||||
children: [
|
||||
SizedBox(height: 20),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Member', member),
|
||||
buildExpandedColumn(context, 'Accident Date', accidentDate),
|
||||
buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
],
|
||||
),
|
||||
],
|
||||
if (policyType != "Sales")
|
||||
buildExpandedColumn(context, 'Policy No', policyName),
|
||||
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
],
|
||||
buildExpandedColumn(context, 'Status', policyStatus),
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
buildExpandedColumn(context, 'Subject', policySubject),
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
buildExpandedColumn(context, 'Message', policyMessage),
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
// buildExpandedColumn(context, 'Message', policyMessage),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Widget buildMobileLayout(BuildContext context) {
|
||||
return SingleChildScrollView(
|
||||
child: Column(
|
||||
children: [
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Ticket No', policyTickID),
|
||||
if (policyType != "Sales")
|
||||
buildExpandedColumn(context, 'Policy No', policyName),
|
||||
if (policyType == "Sales")
|
||||
buildExpandedColumn(context, 'Status', policyStatus),
|
||||
],
|
||||
),
|
||||
SizedBox(height: 20),
|
||||
if (policyType != "Sales")
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Status', policyStatus),
|
||||
// buildExpandedColumn(context, 'Ticket Type', policyType),
|
||||
],
|
||||
child: Container(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Ticket No', policyTickID),
|
||||
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
if (departmentID == '4')
|
||||
Column(
|
||||
children: [
|
||||
SizedBox(height: 20),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
buildExpandedColumn(context, 'Hospital Name', hospitalName),
|
||||
],
|
||||
),
|
||||
SizedBox(height: 20),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Admit Date', admitDate),
|
||||
buildExpandedColumn(
|
||||
context, 'Discharge Date', dischargeDate),
|
||||
],
|
||||
),
|
||||
],
|
||||
if (policyType != "Sales")
|
||||
buildExpandedColumn(context, 'Policy No', policyName),
|
||||
|
||||
if (policyType != "Sales")
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
buildExpandedColumn(context, 'Status', policyStatus),
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
if (departmentID == '3')
|
||||
Column(
|
||||
children: [
|
||||
SizedBox(height: 20),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
buildExpandedColumn(context, 'Accident Date', accidentDate),
|
||||
],
|
||||
),
|
||||
],
|
||||
buildExpandedColumn(context, 'Subject', policySubject),
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
],
|
||||
buildExpandedColumn(context, 'Message', policyMessage),
|
||||
SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
|
||||
// SizedBox(height: 20),
|
||||
// if (policyType != "Sales")
|
||||
// Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Status', policyStatus),
|
||||
// // buildExpandedColumn(context, 'Ticket Type', policyType),
|
||||
// ],
|
||||
// ),
|
||||
// if (departmentID == '4')
|
||||
// Column(
|
||||
// children: [
|
||||
// SizedBox(height: 20),
|
||||
// Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
// buildExpandedColumn(
|
||||
// context, 'Hospital Name', hospitalName),
|
||||
// ],
|
||||
// ),
|
||||
// SizedBox(height: 20),
|
||||
// Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Admit Date', admitDate),
|
||||
// buildExpandedColumn(
|
||||
// context, 'Discharge Date', dischargeDate),
|
||||
// ],
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// if (departmentID == '3')
|
||||
// Column(
|
||||
// children: [
|
||||
// SizedBox(height: 20),
|
||||
// Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// children: [
|
||||
// buildExpandedColumn(context, 'Claim Amount', claimAmount),
|
||||
// buildExpandedColumn(
|
||||
// context, 'Accident Date', accidentDate),
|
||||
// ],
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Widget buildExpandedColumn(
|
||||
BuildContext context, String title, String? value) {
|
||||
return Expanded(
|
||||
flex: 3,
|
||||
child: Container(
|
||||
// alignment: Alignment.center,
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
title,
|
||||
textAlign: TextAlign.center,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: Responsive.isDesktop(context) ? 18 : 14,
|
||||
fontWeight: FontWeight.w400,
|
||||
color: Color(0xFF000000),
|
||||
),
|
||||
),
|
||||
SizedBox(height: Responsive.isDesktop(context) ? 10 : 4),
|
||||
title == 'Status'
|
||||
? Text(
|
||||
value ?? '', // Null check for value
|
||||
textAlign: TextAlign.center,
|
||||
return Container(
|
||||
// color: Colors.orange.shade100,
|
||||
width: Responsive.isDesktop(context)
|
||||
? MediaQuery.of(context).size.width * 0.6
|
||||
: MediaQuery.of(context).size.width * 1,
|
||||
// alignment: Alignment.center,
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Expanded(
|
||||
flex: 1,
|
||||
child: Container(
|
||||
// color: Colors.pink.shade100,
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
title,
|
||||
textAlign: TextAlign.start,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: Responsive.isDesktop(context) ? 18 : 16,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: getStatusColor(policyStatus),
|
||||
),
|
||||
)
|
||||
: Text(
|
||||
value ?? '', // Null check for value
|
||||
textAlign: TextAlign.center,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: Responsive.isDesktop(context) ? 18 : 16,
|
||||
fontWeight: FontWeight.w600,
|
||||
fontSize: Responsive.isDesktop(context) ? 14 : 12,
|
||||
fontWeight: FontWeight.w400,
|
||||
color: Color(0xFF000000),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
// SizedBox(width: Responsive.isDesktop(context) ? 10 : 4),
|
||||
Expanded(
|
||||
flex: 3,
|
||||
child: Container(
|
||||
// color: Colors.deepPurple.shade100,
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
title == 'Status'
|
||||
? Text(
|
||||
value ?? '', // Null check for value
|
||||
textAlign: TextAlign.start,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: Responsive.isDesktop(context) ? 14 : 12,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: getStatusColor(policyStatus),
|
||||
),
|
||||
)
|
||||
: Text(
|
||||
value ?? '', // Null check for value
|
||||
textAlign: TextAlign.start,
|
||||
softWrap: true,
|
||||
maxLines: 20,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: Responsive.isDesktop(context) ? 14 : 12,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Color(0xFF000000),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
// );
|
||||
}
|
||||
|
||||
Widget buildExpandedRow(BuildContext context, String title, String? value) {
|
||||
|
||||
@ -1572,18 +1572,33 @@ class _helpState extends State<help> {
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
'$claimsDepartmentName($claimsticket)' ??
|
||||
'',
|
||||
textAlign: TextAlign.left,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
Responsive.isDesktop(context)
|
||||
? 18
|
||||
: 16,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Color(0xFF000000),
|
||||
),
|
||||
Row(
|
||||
children: [
|
||||
Text(
|
||||
'$claimsDepartmentName' ?? '',
|
||||
textAlign: TextAlign.left,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: Responsive.isDesktop(
|
||||
context)
|
||||
? 16
|
||||
: 14,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Color(0xFF000000),
|
||||
),
|
||||
),
|
||||
Text(
|
||||
' (TCKT : $claimsticket)' ?? '',
|
||||
textAlign: TextAlign.left,
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: Responsive.isDesktop(
|
||||
context)
|
||||
? 14
|
||||
: 10,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.black87,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
SizedBox(height: 5),
|
||||
Container(
|
||||
|
||||
Loading…
Reference in New Issue
Block a user