CHANGE_
This commit is contained in:
parent
17280b1bb8
commit
653dd27018
Binary file not shown.
4649
lib/addons.dart
4649
lib/addons.dart
File diff suppressed because it is too large
Load Diff
@ -15,7 +15,7 @@ class CustomAppBar extends StatefulWidget implements PreferredSizeWidget {
|
|||||||
|
|
||||||
class _CustomAppBarState extends State<CustomAppBar> {
|
class _CustomAppBarState extends State<CustomAppBar> {
|
||||||
bool showBackToHR = true;
|
bool showBackToHR = true;
|
||||||
bool hideInactiveStatus = true;
|
// bool hideInactiveStatus = true;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
@ -32,7 +32,7 @@ class _CustomAppBarState extends State<CustomAppBar> {
|
|||||||
showBackToHR = (hrtoken != null && hrtoken.isNotEmpty) &&
|
showBackToHR = (hrtoken != null && hrtoken.isNotEmpty) &&
|
||||||
(token != null && token.isNotEmpty);
|
(token != null && token.isNotEmpty);
|
||||||
|
|
||||||
hideInactiveStatus = token != null && token.isNotEmpty;
|
// hideInactiveStatus = token != null && token.isNotEmpty;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -113,14 +113,14 @@ class _CustomAppBarState extends State<CustomAppBar> {
|
|||||||
Container(), // Set an empty container as we have the logo separately
|
Container(), // Set an empty container as we have the logo separately
|
||||||
title: Text(''),
|
title: Text(''),
|
||||||
navBarItems: [
|
navBarItems: [
|
||||||
if (Responsive.isDesktop(context))
|
// if (Responsive.isDesktop(context))
|
||||||
if (hideInactiveStatus)
|
// if (hideInactiveStatus)
|
||||||
NavBarItem(
|
// NavBarItem(
|
||||||
text: "Inactive Policy",
|
// text: "Inactive Policy",
|
||||||
onTap: () {
|
// onTap: () {
|
||||||
Navigator.pushNamed(context, 'oldPolicy');
|
// Navigator.pushNamed(context, 'oldPolicy');
|
||||||
},
|
// },
|
||||||
),
|
// ),
|
||||||
if (showBackToHR)
|
if (showBackToHR)
|
||||||
NavBarItem(
|
NavBarItem(
|
||||||
text: "Back To HR",
|
text: "Back To HR",
|
||||||
|
|||||||
23
lib/customAppBar/customFooter.dart
Normal file
23
lib/customAppBar/customFooter.dart
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
class CustomFooter extends StatelessWidget {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return Container(
|
||||||
|
padding: EdgeInsets.all(8.0),
|
||||||
|
color: Color(0xFFFFFBDE), // Background color of the footer
|
||||||
|
child: Column(
|
||||||
|
mainAxisSize: MainAxisSize.min,
|
||||||
|
children: [
|
||||||
|
Text(
|
||||||
|
'Copyright@ 2024 Nhance - Jubiliant',
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 14,
|
||||||
|
color: Colors.grey[600], // Text color
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -17,6 +17,8 @@ import 'dart:async';
|
|||||||
import 'package:nhancepolicy/responsive.dart';
|
import 'package:nhancepolicy/responsive.dart';
|
||||||
import 'package:url_launcher/url_launcher.dart';
|
import 'package:url_launcher/url_launcher.dart';
|
||||||
|
|
||||||
|
import 'customAppBar/customFooter.dart';
|
||||||
|
|
||||||
class empDetails extends StatefulWidget {
|
class empDetails extends StatefulWidget {
|
||||||
const empDetails({Key? key}) : super(key: key);
|
const empDetails({Key? key}) : super(key: key);
|
||||||
|
|
||||||
@ -682,6 +684,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
children: [
|
children: [
|
||||||
Card(
|
Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Container(
|
child: Container(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
height: 75,
|
height: 75,
|
||||||
@ -753,6 +756,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
SizedBox(height: 16),
|
SizedBox(height: 16),
|
||||||
Card(
|
Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Container(
|
child: Container(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
height: MediaQuery.of(context).size.height,
|
height: MediaQuery.of(context).size.height,
|
||||||
@ -798,6 +802,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
children: [
|
children: [
|
||||||
Card(
|
Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Container(
|
child: Container(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
height: 75,
|
height: 75,
|
||||||
@ -870,6 +875,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
if (gpaPolicies != null && gpaPolicies.length > 0)
|
if (gpaPolicies != null && gpaPolicies.length > 0)
|
||||||
Card(
|
Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: Responsive.isDesktop(context)
|
padding: Responsive.isDesktop(context)
|
||||||
? EdgeInsets.all(30)
|
? EdgeInsets.all(30)
|
||||||
@ -1224,6 +1230,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
if (gmcPolicies != null && gmcPolicies.length > 0)
|
if (gmcPolicies != null && gmcPolicies.length > 0)
|
||||||
Card(
|
Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Container(
|
child: Container(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
height: 75,
|
height: 75,
|
||||||
@ -1266,13 +1273,14 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
SizedBox(height: 30),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
if (isLoading)
|
if (isLoading)
|
||||||
Container(
|
Container(
|
||||||
color: Color(0xFFFFFCE5), // Semi-transparent background
|
color: Color(0x98FFFCE5), // Semi-transparent background
|
||||||
child: Center(
|
child: Center(
|
||||||
child: // Your GIF loader widget
|
child: // Your GIF loader widget
|
||||||
Image.asset(
|
Image.asset(
|
||||||
@ -1281,6 +1289,13 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
'assets/nhance-loader.gif'), // Adjust path to your GIF loader
|
'assets/nhance-loader.gif'), // Adjust path to your GIF loader
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
Align(
|
||||||
|
alignment: Alignment.bottomCenter,
|
||||||
|
child: Container(
|
||||||
|
width: double.infinity, // Make the footer full width
|
||||||
|
child: CustomFooter(),
|
||||||
|
),
|
||||||
|
),
|
||||||
]));
|
]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1348,6 +1363,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
child: SingleChildScrollView(
|
child: SingleChildScrollView(
|
||||||
child: Card(
|
child: Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: Responsive.isDesktop(context)
|
padding: Responsive.isDesktop(context)
|
||||||
? EdgeInsets.all(30)
|
? EdgeInsets.all(30)
|
||||||
@ -1602,6 +1618,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
child: SingleChildScrollView(
|
child: SingleChildScrollView(
|
||||||
child: Card(
|
child: Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: Responsive.isDesktop(context)
|
padding: Responsive.isDesktop(context)
|
||||||
? EdgeInsets.all(30)
|
? EdgeInsets.all(30)
|
||||||
@ -2216,6 +2233,7 @@ class _empDetailsState extends State<empDetails> {
|
|||||||
|
|
||||||
Widget card = Card(
|
Widget card = Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: Responsive.isDesktop(context)
|
padding: Responsive.isDesktop(context)
|
||||||
? EdgeInsets.all(30)
|
? EdgeInsets.all(30)
|
||||||
|
|||||||
3193
lib/empReview.dart
3193
lib/empReview.dart
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -11,6 +11,7 @@ import 'package:nhancepolicy/service/api_service.dart';
|
|||||||
import 'package:shared_preferences/shared_preferences.dart';
|
import 'package:shared_preferences/shared_preferences.dart';
|
||||||
import 'package:http/http.dart' as http;
|
import 'package:http/http.dart' as http;
|
||||||
import 'customAppBar/customAppBar.dart';
|
import 'customAppBar/customAppBar.dart';
|
||||||
|
import 'customAppBar/customFooter.dart';
|
||||||
import 'customAppBar/toastHelper.dart';
|
import 'customAppBar/toastHelper.dart';
|
||||||
import 'package:universal_html/html.dart' as html;
|
import 'package:universal_html/html.dart' as html;
|
||||||
import 'package:intl/intl.dart';
|
import 'package:intl/intl.dart';
|
||||||
@ -24,10 +25,10 @@ class hrDashboard extends StatefulWidget {
|
|||||||
|
|
||||||
class _hrDashboardState extends State<hrDashboard> {
|
class _hrDashboardState extends State<hrDashboard> {
|
||||||
late ApiService apiService;
|
late ApiService apiService;
|
||||||
bool isLoading = true;
|
bool isLoading = false;
|
||||||
late String _token;
|
late String _token;
|
||||||
dynamic getPolicyNo;
|
dynamic getPolicyNo;
|
||||||
bool _isLoading = false;
|
// bool _isLoading = false;
|
||||||
dynamic getPolicyNameDetails;
|
dynamic getPolicyNameDetails;
|
||||||
dynamic clintID;
|
dynamic clintID;
|
||||||
dynamic policy_name;
|
dynamic policy_name;
|
||||||
@ -41,17 +42,18 @@ class _hrDashboardState extends State<hrDashboard> {
|
|||||||
Color(0xFFDBFFDE),
|
Color(0xFFDBFFDE),
|
||||||
Color(0xFFE4DFFF),
|
Color(0xFFE4DFFF),
|
||||||
];
|
];
|
||||||
|
ScrollController _scrollController = ScrollController();
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
apiService = ApiService(context); // Initialize ApiService here
|
apiService = ApiService(context); // Initialize ApiService here
|
||||||
_loadToken();
|
_loadToken();
|
||||||
Future.delayed(Duration(seconds: 3), () {
|
// Future.delayed(Duration(seconds: 3), () {
|
||||||
setState(() {
|
// setState(() {
|
||||||
isLoading = false;
|
// isLoading = false;
|
||||||
});
|
// });
|
||||||
});
|
// });
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@ -134,9 +136,10 @@ class _hrDashboardState extends State<hrDashboard> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Future<void> getCashDepositDetails(String clintID) async {
|
Future<void> getCashDepositDetails(String clintID) async {
|
||||||
setState(() {
|
isLoading = true;
|
||||||
_isLoading = true;
|
// setState(() {
|
||||||
});
|
// _isLoading = true;
|
||||||
|
// });
|
||||||
try {
|
try {
|
||||||
if (clintID == null || empRefId == null) {
|
if (clintID == null || empRefId == null) {
|
||||||
return;
|
return;
|
||||||
@ -144,6 +147,7 @@ class _hrDashboardState extends State<hrDashboard> {
|
|||||||
final response =
|
final response =
|
||||||
await apiService.getCashDepositDetailsToApi(clintID!, empRefId!);
|
await apiService.getCashDepositDetailsToApi(clintID!, empRefId!);
|
||||||
if (response['status'] == 'success') {
|
if (response['status'] == 'success') {
|
||||||
|
isLoading = false;
|
||||||
setState(() {
|
setState(() {
|
||||||
getCardArrays = List<Map<String, dynamic>>.from(response['data']);
|
getCardArrays = List<Map<String, dynamic>>.from(response['data']);
|
||||||
print(getCardArrays);
|
print(getCardArrays);
|
||||||
@ -223,12 +227,13 @@ class _hrDashboardState extends State<hrDashboard> {
|
|||||||
SingleChildScrollView(
|
SingleChildScrollView(
|
||||||
child: Container(
|
child: Container(
|
||||||
padding:
|
padding:
|
||||||
EdgeInsets.only(top: 30, bottom: 30, left: 50, right: 50),
|
EdgeInsets.only(top: 30, bottom: 200, left: 50, right: 50),
|
||||||
color: Color(0xFFEFF3F6),
|
color: Color(0xFFEFF3F6),
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
Card(
|
Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
|
color: Colors.white,
|
||||||
child: Container(
|
child: Container(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
height: 75,
|
height: 75,
|
||||||
@ -298,321 +303,335 @@ class _hrDashboardState extends State<hrDashboard> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
SizedBox(height: 16),
|
SizedBox(height: 16),
|
||||||
|
// if (getCardArrays.length != 0)
|
||||||
|
// Card(
|
||||||
|
// elevation: 0,
|
||||||
|
// color: Colors.white,
|
||||||
|
// child: Container(
|
||||||
|
// width: double.infinity,
|
||||||
|
// padding: Responsive.isDesktop(context)
|
||||||
|
// ? EdgeInsets.all(20)
|
||||||
|
// : EdgeInsets.all(
|
||||||
|
// 10), // Add padding to the container
|
||||||
|
// child: Column(children: [
|
||||||
|
// Row(children: [
|
||||||
|
// Text(
|
||||||
|
// 'Cash Transaction',
|
||||||
|
// style: GoogleFonts.poppins(
|
||||||
|
// fontSize: 18,
|
||||||
|
// fontWeight: FontWeight.w600,
|
||||||
|
// color: Colors.black,
|
||||||
|
// ),
|
||||||
|
// )
|
||||||
|
// ]),
|
||||||
|
// SizedBox(height: 8),
|
||||||
|
// Row(
|
||||||
|
// children: [
|
||||||
|
// // Create an Expanded widget with flex of 4 for each card
|
||||||
|
// for (var cardData in getCardArrays)
|
||||||
|
// Container(
|
||||||
|
// width:
|
||||||
|
// 300, // Set a fixed width for the card
|
||||||
|
// height: cardHeight,
|
||||||
|
// child: Card(
|
||||||
|
// elevation: 3,
|
||||||
|
// color: cardColors[
|
||||||
|
// getCardArrays.indexOf(cardData) %
|
||||||
|
// cardColors.length],
|
||||||
|
// child: Column(
|
||||||
|
// crossAxisAlignment:
|
||||||
|
// CrossAxisAlignment.start,
|
||||||
|
// children: [
|
||||||
|
// ListTile(
|
||||||
|
// title: SizedBox(
|
||||||
|
// height: 50,
|
||||||
|
// child: Text(
|
||||||
|
// cardData['insurerName'],
|
||||||
|
// style: GoogleFonts.poppins(
|
||||||
|
// fontSize: 18,
|
||||||
|
// fontWeight: FontWeight.w500,
|
||||||
|
// color: Color(0xFF000000),
|
||||||
|
// height: 1.5,
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// subtitle: Text(
|
||||||
|
// 'Balance: ₹ ${cardData['balance']}',
|
||||||
|
// style: GoogleFonts.poppins(
|
||||||
|
// fontSize: 16,
|
||||||
|
// fontWeight: FontWeight.w400,
|
||||||
|
// color: Color(0xFF000000),
|
||||||
|
// height: 1.5,
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// SizedBox(height: 10),
|
||||||
|
// Padding(
|
||||||
|
// padding: EdgeInsets.symmetric(
|
||||||
|
// horizontal: 15),
|
||||||
|
// child: GestureDetector(
|
||||||
|
// onTap: () {
|
||||||
|
// openForm(
|
||||||
|
// cardData['depositData'],
|
||||||
|
// cardData['insurerName'],
|
||||||
|
// cardData['clientId'],
|
||||||
|
// cardData['insurerId'],
|
||||||
|
// cardColors[getCardArrays
|
||||||
|
// .indexOf(cardData) %
|
||||||
|
// cardColors.length],
|
||||||
|
// );
|
||||||
|
// },
|
||||||
|
// child: MouseRegion(
|
||||||
|
// cursor:
|
||||||
|
// SystemMouseCursors.click,
|
||||||
|
// child: Align(
|
||||||
|
// alignment:
|
||||||
|
// Alignment.centerRight,
|
||||||
|
// child: Text(
|
||||||
|
// 'View Details',
|
||||||
|
// style:
|
||||||
|
// GoogleFonts.poppins(
|
||||||
|
// color:
|
||||||
|
// Color(0xFF000000),
|
||||||
|
// fontSize: 14,
|
||||||
|
// fontWeight:
|
||||||
|
// FontWeight.w300,
|
||||||
|
// height: 1.5,
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ],
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
// ],
|
||||||
|
// ),
|
||||||
|
// ])),
|
||||||
|
// ),
|
||||||
|
// SizedBox(height: 16),
|
||||||
if (getCardArrays.length != 0)
|
if (getCardArrays.length != 0)
|
||||||
Card(
|
Card(
|
||||||
elevation: 0,
|
elevation: 0,
|
||||||
child: Container(
|
color: Colors.white,
|
||||||
width: double.infinity,
|
child: Padding(
|
||||||
padding: Responsive.isDesktop(context)
|
padding: Responsive.isDesktop(context)
|
||||||
? EdgeInsets.all(20)
|
? EdgeInsets.all(20)
|
||||||
: EdgeInsets.all(
|
: EdgeInsets.all(10),
|
||||||
10), // Add padding to the container
|
child: Column(
|
||||||
child: Column(children: [
|
children: [
|
||||||
Row(children: [
|
|
||||||
Text(
|
|
||||||
'Cash Transaction',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 18,
|
|
||||||
fontWeight: FontWeight.w600,
|
|
||||||
color: Colors.black,
|
|
||||||
),
|
|
||||||
)
|
|
||||||
]),
|
|
||||||
SizedBox(height: 8),
|
|
||||||
Row(
|
Row(
|
||||||
children: [
|
children: [
|
||||||
// Create an Expanded widget with flex of 4 for each card
|
Expanded(
|
||||||
for (var cardData in getCardArrays)
|
child: Column(
|
||||||
Container(
|
crossAxisAlignment:
|
||||||
width:
|
CrossAxisAlignment.start,
|
||||||
300, // Set a fixed width for the card
|
children: List.generate(
|
||||||
height: cardHeight,
|
numExpanded,
|
||||||
child: Card(
|
(index) {
|
||||||
elevation: 3,
|
var insurerName = getCardArrays[index]
|
||||||
color: cardColors[
|
['insurerName'];
|
||||||
getCardArrays.indexOf(cardData) %
|
var policyDetails =
|
||||||
cardColors.length],
|
getCardArrays[index]
|
||||||
child: Column(
|
['policyDetails'];
|
||||||
crossAxisAlignment:
|
|
||||||
CrossAxisAlignment.start,
|
// Determine the color for the policyDetails based on the index of the card in getCardArrays
|
||||||
children: [
|
var cardColorIndex =
|
||||||
ListTile(
|
getCardArrays.indexOf(
|
||||||
title: SizedBox(
|
getCardArrays[index]) %
|
||||||
height: 50,
|
cardColors.length;
|
||||||
child: Text(
|
var cardColor =
|
||||||
cardData['insurerName'],
|
cardColors[cardColorIndex];
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 18,
|
return Column(
|
||||||
fontWeight: FontWeight.w500,
|
crossAxisAlignment:
|
||||||
color: Color(0xFF000000),
|
CrossAxisAlignment.start,
|
||||||
height: 1.5,
|
children: [
|
||||||
),
|
Text(
|
||||||
),
|
insurerName,
|
||||||
),
|
|
||||||
subtitle: Text(
|
|
||||||
'Balance: ₹ ${cardData['balance']}',
|
|
||||||
style: GoogleFonts.poppins(
|
style: GoogleFonts.poppins(
|
||||||
fontSize: 16,
|
fontSize: 18,
|
||||||
fontWeight: FontWeight.w400,
|
fontWeight: FontWeight.w600,
|
||||||
color: Color(0xFF000000),
|
color: Colors.black,
|
||||||
height: 1.5,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
SizedBox(height: 8),
|
||||||
SizedBox(height: 10),
|
Row(
|
||||||
Padding(
|
children: [
|
||||||
padding: EdgeInsets.symmetric(
|
IconButton(
|
||||||
horizontal: 15),
|
icon:
|
||||||
child: GestureDetector(
|
Icon(Icons.arrow_back),
|
||||||
onTap: () {
|
onPressed: () {
|
||||||
openForm(
|
_scrollController
|
||||||
cardData['depositData'],
|
.animateTo(
|
||||||
cardData['insurerName'],
|
_scrollController
|
||||||
cardData['clientId'],
|
.offset -
|
||||||
cardData['insurerId'],
|
300,
|
||||||
cardColors[getCardArrays
|
duration: Duration(
|
||||||
.indexOf(cardData) %
|
milliseconds: 500),
|
||||||
cardColors.length],
|
curve: Curves.easeInOut,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
child: MouseRegion(
|
|
||||||
cursor:
|
|
||||||
SystemMouseCursors.click,
|
|
||||||
child: Align(
|
|
||||||
alignment:
|
|
||||||
Alignment.centerRight,
|
|
||||||
child: Text(
|
|
||||||
'View Details',
|
|
||||||
style:
|
|
||||||
GoogleFonts.poppins(
|
|
||||||
color:
|
|
||||||
Color(0xFF000000),
|
|
||||||
fontSize: 14,
|
|
||||||
fontWeight:
|
|
||||||
FontWeight.w300,
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
Expanded(
|
||||||
),
|
child:
|
||||||
),
|
SingleChildScrollView(
|
||||||
],
|
scrollDirection:
|
||||||
),
|
Axis.horizontal,
|
||||||
),
|
controller:
|
||||||
),
|
_scrollController,
|
||||||
],
|
dragStartBehavior:
|
||||||
),
|
DragStartBehavior
|
||||||
])),
|
.start,
|
||||||
),
|
child: Row(
|
||||||
SizedBox(height: 16),
|
children: List.generate(
|
||||||
if (getCardArrays.length != 0)
|
policyDetails.length,
|
||||||
Card(
|
(index) => Container(
|
||||||
elevation: 0,
|
width: 300,
|
||||||
child: Padding(
|
height:
|
||||||
padding: Responsive.isDesktop(context)
|
policyHeight,
|
||||||
? EdgeInsets.all(20)
|
child:
|
||||||
: EdgeInsets.all(10),
|
GestureDetector(
|
||||||
child: Column(
|
onTap: () {
|
||||||
children: [
|
Navigator.pushNamed(
|
||||||
Row(
|
context,
|
||||||
children: [
|
'hrPolicyDetails',
|
||||||
Expanded(
|
arguments:
|
||||||
child: Column(
|
policyDetails[
|
||||||
crossAxisAlignment:
|
index]);
|
||||||
CrossAxisAlignment.start,
|
},
|
||||||
children: List.generate(
|
child:
|
||||||
numExpanded,
|
MouseRegion(
|
||||||
(index) {
|
cursor:
|
||||||
var insurerName =
|
SystemMouseCursors
|
||||||
getCardArrays[index]
|
.click,
|
||||||
['insurerName'];
|
child: Card(
|
||||||
var policyDetails =
|
elevation: 3,
|
||||||
getCardArrays[index]
|
color:
|
||||||
['policyDetails'];
|
cardColor,
|
||||||
|
child: Column(
|
||||||
// Determine the color for the policyDetails based on the index of the card in getCardArrays
|
crossAxisAlignment:
|
||||||
var cardColorIndex =
|
CrossAxisAlignment
|
||||||
getCardArrays.indexOf(
|
.start,
|
||||||
getCardArrays[index]) %
|
children: [
|
||||||
cardColors.length;
|
ListTile(
|
||||||
var cardColor =
|
title:
|
||||||
cardColors[cardColorIndex];
|
SizedBox(
|
||||||
|
|
||||||
return Column(
|
|
||||||
crossAxisAlignment:
|
|
||||||
CrossAxisAlignment.start,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
insurerName,
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 18,
|
|
||||||
fontWeight: FontWeight.w600,
|
|
||||||
color: Colors.black,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
SizedBox(height: 8),
|
|
||||||
SingleChildScrollView(
|
|
||||||
scrollDirection:
|
|
||||||
Axis.horizontal,
|
|
||||||
controller:
|
|
||||||
ScrollController(), // Adding ScrollController
|
|
||||||
dragStartBehavior:
|
|
||||||
DragStartBehavior.start,
|
|
||||||
child: Row(
|
|
||||||
children: List.generate(
|
|
||||||
policyDetails.length,
|
|
||||||
(index) => Container(
|
|
||||||
width: 300,
|
|
||||||
height: policyHeight,
|
|
||||||
child: GestureDetector(
|
|
||||||
onTap: () {
|
|
||||||
Navigator.pushNamed(
|
|
||||||
context,
|
|
||||||
'hrPolicyDetails',
|
|
||||||
arguments:
|
|
||||||
policyDetails[
|
|
||||||
index]);
|
|
||||||
},
|
|
||||||
child: MouseRegion(
|
|
||||||
cursor:
|
|
||||||
SystemMouseCursors
|
|
||||||
.click,
|
|
||||||
child: Card(
|
|
||||||
elevation: 3,
|
|
||||||
color:
|
|
||||||
cardColor, // Use the determined color
|
|
||||||
child: Column(
|
|
||||||
crossAxisAlignment:
|
|
||||||
CrossAxisAlignment
|
|
||||||
.start,
|
|
||||||
children: [
|
|
||||||
ListTile(
|
|
||||||
title:
|
|
||||||
SizedBox(
|
|
||||||
height:
|
|
||||||
50,
|
|
||||||
child:
|
|
||||||
Text(
|
|
||||||
'${policyDetails[index]['policy_name']} - (${policyDetails[index]['type']})',
|
|
||||||
style: GoogleFonts
|
|
||||||
.poppins(
|
|
||||||
fontSize:
|
|
||||||
16,
|
|
||||||
fontWeight:
|
|
||||||
FontWeight.w500,
|
|
||||||
color:
|
|
||||||
Color(0xFF000000),
|
|
||||||
height:
|
height:
|
||||||
1.5,
|
50,
|
||||||
|
child:
|
||||||
|
Text(
|
||||||
|
'${policyDetails[index]['policy_name']} - (${policyDetails[index]['type']})',
|
||||||
|
style:
|
||||||
|
GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight: FontWeight.w500,
|
||||||
|
color: Color(0xFF000000),
|
||||||
|
height: 1.5,
|
||||||
|
),
|
||||||
|
softWrap:
|
||||||
|
true,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
softWrap:
|
|
||||||
true, // Allow text to wrap to the next line if needed
|
|
||||||
),
|
),
|
||||||
),
|
SizedBox(
|
||||||
|
height:
|
||||||
|
8),
|
||||||
|
Padding(
|
||||||
|
padding: EdgeInsets.only(
|
||||||
|
left:
|
||||||
|
15,
|
||||||
|
right:
|
||||||
|
15),
|
||||||
|
child:
|
||||||
|
Row(
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
flex: 4,
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
|
children: [
|
||||||
|
Text(
|
||||||
|
'Draft',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight: FontWeight.w500,
|
||||||
|
color: Color(0xFF000000),
|
||||||
|
height: 1.5,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Text(
|
||||||
|
policyDetails[index]['membersCountOfDraft'].toString(),
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight: FontWeight.w400,
|
||||||
|
color: Color(0xFF000000),
|
||||||
|
height: 1.5,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
flex: 4,
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
|
children: [
|
||||||
|
Text(
|
||||||
|
'Enrolled',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight: FontWeight.w500,
|
||||||
|
color: Color(0xFF000000),
|
||||||
|
height: 1.5,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Text(
|
||||||
|
policyDetails[index]['membersCountOfEnrolled'].toString(),
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight: FontWeight.w400,
|
||||||
|
color: Color(0xFF000000),
|
||||||
|
height: 1.5,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
flex: 4,
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
|
children: [
|
||||||
|
Text(
|
||||||
|
'Total',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight: FontWeight.w500,
|
||||||
|
color: Color(0xFF000000),
|
||||||
|
height: 1.5,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Text(
|
||||||
|
policyDetails[index]['totalMembersCount'].toString(),
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight: FontWeight.w400,
|
||||||
|
color: Color(0xFF000000),
|
||||||
|
height: 1.5,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
SizedBox(
|
),
|
||||||
height:
|
|
||||||
8),
|
|
||||||
Padding(
|
|
||||||
padding: EdgeInsets.only(
|
|
||||||
left:
|
|
||||||
15,
|
|
||||||
right:
|
|
||||||
15),
|
|
||||||
child: Row(
|
|
||||||
children: [
|
|
||||||
Expanded(
|
|
||||||
flex:
|
|
||||||
4,
|
|
||||||
child:
|
|
||||||
Column(
|
|
||||||
crossAxisAlignment:
|
|
||||||
CrossAxisAlignment.center,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
'Draft',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 16,
|
|
||||||
fontWeight: FontWeight.w500,
|
|
||||||
color: Color(0xFF000000),
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Text(
|
|
||||||
policyDetails[index]['membersCountOfDraft'].toString(),
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 16,
|
|
||||||
fontWeight: FontWeight.w400,
|
|
||||||
color: Color(0xFF000000),
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Expanded(
|
|
||||||
flex:
|
|
||||||
4,
|
|
||||||
child:
|
|
||||||
Column(
|
|
||||||
crossAxisAlignment:
|
|
||||||
CrossAxisAlignment.center,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
'Enrolled',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 16,
|
|
||||||
fontWeight: FontWeight.w500,
|
|
||||||
color: Color(0xFF000000),
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Text(
|
|
||||||
policyDetails[index]['membersCountOfEnrolled'].toString(),
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 16,
|
|
||||||
fontWeight: FontWeight.w400,
|
|
||||||
color: Color(0xFF000000),
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Expanded(
|
|
||||||
flex:
|
|
||||||
4,
|
|
||||||
child:
|
|
||||||
Column(
|
|
||||||
crossAxisAlignment:
|
|
||||||
CrossAxisAlignment.center,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
'Total',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 16,
|
|
||||||
fontWeight: FontWeight.w500,
|
|
||||||
color: Color(0xFF000000),
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Text(
|
|
||||||
policyDetails[index]['totalMembersCount'].toString(),
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 16,
|
|
||||||
fontWeight: FontWeight.w400,
|
|
||||||
color: Color(0xFF000000),
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
), // Adjust the horizontal padding as needed
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -620,26 +639,43 @@ class _hrDashboardState extends State<hrDashboard> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
IconButton(
|
||||||
SizedBox(height: 20),
|
icon: Icon(
|
||||||
],
|
Icons.arrow_forward),
|
||||||
);
|
onPressed: () {
|
||||||
},
|
_scrollController
|
||||||
),
|
.animateTo(
|
||||||
|
_scrollController
|
||||||
|
.offset +
|
||||||
|
300,
|
||||||
|
duration: Duration(
|
||||||
|
milliseconds: 500),
|
||||||
|
curve: Curves.easeInOut,
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
SizedBox(height: 20),
|
||||||
|
],
|
||||||
|
);
|
||||||
|
},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
),
|
||||||
)
|
],
|
||||||
],
|
),
|
||||||
),
|
],
|
||||||
))
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
if (isLoading)
|
if (isLoading)
|
||||||
Container(
|
Container(
|
||||||
color: Color(0xFFFFFCE5), // Semi-transparent background
|
color: Color(0x98FFFCE5), // Semi-transparent background
|
||||||
child: Center(
|
child: Center(
|
||||||
child: // Your GIF loader widget
|
child: // Your GIF loader widget
|
||||||
Image.asset(
|
Image.asset(
|
||||||
@ -648,6 +684,13 @@ class _hrDashboardState extends State<hrDashboard> {
|
|||||||
'assets/nhance-loader.gif'), // Adjust path to your GIF loader
|
'assets/nhance-loader.gif'), // Adjust path to your GIF loader
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
Align(
|
||||||
|
alignment: Alignment.bottomCenter,
|
||||||
|
child: Container(
|
||||||
|
width: double.infinity, // Make the footer full width
|
||||||
|
child: CustomFooter(),
|
||||||
|
),
|
||||||
|
),
|
||||||
]));
|
]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -267,7 +267,7 @@ class _MyPhoneState extends State<MyHrLogin> {
|
|||||||
return Image.asset(
|
return Image.asset(
|
||||||
'assets/hrLogin.jpg',
|
'assets/hrLogin.jpg',
|
||||||
height: _size.height,
|
height: _size.height,
|
||||||
fit: BoxFit.fill,
|
fit: BoxFit.cover,
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
return SizedBox();
|
return SizedBox();
|
||||||
@ -327,23 +327,23 @@ class _MyPhoneState extends State<MyHrLogin> {
|
|||||||
flex: 8,
|
flex: 8,
|
||||||
child: Align(
|
child: Align(
|
||||||
alignment: Alignment
|
alignment: Alignment
|
||||||
.centerRight, // Align to the start
|
.topRight, // Align to the start
|
||||||
child: _size.width <= 1100
|
child: _size.width <= 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final-mobile.png',
|
'assets/Nhance-Logo-Final-mobile.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: _size.width > 1100
|
: _size.width > 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: Image.asset(
|
: Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
),
|
),
|
||||||
)),
|
)),
|
||||||
],
|
],
|
||||||
@ -598,42 +598,49 @@ class _MyPhoneState extends State<MyHrLogin> {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: _size.height * 0.1,
|
height: _size.height * 0.1,
|
||||||
),
|
),
|
||||||
Container(
|
Align(
|
||||||
alignment: Alignment.bottomCenter,
|
alignment: Alignment.bottomCenter,
|
||||||
padding:
|
child: Container(
|
||||||
EdgeInsets.symmetric(vertical: 8),
|
width: double
|
||||||
child: RichText(
|
.infinity, // Make the footer full width
|
||||||
textAlign: TextAlign.center,
|
child: Container(
|
||||||
text: TextSpan(
|
alignment: Alignment.bottomCenter,
|
||||||
text:
|
padding:
|
||||||
'By continuing, you agree with our ',
|
EdgeInsets.symmetric(vertical: 8),
|
||||||
style: TextStyle(
|
child: RichText(
|
||||||
color: Colors.black,
|
textAlign: TextAlign.center,
|
||||||
fontSize: 9,
|
text: TextSpan(
|
||||||
),
|
text:
|
||||||
children: <TextSpan>[
|
'By continuing, you agree with our ',
|
||||||
TextSpan(
|
style: GoogleFonts.poppins(
|
||||||
text: 'privacy policy ',
|
|
||||||
style: TextStyle(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
TextSpan(
|
|
||||||
text: 'and ',
|
|
||||||
style: TextStyle(
|
|
||||||
color: Colors.black,
|
color: Colors.black,
|
||||||
fontSize: 9,
|
fontSize: 9,
|
||||||
),
|
),
|
||||||
|
children: <TextSpan>[
|
||||||
|
TextSpan(
|
||||||
|
text: 'privacy policy ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'and ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Colors.black,
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'terms of use',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
TextSpan(
|
),
|
||||||
text: 'terms of use',
|
|
||||||
style: TextStyle(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -19,6 +19,8 @@ import 'package:excel/excel.dart';
|
|||||||
import 'package:path_provider/path_provider.dart';
|
import 'package:path_provider/path_provider.dart';
|
||||||
import 'package:path/path.dart' as path;
|
import 'package:path/path.dart' as path;
|
||||||
|
|
||||||
|
import 'customAppBar/customFooter.dart';
|
||||||
|
|
||||||
class hrPolicyDetails extends StatefulWidget {
|
class hrPolicyDetails extends StatefulWidget {
|
||||||
const hrPolicyDetails({Key? key}) : super(key: key);
|
const hrPolicyDetails({Key? key}) : super(key: key);
|
||||||
|
|
||||||
@ -31,6 +33,7 @@ class _HrPolicyDetailsState extends State<hrPolicyDetails>
|
|||||||
Uint8List? fileBytes;
|
Uint8List? fileBytes;
|
||||||
late String _token;
|
late String _token;
|
||||||
List<Map<String, dynamic>> getEmpDependenceByClintId = [];
|
List<Map<String, dynamic>> getEmpDependenceByClintId = [];
|
||||||
|
bool isLoading = false;
|
||||||
bool _isLoading = false;
|
bool _isLoading = false;
|
||||||
// dynamic clintID;
|
// dynamic clintID;
|
||||||
late TabController _tabController;
|
late TabController _tabController;
|
||||||
@ -133,6 +136,7 @@ class _HrPolicyDetailsState extends State<hrPolicyDetails>
|
|||||||
}
|
}
|
||||||
|
|
||||||
Future<void> getEmployeeAndDependence(clintID, getPolicyNo) async {
|
Future<void> getEmployeeAndDependence(clintID, getPolicyNo) async {
|
||||||
|
isLoading = true;
|
||||||
setState(() {
|
setState(() {
|
||||||
_isLoading = true;
|
_isLoading = true;
|
||||||
});
|
});
|
||||||
@ -140,6 +144,7 @@ class _HrPolicyDetailsState extends State<hrPolicyDetails>
|
|||||||
final response = await apiService.getEmployeeAndDependenceToApi(
|
final response = await apiService.getEmployeeAndDependenceToApi(
|
||||||
clintID!, getPolicyNo!, empRefId!);
|
clintID!, getPolicyNo!, empRefId!);
|
||||||
if (response['status'] == 'success') {
|
if (response['status'] == 'success') {
|
||||||
|
isLoading = false;
|
||||||
setState(() {
|
setState(() {
|
||||||
getEmpDependenceByClintId =
|
getEmpDependenceByClintId =
|
||||||
List<Map<String, dynamic>>.from(response['data']);
|
List<Map<String, dynamic>>.from(response['data']);
|
||||||
@ -293,176 +298,336 @@ class _HrPolicyDetailsState extends State<hrPolicyDetails>
|
|||||||
if (filteredData == []) {
|
if (filteredData == []) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
appBar: CustomAppBar(),
|
appBar: CustomAppBar(),
|
||||||
body: SingleChildScrollView(
|
body: Stack(children: [
|
||||||
child: Container(
|
SingleChildScrollView(
|
||||||
color: Color(0xFFEFF3F6),
|
child: Container(
|
||||||
child: Column(
|
color: Color(0xFFEFF3F6),
|
||||||
children: [
|
|
||||||
Center(
|
|
||||||
child: Text('No Data Available'),
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
));
|
|
||||||
} else {
|
|
||||||
return Scaffold(
|
|
||||||
appBar: CustomAppBar(),
|
|
||||||
body: Container(
|
|
||||||
padding: const EdgeInsets.all(20),
|
|
||||||
color: Color(0xFFEFF3F6),
|
|
||||||
child: Card(
|
|
||||||
elevation: 0,
|
|
||||||
child: SingleChildScrollView(
|
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
Center(
|
Center(
|
||||||
child: Padding(
|
child: Text('No Data Available'),
|
||||||
padding: const EdgeInsets.all(20),
|
)
|
||||||
child: _isLoading
|
],
|
||||||
? Center(child: CircularProgressIndicator())
|
),
|
||||||
: originalData.isNotEmpty
|
),
|
||||||
? SingleChildScrollView(
|
),
|
||||||
child: Column(
|
if (isLoading)
|
||||||
children: [
|
Container(
|
||||||
Container(
|
color: Color(0x98FFFCE5), // Semi-transparent background
|
||||||
padding: EdgeInsets.all(
|
child: Center(
|
||||||
10), // Set your desired padding
|
child: // Your GIF loader widget
|
||||||
color: Color(
|
Image.asset(
|
||||||
0xFFE26728), // Set your desired background color
|
height: 60,
|
||||||
child: Row(
|
width: 60,
|
||||||
children: [
|
'assets/nhance-loader.gif'), // Adjust path to your GIF loader
|
||||||
Expanded(
|
),
|
||||||
flex: 6,
|
),
|
||||||
child: Container(
|
Align(
|
||||||
alignment: Alignment
|
alignment: Alignment.bottomCenter,
|
||||||
.centerLeft, // Align text to the center
|
child: Container(
|
||||||
child: Text(
|
width: double.infinity, // Make the footer full width
|
||||||
'$policyName - ($policyType)',
|
child: CustomFooter(),
|
||||||
textAlign: TextAlign
|
),
|
||||||
.center, // Align text to the center
|
),
|
||||||
style: GoogleFonts.poppins(
|
]));
|
||||||
fontSize: 16,
|
} else {
|
||||||
fontWeight: FontWeight.w500,
|
return Scaffold(
|
||||||
color: Colors.white,
|
appBar: CustomAppBar(),
|
||||||
),
|
body: Stack(children: [
|
||||||
),
|
Container(
|
||||||
),
|
padding: const EdgeInsets.all(20),
|
||||||
),
|
color: Color(0xFFEFF3F6),
|
||||||
Expanded(
|
child: Card(
|
||||||
flex: 6,
|
elevation: 0,
|
||||||
child: Container(
|
color: Colors.white,
|
||||||
alignment: Alignment
|
child: SingleChildScrollView(
|
||||||
.centerRight, // Align text to the center
|
child: Column(
|
||||||
child: MouseRegion(
|
children: [
|
||||||
cursor:
|
Center(
|
||||||
SystemMouseCursors.click,
|
child: Padding(
|
||||||
child: GestureDetector(
|
padding: const EdgeInsets.all(20),
|
||||||
onTap: () {
|
child: _isLoading
|
||||||
Navigator.pushNamed(
|
? Center(child: CircularProgressIndicator())
|
||||||
context,
|
: originalData.isNotEmpty
|
||||||
'hrDashboard');
|
? SingleChildScrollView(
|
||||||
},
|
child: Column(
|
||||||
child: Icon(
|
children: [
|
||||||
Icons
|
Container(
|
||||||
.close, // Replace with your desired icon
|
padding: EdgeInsets.all(
|
||||||
color: Colors
|
10), // Set your desired padding
|
||||||
.white, // Replace with your desired icon color
|
color: Color(
|
||||||
|
0xFFE26728), // Set your desired background color
|
||||||
|
child: Row(
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
flex: 6,
|
||||||
|
child: Container(
|
||||||
|
alignment: Alignment
|
||||||
|
.centerLeft, // Align text to the center
|
||||||
|
child: Text(
|
||||||
|
'$policyName - ($policyType)',
|
||||||
|
textAlign: TextAlign
|
||||||
|
.center, // Align text to the center
|
||||||
|
style:
|
||||||
|
GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight:
|
||||||
|
FontWeight.w500,
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
Expanded(
|
||||||
|
flex: 6,
|
||||||
|
child: Container(
|
||||||
|
alignment: Alignment
|
||||||
|
.centerRight, // Align text to the center
|
||||||
|
child: MouseRegion(
|
||||||
|
cursor: SystemMouseCursors
|
||||||
|
.click,
|
||||||
|
child: GestureDetector(
|
||||||
|
onTap: () {
|
||||||
|
Navigator.pushNamed(
|
||||||
|
context,
|
||||||
|
'hrDashboard');
|
||||||
|
},
|
||||||
|
child: Icon(
|
||||||
|
Icons
|
||||||
|
.close, // Replace with your desired icon
|
||||||
|
color: Colors
|
||||||
|
.white, // Replace with your desired icon color
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
],
|
),
|
||||||
),
|
SizedBox(height: 20),
|
||||||
),
|
Row(
|
||||||
SizedBox(height: 20),
|
children: [
|
||||||
Row(
|
Expanded(
|
||||||
children: [
|
flex: (policyType == 'GPA' ||
|
||||||
Expanded(
|
policyType == 'GMC')
|
||||||
flex: (policyType == 'GPA' ||
|
? 8
|
||||||
policyType == 'GMC')
|
: 10,
|
||||||
? 8
|
|
||||||
: 10,
|
|
||||||
child: Container(
|
|
||||||
alignment: Alignment.centerLeft,
|
|
||||||
child: Container(
|
child: Container(
|
||||||
width:
|
alignment:
|
||||||
350, // Set your desired width here
|
Alignment.centerLeft,
|
||||||
height:
|
child: Container(
|
||||||
40, // Set your desired height here
|
width:
|
||||||
decoration: BoxDecoration(
|
350, // Set your desired width here
|
||||||
boxShadow: [
|
height:
|
||||||
BoxShadow(
|
40, // Set your desired height here
|
||||||
color: Color.fromRGBO(
|
decoration: BoxDecoration(
|
||||||
255,
|
boxShadow: [
|
||||||
255,
|
BoxShadow(
|
||||||
255,
|
color: Color.fromRGBO(
|
||||||
0.5), // Shadow color with opacity
|
255,
|
||||||
offset: Offset(5,
|
255,
|
||||||
5), // Shadow position (horizontal, vertical)
|
255,
|
||||||
blurRadius:
|
0.5), // Shadow color with opacity
|
||||||
10, // Blur radius
|
offset: Offset(5,
|
||||||
spreadRadius:
|
5), // Shadow position (horizontal, vertical)
|
||||||
0, // Spread radius
|
blurRadius:
|
||||||
|
10, // Blur radius
|
||||||
|
spreadRadius:
|
||||||
|
0, // Spread radius
|
||||||
|
),
|
||||||
|
],
|
||||||
|
borderRadius:
|
||||||
|
BorderRadius
|
||||||
|
.circular(5),
|
||||||
|
),
|
||||||
|
child: TextField(
|
||||||
|
textAlignVertical:
|
||||||
|
TextAlignVertical
|
||||||
|
.center, // Center the text vertically
|
||||||
|
decoration:
|
||||||
|
InputDecoration(
|
||||||
|
hintText: 'Search',
|
||||||
|
suffixIcon: Icon(
|
||||||
|
Icons.search),
|
||||||
|
contentPadding:
|
||||||
|
EdgeInsets.all(
|
||||||
|
10), // Adjust the horizontal padding
|
||||||
|
border:
|
||||||
|
OutlineInputBorder(
|
||||||
|
borderSide: BorderSide(
|
||||||
|
color: Color(
|
||||||
|
0xFFf5f5f7)), // Set border color to gray
|
||||||
|
),
|
||||||
|
),
|
||||||
|
controller:
|
||||||
|
searchController,
|
||||||
|
onChanged:
|
||||||
|
search, // Call the search method on text change
|
||||||
|
),
|
||||||
|
)),
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
flex: 2,
|
||||||
|
child: Container(
|
||||||
|
alignment:
|
||||||
|
Alignment.centerRight,
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment:
|
||||||
|
MainAxisAlignment
|
||||||
|
.center,
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: ElevatedButton(
|
||||||
|
onPressed: () =>
|
||||||
|
{downloadExcel()},
|
||||||
|
child: Text(
|
||||||
|
'Export',
|
||||||
|
style: TextStyle(
|
||||||
|
color: Colors
|
||||||
|
.white),
|
||||||
|
),
|
||||||
|
style: ElevatedButton
|
||||||
|
.styleFrom(
|
||||||
|
backgroundColor:
|
||||||
|
Color(
|
||||||
|
0xFFE26728),
|
||||||
|
shape:
|
||||||
|
RoundedRectangleBorder(
|
||||||
|
borderRadius:
|
||||||
|
BorderRadius
|
||||||
|
.circular(
|
||||||
|
5),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
borderRadius:
|
|
||||||
BorderRadius.circular(
|
|
||||||
5),
|
|
||||||
),
|
),
|
||||||
child: TextField(
|
),
|
||||||
textAlignVertical:
|
),
|
||||||
TextAlignVertical
|
SizedBox(
|
||||||
.center, // Center the text vertically
|
width: (policyType == 'GPA' ||
|
||||||
decoration: InputDecoration(
|
policyType == 'GMC')
|
||||||
hintText: 'Search',
|
? 5
|
||||||
suffixIcon:
|
: 0),
|
||||||
Icon(Icons.search),
|
if ((policyType == 'GPA' ||
|
||||||
contentPadding:
|
policyType == 'GMC') &&
|
||||||
EdgeInsets.all(
|
inceptionType == 2)
|
||||||
10), // Adjust the horizontal padding
|
Expanded(
|
||||||
border:
|
flex: 2,
|
||||||
OutlineInputBorder(
|
child: Container(
|
||||||
borderSide: BorderSide(
|
alignment:
|
||||||
color: Color(
|
Alignment.centerRight,
|
||||||
0xFFf5f5f7)), // Set border color to gray
|
child: Row(
|
||||||
),
|
mainAxisAlignment:
|
||||||
|
MainAxisAlignment
|
||||||
|
.center,
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: ElevatedButton(
|
||||||
|
onPressed: () =>
|
||||||
|
_uploadFile(
|
||||||
|
policyType),
|
||||||
|
child: Text(
|
||||||
|
'Import Data',
|
||||||
|
style: TextStyle(
|
||||||
|
color: Colors
|
||||||
|
.white),
|
||||||
|
),
|
||||||
|
style:
|
||||||
|
ElevatedButton
|
||||||
|
.styleFrom(
|
||||||
|
backgroundColor:
|
||||||
|
Color(
|
||||||
|
0xFFE26728),
|
||||||
|
shape:
|
||||||
|
RoundedRectangleBorder(
|
||||||
|
borderRadius:
|
||||||
|
BorderRadius
|
||||||
|
.circular(
|
||||||
|
5),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
controller:
|
|
||||||
searchController,
|
|
||||||
onChanged:
|
|
||||||
search, // Call the search method on text change
|
|
||||||
),
|
),
|
||||||
)),
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
Expanded(
|
SizedBox(height: 20),
|
||||||
flex: 2,
|
Row(
|
||||||
child: Container(
|
children: [
|
||||||
alignment: Alignment.centerRight,
|
Expanded(
|
||||||
|
child: SingleChildScrollView(
|
||||||
|
child: _buildDataTableGPA(
|
||||||
|
context),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
],
|
||||||
|
))
|
||||||
|
: Container(
|
||||||
|
height:
|
||||||
|
MediaQuery.of(context).size.height,
|
||||||
|
child: Column(
|
||||||
|
mainAxisAlignment:
|
||||||
|
MainAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Container(
|
||||||
|
padding: EdgeInsets.all(
|
||||||
|
10), // Set your desired padding
|
||||||
|
color: Color(
|
||||||
|
0xFFE26728), // Set your desired background color
|
||||||
child: Row(
|
child: Row(
|
||||||
mainAxisAlignment:
|
|
||||||
MainAxisAlignment.center,
|
|
||||||
children: [
|
children: [
|
||||||
Expanded(
|
Expanded(
|
||||||
child: ElevatedButton(
|
flex: 6,
|
||||||
onPressed: () =>
|
child: Container(
|
||||||
{downloadExcel()},
|
alignment: Alignment
|
||||||
|
.centerLeft, // Align text to the center
|
||||||
child: Text(
|
child: Text(
|
||||||
'Export',
|
(policyName != null &&
|
||||||
style: TextStyle(
|
policyType !=
|
||||||
color:
|
null)
|
||||||
Colors.white),
|
? '$policyName - ($policyType)'
|
||||||
|
: '',
|
||||||
|
textAlign: TextAlign
|
||||||
|
.center, // Align text to the center
|
||||||
|
style:
|
||||||
|
GoogleFonts.poppins(
|
||||||
|
fontSize: 16,
|
||||||
|
fontWeight:
|
||||||
|
FontWeight.w500,
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
style: ElevatedButton
|
),
|
||||||
.styleFrom(
|
),
|
||||||
backgroundColor:
|
Expanded(
|
||||||
Color(0xFFE26728),
|
flex: 6,
|
||||||
shape:
|
child: Container(
|
||||||
RoundedRectangleBorder(
|
alignment: Alignment
|
||||||
borderRadius:
|
.centerRight, // Align text to the center
|
||||||
BorderRadius
|
child: MouseRegion(
|
||||||
.circular(5),
|
cursor:
|
||||||
|
SystemMouseCursors
|
||||||
|
.click,
|
||||||
|
child: GestureDetector(
|
||||||
|
onTap: () {
|
||||||
|
Navigator.pushNamed(
|
||||||
|
context,
|
||||||
|
'hrDashboard');
|
||||||
|
},
|
||||||
|
child: Icon(
|
||||||
|
Icons
|
||||||
|
.close, // Replace with your desired icon
|
||||||
|
color: Colors
|
||||||
|
.white, // Replace with your desired icon color
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -470,172 +635,70 @@ class _HrPolicyDetailsState extends State<hrPolicyDetails>
|
|||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
SizedBox(height: 200),
|
||||||
SizedBox(
|
if (inceptionType == 2)
|
||||||
width: (policyType == 'GPA' ||
|
Center(
|
||||||
policyType == 'GMC')
|
child: ElevatedButton(
|
||||||
? 5
|
onPressed: () =>
|
||||||
: 0),
|
_uploadFile(policyType),
|
||||||
if ((policyType == 'GPA' ||
|
|
||||||
policyType == 'GMC') &&
|
|
||||||
inceptionType == 2)
|
|
||||||
Expanded(
|
|
||||||
flex: 2,
|
|
||||||
child: Container(
|
|
||||||
alignment:
|
|
||||||
Alignment.centerRight,
|
|
||||||
child: Row(
|
|
||||||
mainAxisAlignment:
|
|
||||||
MainAxisAlignment.center,
|
|
||||||
children: [
|
|
||||||
Expanded(
|
|
||||||
child: ElevatedButton(
|
|
||||||
onPressed: () =>
|
|
||||||
_uploadFile(
|
|
||||||
policyType),
|
|
||||||
child: Text(
|
|
||||||
'Import Data',
|
|
||||||
style: TextStyle(
|
|
||||||
color:
|
|
||||||
Colors.white),
|
|
||||||
),
|
|
||||||
style: ElevatedButton
|
|
||||||
.styleFrom(
|
|
||||||
backgroundColor:
|
|
||||||
Color(0xFFE26728),
|
|
||||||
shape:
|
|
||||||
RoundedRectangleBorder(
|
|
||||||
borderRadius:
|
|
||||||
BorderRadius
|
|
||||||
.circular(
|
|
||||||
5),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
SizedBox(height: 20),
|
|
||||||
Row(
|
|
||||||
children: [
|
|
||||||
Expanded(
|
|
||||||
child: SingleChildScrollView(
|
|
||||||
child:
|
|
||||||
_buildDataTableGPA(context),
|
|
||||||
),
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
],
|
|
||||||
))
|
|
||||||
: Container(
|
|
||||||
height: MediaQuery.of(context).size.height,
|
|
||||||
child: Column(
|
|
||||||
mainAxisAlignment:
|
|
||||||
MainAxisAlignment.start,
|
|
||||||
children: [
|
|
||||||
Container(
|
|
||||||
padding: EdgeInsets.all(
|
|
||||||
10), // Set your desired padding
|
|
||||||
color: Color(
|
|
||||||
0xFFE26728), // Set your desired background color
|
|
||||||
child: Row(
|
|
||||||
children: [
|
|
||||||
Expanded(
|
|
||||||
flex: 6,
|
|
||||||
child: Container(
|
|
||||||
alignment: Alignment
|
|
||||||
.centerLeft, // Align text to the center
|
|
||||||
child: Text(
|
child: Text(
|
||||||
(policyName != null &&
|
'Import Data',
|
||||||
policyType != null)
|
style: TextStyle(
|
||||||
? '$policyName - ($policyType)'
|
color: Colors.white),
|
||||||
: '',
|
),
|
||||||
textAlign: TextAlign
|
style:
|
||||||
.center, // Align text to the center
|
ElevatedButton.styleFrom(
|
||||||
style: GoogleFonts.poppins(
|
backgroundColor:
|
||||||
fontSize: 16,
|
Color(0xFFE26728),
|
||||||
fontWeight:
|
shape:
|
||||||
FontWeight.w500,
|
RoundedRectangleBorder(
|
||||||
color: Colors.white,
|
borderRadius:
|
||||||
|
BorderRadius.circular(
|
||||||
|
5),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
)
|
||||||
Expanded(
|
else
|
||||||
flex: 6,
|
Center(
|
||||||
child: Container(
|
child: Text(
|
||||||
alignment: Alignment
|
'No Data Available',
|
||||||
.centerRight, // Align text to the center
|
style: GoogleFonts.poppins(
|
||||||
child: MouseRegion(
|
fontSize: 16,
|
||||||
cursor: SystemMouseCursors
|
letterSpacing: 0,
|
||||||
.click,
|
color: Colors.black,
|
||||||
child: GestureDetector(
|
fontWeight: FontWeight.w300,
|
||||||
onTap: () {
|
|
||||||
Navigator.pushNamed(
|
|
||||||
context,
|
|
||||||
'hrDashboard');
|
|
||||||
},
|
|
||||||
child: Icon(
|
|
||||||
Icons
|
|
||||||
.close, // Replace with your desired icon
|
|
||||||
color: Colors
|
|
||||||
.white, // Replace with your desired icon color
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
)
|
||||||
],
|
],
|
||||||
),
|
|
||||||
),
|
),
|
||||||
SizedBox(height: 200),
|
),
|
||||||
if (inceptionType == 2)
|
),
|
||||||
Center(
|
),
|
||||||
child: ElevatedButton(
|
],
|
||||||
onPressed: () =>
|
|
||||||
_uploadFile(policyType),
|
|
||||||
child: Text(
|
|
||||||
'Import Data',
|
|
||||||
style: TextStyle(
|
|
||||||
color: Colors.white),
|
|
||||||
),
|
|
||||||
style: ElevatedButton.styleFrom(
|
|
||||||
backgroundColor:
|
|
||||||
Color(0xFFE26728),
|
|
||||||
shape: RoundedRectangleBorder(
|
|
||||||
borderRadius:
|
|
||||||
BorderRadius.circular(5),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
)
|
|
||||||
else
|
|
||||||
Center(
|
|
||||||
child: Text(
|
|
||||||
'No Data Available',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
fontSize: 16,
|
|
||||||
letterSpacing: 0,
|
|
||||||
color: Colors.black,
|
|
||||||
fontWeight: FontWeight.w300,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
],
|
)),
|
||||||
|
),
|
||||||
|
if (isLoading)
|
||||||
|
Container(
|
||||||
|
color: Color(0x98FFFCE5), // Semi-transparent background
|
||||||
|
child: Center(
|
||||||
|
child: // Your GIF loader widget
|
||||||
|
Image.asset(
|
||||||
|
height: 60,
|
||||||
|
width: 60,
|
||||||
|
'assets/nhance-loader.gif'), // Adjust path to your GIF loader
|
||||||
),
|
),
|
||||||
)),
|
),
|
||||||
),
|
Align(
|
||||||
);
|
alignment: Alignment.bottomCenter,
|
||||||
|
child: Container(
|
||||||
|
width: double.infinity, // Make the footer full width
|
||||||
|
child: CustomFooter(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -645,7 +708,8 @@ class _HrPolicyDetailsState extends State<hrPolicyDetails>
|
|||||||
return Text('No available data');
|
return Text('No available data');
|
||||||
} else {
|
} else {
|
||||||
return Card(
|
return Card(
|
||||||
elevation: 0, // Set elevation to 0 for no shadow
|
elevation: 0,
|
||||||
|
color: Colors.white, // Set elevation to 0 for no shadow
|
||||||
child: PaginatedDataTable(
|
child: PaginatedDataTable(
|
||||||
rowsPerPage: 25, // Adjust rows per page as needed
|
rowsPerPage: 25, // Adjust rows per page as needed
|
||||||
columns: [
|
columns: [
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:google_fonts/google_fonts.dart';
|
||||||
import 'package:nhancepolicy/customAppBar/toastHelper.dart';
|
import 'package:nhancepolicy/customAppBar/toastHelper.dart';
|
||||||
import 'package:nhancepolicy/models/environment.dart';
|
import 'package:nhancepolicy/models/environment.dart';
|
||||||
import 'package:pinput/pinput.dart';
|
import 'package:pinput/pinput.dart';
|
||||||
@ -404,7 +405,7 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
return Image.asset(
|
return Image.asset(
|
||||||
'assets/hrLogin.jpg',
|
'assets/hrLogin.jpg',
|
||||||
height: _size.height,
|
height: _size.height,
|
||||||
fit: BoxFit.fill,
|
fit: BoxFit.cover,
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
return SizedBox();
|
return SizedBox();
|
||||||
@ -429,23 +430,23 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
flex: 8,
|
flex: 8,
|
||||||
child: Align(
|
child: Align(
|
||||||
alignment: Alignment
|
alignment: Alignment
|
||||||
.centerRight, // Align to the start
|
.topRight, // Align to the start
|
||||||
child: _size.width <= 1100
|
child: _size.width <= 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final-mobile.png',
|
'assets/Nhance-Logo-Final-mobile.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: _size.width > 1100
|
: _size.width > 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: Image.asset(
|
: Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
),
|
),
|
||||||
)),
|
)),
|
||||||
],
|
],
|
||||||
@ -462,7 +463,7 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
children: [
|
children: [
|
||||||
Text(
|
Text(
|
||||||
"Welcome to Nhance",
|
"Welcome to Nhance",
|
||||||
style: TextStyle(
|
style: GoogleFonts.poppins(
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
@ -481,14 +482,14 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
text: TextSpan(
|
text: TextSpan(
|
||||||
text:
|
text:
|
||||||
"Please enter the one-time usage code sent to your mobile number $mobileNumber",
|
"Please enter the one-time usage code sent to your mobile number $mobileNumber",
|
||||||
style: TextStyle(
|
style: GoogleFonts.poppins(
|
||||||
fontSize: 12,
|
fontSize: 12,
|
||||||
height: 1.5,
|
height: 1.5,
|
||||||
color: Color(0xFF000000)),
|
color: Color(0xFF000000)),
|
||||||
children: [
|
children: [
|
||||||
TextSpan(
|
TextSpan(
|
||||||
text: " (Change Number)",
|
text: " (Change Number)",
|
||||||
style: TextStyle(
|
style: GoogleFonts.poppins(
|
||||||
fontSize: 12,
|
fontSize: 12,
|
||||||
color: Color(
|
color: Color(
|
||||||
0xFFE26728)), // Change color as desired
|
0xFFE26728)), // Change color as desired
|
||||||
@ -531,7 +532,7 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
_isTimerRunning
|
_isTimerRunning
|
||||||
? Text(
|
? Text(
|
||||||
"Resend OTP in $_secondsRemaining seconds",
|
"Resend OTP in $_secondsRemaining seconds",
|
||||||
style: TextStyle(
|
style: GoogleFonts.poppins(
|
||||||
color: Colors.black),
|
color: Colors.black),
|
||||||
)
|
)
|
||||||
: InkWell(
|
: InkWell(
|
||||||
@ -540,7 +541,7 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
},
|
},
|
||||||
child: Text(
|
child: Text(
|
||||||
"Resend OTP",
|
"Resend OTP",
|
||||||
style: TextStyle(
|
style: GoogleFonts.poppins(
|
||||||
color: Colors.blue),
|
color: Colors.blue),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -574,7 +575,7 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
},
|
},
|
||||||
child: Text(
|
child: Text(
|
||||||
"Submit",
|
"Submit",
|
||||||
style: TextStyle(
|
style: GoogleFonts.poppins(
|
||||||
color: Color(0xFFFFFFFF)),
|
color: Color(0xFFFFFFFF)),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -592,7 +593,7 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
SizedBox(height: 30),
|
SizedBox(height: 30),
|
||||||
Text(
|
Text(
|
||||||
"Benefits of Login",
|
"Benefits of Login",
|
||||||
style: TextStyle(
|
style: GoogleFonts.poppins(
|
||||||
fontSize: 20,
|
fontSize: 20,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
),
|
),
|
||||||
@ -687,42 +688,49 @@ class _MyVerifyState extends State<MyHrVerify> {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: _size.height * 0.1,
|
height: _size.height * 0.1,
|
||||||
),
|
),
|
||||||
Container(
|
Align(
|
||||||
alignment: Alignment.bottomCenter,
|
alignment: Alignment.bottomCenter,
|
||||||
padding:
|
child: Container(
|
||||||
EdgeInsets.symmetric(vertical: 8),
|
width: double
|
||||||
child: RichText(
|
.infinity, // Make the footer full width
|
||||||
textAlign: TextAlign.center,
|
child: Container(
|
||||||
text: TextSpan(
|
alignment: Alignment.bottomCenter,
|
||||||
text:
|
padding:
|
||||||
'By continuing, you agree with our ',
|
EdgeInsets.symmetric(vertical: 8),
|
||||||
style: TextStyle(
|
child: RichText(
|
||||||
color: Colors.black,
|
textAlign: TextAlign.center,
|
||||||
fontSize: 9,
|
text: TextSpan(
|
||||||
),
|
text:
|
||||||
children: <TextSpan>[
|
'By continuing, you agree with our ',
|
||||||
TextSpan(
|
style: GoogleFonts.poppins(
|
||||||
text: 'privacy policy ',
|
|
||||||
style: TextStyle(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
TextSpan(
|
|
||||||
text: 'and ',
|
|
||||||
style: TextStyle(
|
|
||||||
color: Colors.black,
|
color: Colors.black,
|
||||||
fontSize: 9,
|
fontSize: 9,
|
||||||
),
|
),
|
||||||
|
children: <TextSpan>[
|
||||||
|
TextSpan(
|
||||||
|
text: 'privacy policy ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'and ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Colors.black,
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'terms of use',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
TextSpan(
|
),
|
||||||
text: 'terms of use',
|
|
||||||
style: TextStyle(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -273,25 +273,25 @@ class _MyPhoneState extends State<MyPhone> {
|
|||||||
child: Align(
|
child: Align(
|
||||||
alignment: Responsive.isDesktop(
|
alignment: Responsive.isDesktop(
|
||||||
context)
|
context)
|
||||||
? Alignment.centerLeft
|
? Alignment.topLeft
|
||||||
: Alignment
|
: Alignment
|
||||||
.bottomCenter, // Align to the start
|
.bottomCenter, // Align to the start
|
||||||
child: _size.width <= 1100
|
child: _size.width <= 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final-mobile.png',
|
'assets/Nhance-Logo-Final-mobile.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: _size.width > 1100
|
: _size.width > 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: Image.asset(
|
: Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
),
|
),
|
||||||
)),
|
)),
|
||||||
Expanded(
|
Expanded(
|
||||||
@ -581,42 +581,49 @@ class _MyPhoneState extends State<MyPhone> {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: _size.height * 0.1,
|
height: _size.height * 0.1,
|
||||||
),
|
),
|
||||||
Container(
|
Align(
|
||||||
alignment: Alignment.bottomCenter,
|
alignment: Alignment.bottomCenter,
|
||||||
padding:
|
child: Container(
|
||||||
EdgeInsets.symmetric(vertical: 8),
|
width: double
|
||||||
child: RichText(
|
.infinity, // Make the footer full width
|
||||||
textAlign: TextAlign.center,
|
child: Container(
|
||||||
text: TextSpan(
|
alignment: Alignment.bottomCenter,
|
||||||
text:
|
padding:
|
||||||
'By continuing, you agree with our ',
|
EdgeInsets.symmetric(vertical: 8),
|
||||||
style: GoogleFonts.poppins(
|
child: RichText(
|
||||||
color: Colors.black,
|
textAlign: TextAlign.center,
|
||||||
fontSize: 9,
|
text: TextSpan(
|
||||||
),
|
text:
|
||||||
children: <TextSpan>[
|
'By continuing, you agree with our ',
|
||||||
TextSpan(
|
|
||||||
text: 'privacy policy ',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
TextSpan(
|
|
||||||
text: 'and ',
|
|
||||||
style: GoogleFonts.poppins(
|
style: GoogleFonts.poppins(
|
||||||
color: Colors.black,
|
color: Colors.black,
|
||||||
fontSize: 9,
|
fontSize: 9,
|
||||||
),
|
),
|
||||||
|
children: <TextSpan>[
|
||||||
|
TextSpan(
|
||||||
|
text: 'privacy policy ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'and ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Colors.black,
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'terms of use',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
TextSpan(
|
),
|
||||||
text: 'terms of use',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -32,7 +32,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getClientDetails?client_id=$clientId&emp_code=$empCode&client_branch_id=$branchID');
|
'${Environment.apiUrl}getClientDetails?client_id=$clientId&emp_code=$empCode&client_branch_id=$branchID');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -47,7 +47,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getEmployeeProfile?emp_code=$empCode&client_id=$clientId&client_branch_id=$branchID');
|
'${Environment.apiUrl}getEmployeeProfile?emp_code=$empCode&client_id=$clientId&client_branch_id=$branchID');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -60,7 +60,7 @@ class ApiService {
|
|||||||
}
|
}
|
||||||
final url = Uri.parse('${Environment.apiUrl}relationshipList');
|
final url = Uri.parse('${Environment.apiUrl}relationshipList');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -75,7 +75,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getEmployeePolicy?id=$empPrimaryId&emp_code=$empCode&client_id=$clientId&policy=$policy&client_branch_id=$branchID');
|
'${Environment.apiUrl}getEmployeePolicy?id=$empPrimaryId&emp_code=$empCode&client_id=$clientId&policy=$policy&client_branch_id=$branchID');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -90,7 +90,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getEmployeePolicy?id=$empPrimaryId&emp_code=$empCode&client_id=$clientId&policy=$policy&client_branch_id=$branchID');
|
'${Environment.apiUrl}getEmployeePolicy?id=$empPrimaryId&emp_code=$empCode&client_id=$clientId&policy=$policy&client_branch_id=$branchID');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -105,7 +105,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getAddOnPolicy?client_id=$client_id&emp_code=$emp_code&policy=$policy&client_branch_id=$branchID');
|
'${Environment.apiUrl}getAddOnPolicy?client_id=$client_id&emp_code=$emp_code&policy=$policy&client_branch_id=$branchID');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -120,7 +120,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getAddOnPolicy?client_id=$client_id&emp_code=$emp_code&policy=$policy&client_branch_id=$branchID');
|
'${Environment.apiUrl}getAddOnPolicy?client_id=$client_id&emp_code=$emp_code&policy=$policy&client_branch_id=$branchID');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -135,7 +135,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getAddOnPolicy?client_id=$client_id&emp_code=$emp_code&policy=$policy&client_branch_id=$branchID');
|
'${Environment.apiUrl}getAddOnPolicy?client_id=$client_id&emp_code=$emp_code&policy=$policy&client_branch_id=$branchID');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -150,7 +150,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}removeEmpAndEmpPolicyData?emp_code=$empCodeString&client_policy_id=$addOnsDependentClientPolicyId');
|
'${Environment.apiUrl}removeEmpAndEmpPolicyData?emp_code=$empCodeString&client_policy_id=$addOnsDependentClientPolicyId');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -165,7 +165,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}removeEmpAndEmpPolicyData?emp_code=$empCodeString&client_policy_id=$topUpClientPolicyId');
|
'${Environment.apiUrl}removeEmpAndEmpPolicyData?emp_code=$empCodeString&client_policy_id=$topUpClientPolicyId');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -180,7 +180,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}removeEmpAndEmpPolicyData?emp_code=$empCodeString&client_policy_id=$topUpParentClientPolicyId');
|
'${Environment.apiUrl}removeEmpAndEmpPolicyData?emp_code=$empCodeString&client_policy_id=$topUpParentClientPolicyId');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -193,7 +193,7 @@ class ApiService {
|
|||||||
}
|
}
|
||||||
final url = Uri.parse('${Environment.apiUrl}deleteDependence?id=$id');
|
final url = Uri.parse('${Environment.apiUrl}deleteDependence?id=$id');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -208,7 +208,7 @@ class ApiService {
|
|||||||
|
|
||||||
final url = Uri.parse('${Environment.apiUrl}addEmployeeAndDependence');
|
final url = Uri.parse('${Environment.apiUrl}addEmployeeAndDependence');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -229,7 +229,7 @@ class ApiService {
|
|||||||
|
|
||||||
final url = Uri.parse('${Environment.apiUrl}addEmployeeAndDependence');
|
final url = Uri.parse('${Environment.apiUrl}addEmployeeAndDependence');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -251,7 +251,7 @@ class ApiService {
|
|||||||
final url =
|
final url =
|
||||||
Uri.parse('${Environment.apiUrl}createOrUpdateEmployeePolicySiAmount');
|
Uri.parse('${Environment.apiUrl}createOrUpdateEmployeePolicySiAmount');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -273,7 +273,7 @@ class ApiService {
|
|||||||
final url =
|
final url =
|
||||||
Uri.parse('${Environment.apiUrl}createOrUpdateEmployeePolicySiAmount');
|
Uri.parse('${Environment.apiUrl}createOrUpdateEmployeePolicySiAmount');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -295,7 +295,7 @@ class ApiService {
|
|||||||
final url =
|
final url =
|
||||||
Uri.parse('${Environment.apiUrl}createOrUpdateEmployeePolicySiAmount');
|
Uri.parse('${Environment.apiUrl}createOrUpdateEmployeePolicySiAmount');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -316,7 +316,7 @@ class ApiService {
|
|||||||
|
|
||||||
final url = Uri.parse('${Environment.apiUrl}iAgreeForAddOn');
|
final url = Uri.parse('${Environment.apiUrl}iAgreeForAddOn');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -336,7 +336,7 @@ class ApiService {
|
|||||||
|
|
||||||
final url = Uri.parse('${Environment.apiUrl}calculatePremium');
|
final url = Uri.parse('${Environment.apiUrl}calculatePremium');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -357,7 +357,7 @@ class ApiService {
|
|||||||
|
|
||||||
final url = Uri.parse('${Environment.apiUrl}calculatePremium');
|
final url = Uri.parse('${Environment.apiUrl}calculatePremium');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -378,7 +378,7 @@ class ApiService {
|
|||||||
|
|
||||||
final url = Uri.parse('${Environment.apiUrl}calculatePremium');
|
final url = Uri.parse('${Environment.apiUrl}calculatePremium');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _token ?? '',
|
'Authorization': 'Bearer $_token' ?? '',
|
||||||
'Content-Type': 'application/json', // Ensure content type is JSON
|
'Content-Type': 'application/json', // Ensure content type is JSON
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -401,7 +401,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getCashDepositData?client_id=$clintID&client_branch_id=$empRefId');
|
'${Environment.apiUrl}getCashDepositData?client_id=$clintID&client_branch_id=$empRefId');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _hrtoken ?? '',
|
'Authorization': 'Bearer $_hrtoken' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
@ -416,7 +416,7 @@ class ApiService {
|
|||||||
final url = Uri.parse(
|
final url = Uri.parse(
|
||||||
'${Environment.apiUrl}getEmployeeAndDependenceByClientId?client_id=$clintID&client_policy_id=$getPolicyNo&client_branch_id=$empRefId');
|
'${Environment.apiUrl}getEmployeeAndDependenceByClientId?client_id=$clintID&client_policy_id=$getPolicyNo&client_branch_id=$empRefId');
|
||||||
final headers = {
|
final headers = {
|
||||||
'Authorization': _hrtoken ?? '',
|
'Authorization': 'Bearer $_hrtoken' ?? '',
|
||||||
};
|
};
|
||||||
final response = await _makeGetRequest(url, headers);
|
final response = await _makeGetRequest(url, headers);
|
||||||
return response;
|
return response;
|
||||||
|
|||||||
@ -397,25 +397,25 @@ class _MyVerifyState extends State<MyVerify> {
|
|||||||
child: Align(
|
child: Align(
|
||||||
alignment: Responsive.isDesktop(
|
alignment: Responsive.isDesktop(
|
||||||
context)
|
context)
|
||||||
? Alignment.centerLeft
|
? Alignment.topLeft
|
||||||
: Alignment
|
: Alignment
|
||||||
.bottomCenter, // Align to the start
|
.bottomCenter, // Align to the start
|
||||||
child: _size.width <= 1100
|
child: _size.width <= 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final-mobile.png',
|
'assets/Nhance-Logo-Final-mobile.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: _size.width > 1100
|
: _size.width > 1100
|
||||||
? Image.asset(
|
? Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
)
|
)
|
||||||
: Image.asset(
|
: Image.asset(
|
||||||
'assets/Nhance-Logo-Final 1.png',
|
'assets/Nhance-Logo-Final 1.png',
|
||||||
width: 150,
|
width: 150,
|
||||||
height: 150,
|
height: 70,
|
||||||
),
|
),
|
||||||
)),
|
)),
|
||||||
],
|
],
|
||||||
@ -658,42 +658,49 @@ class _MyVerifyState extends State<MyVerify> {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: _size.height * 0.1,
|
height: _size.height * 0.1,
|
||||||
),
|
),
|
||||||
Container(
|
Align(
|
||||||
alignment: Alignment.bottomCenter,
|
alignment: Alignment.bottomCenter,
|
||||||
padding:
|
child: Container(
|
||||||
EdgeInsets.symmetric(vertical: 8),
|
width: double
|
||||||
child: RichText(
|
.infinity, // Make the footer full width
|
||||||
textAlign: TextAlign.center,
|
child: Container(
|
||||||
text: TextSpan(
|
alignment: Alignment.bottomCenter,
|
||||||
text:
|
padding:
|
||||||
'By continuing, you agree with our ',
|
EdgeInsets.symmetric(vertical: 8),
|
||||||
style: GoogleFonts.poppins(
|
child: RichText(
|
||||||
color: Colors.black,
|
textAlign: TextAlign.center,
|
||||||
fontSize: 9,
|
text: TextSpan(
|
||||||
),
|
text:
|
||||||
children: <TextSpan>[
|
'By continuing, you agree with our ',
|
||||||
TextSpan(
|
|
||||||
text: 'privacy policy ',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
TextSpan(
|
|
||||||
text: 'and ',
|
|
||||||
style: GoogleFonts.poppins(
|
style: GoogleFonts.poppins(
|
||||||
color: Colors.black,
|
color: Colors.black,
|
||||||
fontSize: 9,
|
fontSize: 9,
|
||||||
),
|
),
|
||||||
|
children: <TextSpan>[
|
||||||
|
TextSpan(
|
||||||
|
text: 'privacy policy ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'and ',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Colors.black,
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
TextSpan(
|
||||||
|
text: 'terms of use',
|
||||||
|
style: GoogleFonts.poppins(
|
||||||
|
color: Color(0xFF00989E),
|
||||||
|
fontSize: 9,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
TextSpan(
|
),
|
||||||
text: 'terms of use',
|
|
||||||
style: GoogleFonts.poppins(
|
|
||||||
color: Color(0xFF00989E),
|
|
||||||
fontSize: 9,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -53,6 +53,7 @@ dependencies:
|
|||||||
flutter_animated_button: ^2.0.3
|
flutter_animated_button: ^2.0.3
|
||||||
spreadsheet_decoder: ^2.2.0
|
spreadsheet_decoder: ^2.2.0
|
||||||
url_launcher: ^6.2.6
|
url_launcher: ^6.2.6
|
||||||
|
font_awesome_flutter: ^10.7.0
|
||||||
|
|
||||||
|
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user