fix issue

merge-requests/1/merge
Fatimah Alshammari 3 years ago
parent c92cd5c20c
commit b502e038a5

@ -306,6 +306,11 @@
"requestType":"نوع الطلب", "requestType":"نوع الطلب",
"employeeDigitalID":"هويةالموظف الرقمية", "employeeDigitalID":"هويةالموظف الرقمية",
"businessCard": "بطاقة العمل", "businessCard": "بطاقة العمل",
"checkOut":"وقت الخروج",
"regular":"منتظم",
"mark" : "علامة",
"selectMethodOfAttendance":"اختر طريقة تسجيل الحضور",
"comeNearHMGWifi": "HMG wifi من فضلك اقترب من",
"profile": { "profile": {
"reset_password": { "reset_password": {
"label": "Reset Password", "label": "Reset Password",

@ -306,6 +306,11 @@
"wantToReject": "Are you sure want to reject?", "wantToReject": "Are you sure want to reject?",
"employeeDigitalID":"Employee Digital ID", "employeeDigitalID":"Employee Digital ID",
"businessCard": "Business Card", "businessCard": "Business Card",
"checkOut":"Check Out",
"regular":"Regular",
"mark" : "Mark",
"selectMethodOfAttendance":"Select the method to mark the attendance",
"comeNearHMGWifi": "Please come near to HMG wifi",
"profile": { "profile": {
"reset_password": { "reset_password": {
"label": "Reset Password", "label": "Reset Password",

@ -322,6 +322,11 @@ class CodegenLoader extends AssetLoader{
"requestType": "نوع الطلب", "requestType": "نوع الطلب",
"employeeDigitalID": "هويةالموظف الرقمية", "employeeDigitalID": "هويةالموظف الرقمية",
"businessCard": "بطاقة العمل", "businessCard": "بطاقة العمل",
"checkOut": "وقت الخروج",
"regular": "منتظم",
"mark": "علامة",
"selectMethodOfAttendance": "اختر طريقة تسجيل الحضور",
"comeNearHMGWifi": "HMG wifi من فضلك اقترب من",
"profile": { "profile": {
"reset_password": { "reset_password": {
"label": "Reset Password", "label": "Reset Password",
@ -661,6 +666,11 @@ static const Map<String,dynamic> en_US = {
"wantToReject": "Are you sure want to reject?", "wantToReject": "Are you sure want to reject?",
"employeeDigitalID": "Employee Digital ID", "employeeDigitalID": "Employee Digital ID",
"businessCard": "Business Card", "businessCard": "Business Card",
"checkOut": "Check Out",
"regular": "Regular",
"mark": "Mark",
"selectMethodOfAttendance": "Select the method to mark the attendance",
"comeNearHMGWifi": "Please come near to HMG wifi",
"profile": { "profile": {
"reset_password": { "reset_password": {
"label": "Reset Password", "label": "Reset Password",

@ -307,6 +307,11 @@ abstract class LocaleKeys {
static const requestType = 'requestType'; static const requestType = 'requestType';
static const employeeDigitalID = 'employeeDigitalID'; static const employeeDigitalID = 'employeeDigitalID';
static const businessCard = 'businessCard'; static const businessCard = 'businessCard';
static const checkOut = 'checkOut';
static const regular = 'regular';
static const mark = 'mark';
static const selectMethodOfAttendance = 'selectMethodOfAttendance';
static const comeNearHMGWifi = 'comeNearHMGWifi';
static const profile_reset_password_label = 'profile.reset_password.label'; static const profile_reset_password_label = 'profile.reset_password.label';
static const profile_reset_password_username = 'profile.reset_password.username'; static const profile_reset_password_username = 'profile.reset_password.username';
static const profile_reset_password_password = 'profile.reset_password.password'; static const profile_reset_password_password = 'profile.reset_password.password';

@ -139,13 +139,13 @@ class _MonthlyAttendanceState extends State<MonthlyAttendance> {
Row( Row(
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
children: [ children: [
optionUI(LocaleKeys.scheduleDays.tr(), "${getTimeCardSummaryList?.sCHEDULEDAYS}"), optionUI(LocaleKeys.scheduleDays.tr(), "${getTimeCardSummaryList?.sCHEDULEDAYS != null ? getTimeCardSummaryList!.sCHEDULEDAYS : 0}"),
6.width, 6.width,
optionUI(LocaleKeys.offDays.tr(), "${getTimeCardSummaryList?.oFFDAYS}"), optionUI(LocaleKeys.offDays.tr(), "${getTimeCardSummaryList?.oFFDAYS != null ? getTimeCardSummaryList!.oFFDAYS : 0}"),
6.width, 6.width,
optionUI(LocaleKeys.nonAnalyzed.tr(), "${getTimeCardSummaryList?.uNAUTHORIZEDLEAVE}"), optionUI(LocaleKeys.nonAnalyzed.tr(), "${getTimeCardSummaryList?.uNAUTHORIZEDLEAVE != null ? getTimeCardSummaryList!.uNAUTHORIZEDLEAVE : 0}"),
6.width, 6.width,
optionUI(LocaleKeys.shortageHour.tr(), "${getTimeCardSummaryList?.sHORTAGEHRS}"), optionUI(LocaleKeys.shortageHour.tr(), "${getTimeCardSummaryList?.sHORTAGEHRS != null ? getTimeCardSummaryList!.sHORTAGEHRS : 0}"),
], ],
).paddingOnly(left: 21, right: 21), ).paddingOnly(left: 21, right: 21),
35.height, 35.height,
@ -319,81 +319,87 @@ class _MonthlyAttendanceState extends State<MonthlyAttendance> {
if (details.date.month == formattedDate.month && details.date.year == formattedDate.year) { if (details.date.month == formattedDate.month && details.date.year == formattedDate.year) {
int val = details.date.day; int val = details.date.day;
//check day is off //check day is off
if (getDayHoursTypeDetailsList?[val - 1].aTTENDEDFLAG == 'N' && getDayHoursTypeDetailsList?[val - 1].dAYTYPE == 'OFF') { if(getDayHoursTypeDetailsList.isNotEmpty)
return Container(
margin: const EdgeInsets.all(4), {
decoration: BoxDecoration( if (getDayHoursTypeDetailsList?[val - 1].aTTENDEDFLAG == 'N' && getDayHoursTypeDetailsList?[val - 1].dAYTYPE == 'OFF') {
color: MyColors.greyACColor.withOpacity(.12), return Container(
shape: BoxShape.circle, margin: const EdgeInsets.all(4),
), decoration: BoxDecoration(
alignment: Alignment.center, color: MyColors.greyACColor.withOpacity(.12),
child: Text( shape: BoxShape.circle,
"$val",
style: const TextStyle(
fontSize: 13,
fontWeight: FontWeight.w500,
color: MyColors.greyA5Color,
),
),
);
}
//check day is Present
else if (getDayHoursTypeDetailsList?[val - 1].aTTENDEDFLAG == 'Y') {
return Container(
margin: const EdgeInsets.all(4),
decoration: BoxDecoration(
gradient: const LinearGradient(
transform: GradientRotation(.46),
begin: Alignment.topRight,
end: Alignment.bottomLeft,
colors: [MyColors.gradiantEndColor, MyColors.gradiantStartColor],
),
shape: BoxShape.circle,
boxShadow: [
BoxShadow(
offset: const Offset(0, 2),
blurRadius: 26,
color: MyColors.blackColor.withOpacity(0.100),
), ),
], alignment: Alignment.center,
), child: Text(
alignment: Alignment.center, "$val",
child: Text( style: const TextStyle(
"$val", fontSize: 13,
style: const TextStyle( fontWeight: FontWeight.w500,
fontSize: 13, color: MyColors.greyA5Color,
fontWeight: FontWeight.w500, ),
color: MyColors.white,
),
),
);
}
//check day is Absent
else if (getDayHoursTypeDetailsList?[val - 1].aTTENDEDFLAG == 'N' && getDayHoursTypeDetailsList?[val - 1].aBSENTFLAG == 'Y') {
return Container(
margin: const EdgeInsets.all(4),
decoration: BoxDecoration(
color: MyColors.backgroundBlackColor,
shape: BoxShape.circle,
boxShadow: [
BoxShadow(
offset: const Offset(0, 2),
blurRadius: 26,
color: MyColors.blackColor.withOpacity(0.100),
), ),
], );
), }
alignment: Alignment.center, //check day is Present
child: Text( else if (getDayHoursTypeDetailsList?[val - 1].aTTENDEDFLAG == 'Y') {
"$val", return Container(
style: const TextStyle( margin: const EdgeInsets.all(4),
fontSize: 13, decoration: BoxDecoration(
fontWeight: FontWeight.w500, gradient: const LinearGradient(
color: MyColors.white, transform: GradientRotation(.46),
), begin: Alignment.topRight,
), end: Alignment.bottomLeft,
); colors: [MyColors.gradiantEndColor, MyColors.gradiantStartColor],
} ),
shape: BoxShape.circle,
boxShadow: [
BoxShadow(
offset: const Offset(0, 2),
blurRadius: 26,
color: MyColors.blackColor.withOpacity(0.100),
),
],
),
alignment: Alignment.center,
child: Text(
"$val",
style: const TextStyle(
fontSize: 13,
fontWeight: FontWeight.w500,
color: MyColors.white,
),
),
);
}
//check day is Absent
else if (getDayHoursTypeDetailsList?[val - 1].aTTENDEDFLAG == 'N' && getDayHoursTypeDetailsList?[val - 1].aBSENTFLAG == 'Y') {
return Container(
margin: const EdgeInsets.all(4),
decoration: BoxDecoration(
color: MyColors.backgroundBlackColor,
shape: BoxShape.circle,
boxShadow: [
BoxShadow(
offset: const Offset(0, 2),
blurRadius: 26,
color: MyColors.blackColor.withOpacity(0.100),
),
],
),
alignment: Alignment.center,
child: Text(
"$val",
style: const TextStyle(
fontSize: 13,
fontWeight: FontWeight.w500,
color: MyColors.white,
),
),
);
}
}
return Container( return Container(
margin: const EdgeInsets.all(4), margin: const EdgeInsets.all(4),
decoration: BoxDecoration( decoration: BoxDecoration(

@ -134,7 +134,7 @@ class _TodayAttendanceScreenState extends State<TodayAttendanceScreen> {
textStyle: TextStyle(color: Colors.white, fontSize: 32, letterSpacing: -1.92, fontWeight: FontWeight.bold, height: 1), textStyle: TextStyle(color: Colors.white, fontSize: 32, letterSpacing: -1.92, fontWeight: FontWeight.bold, height: 1),
), ),
19.height, 19.height,
"Shift Time".tr().toText12(color: MyColors.greyACColor), LocaleKeys.shiftTime.tr().tr().toText12(color: MyColors.greyACColor),
(model.attendanceTracking!.pShtName ?? "00:00:00").toString().toText22(color: Colors.white, isBold: true), (model.attendanceTracking!.pShtName ?? "00:00:00").toString().toText22(color: Colors.white, isBold: true),
], ],
), ),
@ -162,14 +162,14 @@ class _TodayAttendanceScreenState extends State<TodayAttendanceScreen> {
children: [ children: [
Row( Row(
children: [ children: [
commonStatusView("Check In", (model.attendanceTracking!.pSwipeIn) ?? "- - : - -"), commonStatusView(LocaleKeys.checkIn.tr(), (model.attendanceTracking!.pSwipeIn) ?? "- - : - -"),
commonStatusView("Check Out", (model.attendanceTracking!.pSwipeOut) ?? "- - : - -") commonStatusView("Check Out", (model.attendanceTracking!.pSwipeOut) ?? "- - : - -")
], ],
), ),
21.height, 21.height,
Row( Row(
children: [ children: [
commonStatusView("Late In", (model.attendanceTracking!.pLateInHours) ?? "- - : - -"), commonStatusView(LocaleKeys.lateIn.tr(), (model.attendanceTracking!.pLateInHours) ?? "- - : - -"),
commonStatusView("Regular", (model.attendanceTracking!.pScheduledHours) ?? "- - : - -") commonStatusView("Regular", (model.attendanceTracking!.pScheduledHours) ?? "- - : - -")
], ],
), ),
@ -185,9 +185,9 @@ class _TodayAttendanceScreenState extends State<TodayAttendanceScreen> {
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
children: [ children: [
"Mark".tr().toText12(), LocaleKeys.mark.tr().tr().toText12(),
"Attendance".tr().toText24(), LocaleKeys.attendance.tr().tr().toText24(),
"Select the method to mark the attendance".tr().toText12(color: Color(0xff535353)), LocaleKeys.selectMethodOfAttendance.tr().tr().toText12(color: Color(0xff535353)),
24.height, 24.height,
GridView( GridView(
physics: const NeverScrollableScrollPhysics(), physics: const NeverScrollableScrollPhysics(),
@ -312,7 +312,7 @@ class _TodayAttendanceScreenState extends State<TodayAttendanceScreen> {
}); });
} }
} else { } else {
Utils.confirmDialog(context, "Please come near to HMG wifi"); Utils.confirmDialog(context, LocaleKeys.comeNearHMGWifi.tr());
} }
} }

Loading…
Cancel
Save