From 44f23f413ee294214f4ea277df9d788cca4b4ffd Mon Sep 17 00:00:00 2001 From: Sikander Saleem Date: Sun, 12 Feb 2023 15:44:48 +0300 Subject: [PATCH] my request / concurrent reports improvements. --- assets/langs/ar-SA.json | 1 + assets/langs/en-US.json | 1 + lib/api/my_requests_api_client.dart | 4 +- lib/generated/codegen_loader.g.dart | 2 + lib/generated/locale_keys.g.dart | 1 + .../dashboard/drawer_menu_item_model.dart | 4 +- lib/provider/dashboard_provider_model.dart | 38 +++-- lib/ui/landing/dashboard_screen.dart | 2 +- lib/ui/landing/widget/menus_widget.dart | 91 +++++++++--- lib/ui/screens/my_requests/my_requests.dart | 139 +++++++++--------- lib/ui/screens/my_requests/new_request.dart | 17 ++- 11 files changed, 198 insertions(+), 102 deletions(-) diff --git a/assets/langs/ar-SA.json b/assets/langs/ar-SA.json index 4178d17..54d4934 100644 --- a/assets/langs/ar-SA.json +++ b/assets/langs/ar-SA.json @@ -25,6 +25,7 @@ "checkIn": "تحقق في", "workList": "قائمة العمل", "leaveBalance": "رصيد الاجازات", + "businessTripBalance": "رصيد رحلة العمل", "missingSwipes": "تسجيل بصمة حضور", "ticketBalance": "رصيد التذكرة", "other": "آخر", diff --git a/assets/langs/en-US.json b/assets/langs/en-US.json index e4a4266..01572f1 100644 --- a/assets/langs/en-US.json +++ b/assets/langs/en-US.json @@ -25,6 +25,7 @@ "checkIn": "Check In", "workList": "Work List", "leaveBalance": "Leave Balance", + "businessTripBalance": "Business Trip Balance", "missingSwipes": "Missing Swipes", "ticketBalance": "Ticket Balance", "other": "Other", diff --git a/lib/api/my_requests_api_client.dart b/lib/api/my_requests_api_client.dart index c9507b9..c5a32b7 100644 --- a/lib/api/my_requests_api_client.dart +++ b/lib/api/my_requests_api_client.dart @@ -16,9 +16,9 @@ class MyRequestsApiClient { factory MyRequestsApiClient() => _instance; - Future> getConcurrentPrograms() async { + Future> getConcurrentPrograms(int id) async { String url = "${ApiConsts.erpRest}GET_CONCURRENT_PROGRAMS"; - Map postParams = {"P_REQUEST_GROUP_ID": 3290}; + Map postParams = {"P_REQUEST_GROUP_ID": id}; postParams.addAll(AppState().postParamsJson); return await ApiClient().postJsonForObject((json) { diff --git a/lib/generated/codegen_loader.g.dart b/lib/generated/codegen_loader.g.dart index f3497d3..5ec13c6 100644 --- a/lib/generated/codegen_loader.g.dart +++ b/lib/generated/codegen_loader.g.dart @@ -41,6 +41,7 @@ class CodegenLoader extends AssetLoader{ "checkIn": "تحقق في", "workList": "قائمة العمل", "leaveBalance": "رصيد الاجازات", + "businessTripBalance": "رصيد رحلة العمل", "missingSwipes": "تسجيل بصمة حضور", "ticketBalance": "رصيد التذكرة", "other": "آخر", @@ -569,6 +570,7 @@ static const Map en_US = { "checkIn": "Check In", "workList": "Work List", "leaveBalance": "Leave Balance", + "businessTripBalance": "Business Trip Balance", "missingSwipes": "Missing Swipes", "ticketBalance": "Ticket Balance", "other": "Other", diff --git a/lib/generated/locale_keys.g.dart b/lib/generated/locale_keys.g.dart index 4eb91c9..9b00334 100644 --- a/lib/generated/locale_keys.g.dart +++ b/lib/generated/locale_keys.g.dart @@ -27,6 +27,7 @@ abstract class LocaleKeys { static const checkIn = 'checkIn'; static const workList = 'workList'; static const leaveBalance = 'leaveBalance'; + static const businessTripBalance = 'businessTripBalance'; static const missingSwipes = 'missingSwipes'; static const ticketBalance = 'ticketBalance'; static const services = 'services'; diff --git a/lib/models/dashboard/drawer_menu_item_model.dart b/lib/models/dashboard/drawer_menu_item_model.dart index 54a7bfc..cca277b 100644 --- a/lib/models/dashboard/drawer_menu_item_model.dart +++ b/lib/models/dashboard/drawer_menu_item_model.dart @@ -2,6 +2,8 @@ class DrawerMenuItem { String icon; String title; String routeName; + int? requestGroupId; + String? requestGroupName; - DrawerMenuItem(this.icon, this.title, this.routeName); + DrawerMenuItem(this.icon, this.title, this.routeName, {this.requestGroupId, this.requestGroupName}); } diff --git a/lib/provider/dashboard_provider_model.dart b/lib/provider/dashboard_provider_model.dart index 3476729..f3febdf 100644 --- a/lib/provider/dashboard_provider_model.dart +++ b/lib/provider/dashboard_provider_model.dart @@ -41,12 +41,21 @@ class DashboardProviderModel with ChangeNotifier, DiagnosticableTreeMixin { bool isMissingSwipeLoading = true; int missingSwipeCounter = 0; + bool isMyRequestLoading = true; + ListMenu? myRequest; + //Leave and Ticket Balance bool isLeaveTicketBalanceLoading = true; List? accrualList; + GetAccrualBalancesList? leaveBalanceAccrual; double get leaveBalance => leaveBalanceAccrual?.accrualNetEntitlement ?? 0; + + GetAccrualBalancesList? businessTripAccrual; + + double get businessTrip => businessTripAccrual?.accrualNetEntitlement ?? 0; + double ticketBalance = 0; //Menu Entries @@ -87,12 +96,18 @@ class DashboardProviderModel with ChangeNotifier, DiagnosticableTreeMixin { isWorkListLoading = true; workListCounter = 0; + isMyRequestLoading = true; + myRequest = null; + isMissingSwipeLoading = true; missingSwipeCounter = 0; + isWorkListLoading = true; + isLeaveTicketBalanceLoading = true; accrualList = null; leaveBalanceAccrual = null; + businessTripAccrual = null; ticketBalance = 0; isServicesMenusLoading = true; @@ -193,7 +208,8 @@ class DashboardProviderModel with ChangeNotifier, DiagnosticableTreeMixin { try { accrualList = await DashboardApiClient().getAccrualBalances(DateFormat("MM/dd/yyyy", "en_US").format(date)); isLeaveTicketBalanceLoading = false; - leaveBalanceAccrual = accrualList![0]; + leaveBalanceAccrual = accrualList!.singleWhere((element) => element.accuralPlanName == 'Annual Vacation Accrual' || element.accuralPlanName == "خطة استحقاق الاجازة الاعتيادية", orElse: null); + businessTripAccrual = accrualList!.singleWhere((element) => element.accuralPlanName == 'Business Trip Accrual' || element.accuralPlanName == "خطة استحقاق الإنتدابات", orElse: null); ticketBalance = (accrualList![1].accrualNetEntitlement ?? 0.0) + (accrualList![2].accrualNetEntitlement ?? 0.0) + (accrualList![3].accrualNetEntitlement ?? 0.0); notifyListeners(); } catch (ex) { @@ -211,17 +227,19 @@ class DashboardProviderModel with ChangeNotifier, DiagnosticableTreeMixin { void fetchListMenu() async { try { List menuList = await DashboardApiClient().getListMenu(); - List findMyRequest = menuList.where((element) => element.menuType == "E").toList(); - if (findMyRequest.isNotEmpty) { - drawerMenuItemList.add(DrawerMenuItem("assets/images/drawer/my_requests.svg", LocaleKeys.myRequest.tr(), AppRoutes.myRequests)); - } - List findMyTeam = menuList.where((element) => element.menuType == "M").toList(); - if (findMyTeam.isNotEmpty) { - AppState().setempStatusIsManager = true; - drawerMenuItemList.add(DrawerMenuItem("assets/images/drawer/my_team.svg", LocaleKeys.myTeamMembers.tr(), AppRoutes.myTeam)); + for (var menu in menuList) { + if (menu.menuType == "E") { + myRequest = menu; + } else if (menu.menuType == "M") { + AppState().setempStatusIsManager = true; + drawerMenuItemList.add(DrawerMenuItem("assets/images/drawer/my_team.svg", LocaleKeys.myTeamMembers.tr(), AppRoutes.myTeam)); + } } + isMyRequestLoading = false; + notifyListeners(); } catch (ex) { logger.wtf(ex); + notifyListeners(); Utils.handleException(ex, null, null); } } @@ -250,7 +268,7 @@ class DashboardProviderModel with ChangeNotifier, DiagnosticableTreeMixin { } } - void getCategoryOffersListAPI(BuildContext context) async { + void getCategoryOffersListAPI(BuildContext context) async { try { // Utils.showLoading(context); getOffersList = await OffersAndDiscountsApiClient().getOffersList(0, 10); diff --git a/lib/ui/landing/dashboard_screen.dart b/lib/ui/landing/dashboard_screen.dart index 27cd5ff..807e373 100644 --- a/lib/ui/landing/dashboard_screen.dart +++ b/lib/ui/landing/dashboard_screen.dart @@ -81,7 +81,7 @@ class _DashboardScreenState extends State with WidgetsBindingOb void checkSession() async { try { - await DashboardApiClient().getOpenMissingSwipes(); + await DashboardApiClient().getOpenNotifications(); } catch (ex) { Utils.handleException(ex, context, null); } diff --git a/lib/ui/landing/widget/menus_widget.dart b/lib/ui/landing/widget/menus_widget.dart index 2a0f2be..b9447b9 100644 --- a/lib/ui/landing/widget/menus_widget.dart +++ b/lib/ui/landing/widget/menus_widget.dart @@ -20,7 +20,7 @@ class MenusWidget extends StatelessWidget { return Consumer( builder: (cxt, data, child) { return GridView( - gridDelegate: const SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 2, childAspectRatio: 2 / 2, crossAxisSpacing: 9, mainAxisSpacing: 9), + gridDelegate: const SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 2, childAspectRatio: 1.75, crossAxisSpacing: 9, mainAxisSpacing: 9), padding: EdgeInsets.zero, shrinkWrap: true, primary: false, @@ -53,25 +53,52 @@ class MenusWidget extends StatelessWidget { ).onPress(() { Navigator.pushNamed(context, AppRoutes.workList); }), - if(env.dashboard.missingSwipe) - data.isMissingSwipeLoading + if (env.dashboard.missingSwipe) + data.isMissingSwipeLoading + ? MenuShimmer().onPress(() { + data.fetchWorkListCounter(context); + }) + : Container( + decoration: BoxDecoration( + color: Color(namesColor[1]), + borderRadius: BorderRadius.circular(10), + ), + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + LocaleKeys.missingSwipes.tr().toText12(color: Colors.white), + Row( + children: [ + Expanded( + child: data.missingSwipeCounter.toString().toText16(color: Colors.white, isBold: true, maxlines: 1), + ), + RotatedBox(quarterTurns: AppState().isArabic(context) ? 2 : 4, child: SvgPicture.asset("assets/images/arrow_next.svg", color: Colors.white)), + ], + ) + ], + ).paddingOnly(left: 10, right: 10, bottom: 6, top: 6), + ).onPress(() { + Navigator.pushNamed(context, AppRoutes.dynamicScreen, arguments: DynamicListViewParams(LocaleKeys.missingSwipes.tr(), "HMG_OTL_MISSING_SWIPE_EIT_SS")); + }), + data.isLeaveTicketBalanceLoading ? MenuShimmer().onPress(() { data.fetchWorkListCounter(context); }) : Container( decoration: BoxDecoration( - color: Color(namesColor[1]), + color: Color(namesColor[2]), borderRadius: BorderRadius.circular(10), ), child: Column( mainAxisAlignment: MainAxisAlignment.spaceBetween, crossAxisAlignment: CrossAxisAlignment.start, children: [ - LocaleKeys.missingSwipes.tr().toText12(color: Colors.white), + LocaleKeys.leaveBalance.tr().toText12(color: Colors.white), Row( children: [ Expanded( - child: data.missingSwipeCounter.toString().toText16(color: Colors.white, isBold: true, maxlines: 1), + child: data.leaveBalance.toStringAsFixed(2).toText16(color: Colors.white, isBold: true, maxlines: 1), ), RotatedBox(quarterTurns: AppState().isArabic(context) ? 2 : 4, child: SvgPicture.asset("assets/images/arrow_next.svg", color: Colors.white)), ], @@ -79,7 +106,7 @@ class MenusWidget extends StatelessWidget { ], ).paddingOnly(left: 10, right: 10, bottom: 6, top: 6), ).onPress(() { - Navigator.pushNamed(context, AppRoutes.dynamicScreen, arguments: DynamicListViewParams(LocaleKeys.missingSwipes.tr(), "HMG_OTL_MISSING_SWIPE_EIT_SS")); + Navigator.pushNamed(context, AppRoutes.leaveBalance); }), data.isLeaveTicketBalanceLoading ? MenuShimmer().onPress(() { @@ -94,11 +121,11 @@ class MenusWidget extends StatelessWidget { mainAxisAlignment: MainAxisAlignment.spaceBetween, crossAxisAlignment: CrossAxisAlignment.start, children: [ - LocaleKeys.leaveBalance.tr().toText12(color: Colors.white), + LocaleKeys.businessTripBalance.tr().toText12(color: Colors.white), Row( children: [ Expanded( - child: data.leaveBalance.toStringAsFixed(2).toText16(color: Colors.white, isBold: true, maxlines: 1), + child: data.businessTrip.toStringAsFixed(2).toText16(color: Colors.white, isBold: true, maxlines: 1), ), RotatedBox(quarterTurns: AppState().isArabic(context) ? 2 : 4, child: SvgPicture.asset("assets/images/arrow_next.svg", color: Colors.white)), ], @@ -108,10 +135,39 @@ class MenusWidget extends StatelessWidget { ).onPress(() { Navigator.pushNamed(context, AppRoutes.leaveBalance); }), - if(env.dashboard.ticketBalance) - data.isLeaveTicketBalanceLoading + if (env.dashboard.ticketBalance) + data.isLeaveTicketBalanceLoading + ? MenuShimmer().onPress(() { + data.fetchWorkListCounter(context); + }) + : Container( + decoration: BoxDecoration( + color: Color(namesColor[3]), + borderRadius: BorderRadius.circular(10), + ), + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + LocaleKeys.ticketBalance.tr().toText12(color: Colors.white), + Row( + children: [ + Expanded( + child: data.ticketBalance.toStringAsFixed(2).toText16(color: Colors.white, isBold: true, maxlines: 1), + ), + RotatedBox(quarterTurns: AppState().isArabic(context) ? 2 : 4, child: SvgPicture.asset("assets/images/arrow_next.svg", color: Colors.white)), + ], + ) + ], + ).paddingOnly(left: 10, right: 10, bottom: 6, top: 6), + ).onPress( + () { + Navigator.pushNamed(context, AppRoutes.dynamicScreen, arguments: DynamicListViewParams(LocaleKeys.ticketBalance.tr(), "HMG_TKT_NEW_EIT_SS")); + }, + ), + data.isMyRequestLoading ? MenuShimmer().onPress(() { - data.fetchWorkListCounter(context); + data.fetchListMenu(); }) : Container( decoration: BoxDecoration( @@ -122,12 +178,13 @@ class MenusWidget extends StatelessWidget { mainAxisAlignment: MainAxisAlignment.spaceBetween, crossAxisAlignment: CrossAxisAlignment.start, children: [ - LocaleKeys.ticketBalance.tr().toText12(color: Colors.white), + LocaleKeys.myRequest.tr().toText12(color: Colors.white), Row( + mainAxisAlignment: MainAxisAlignment.end, children: [ - Expanded( - child: data.ticketBalance.toStringAsFixed(2).toText16(color: Colors.white, isBold: true, maxlines: 1), - ), + // Expanded( + // child: data.ticketBalance.toStringAsFixed(2).toText16(color: Colors.white, isBold: true, maxlines: 1), + // ), RotatedBox(quarterTurns: AppState().isArabic(context) ? 2 : 4, child: SvgPicture.asset("assets/images/arrow_next.svg", color: Colors.white)), ], ) @@ -135,7 +192,7 @@ class MenusWidget extends StatelessWidget { ).paddingOnly(left: 10, right: 10, bottom: 6, top: 6), ).onPress( () { - Navigator.pushNamed(context, AppRoutes.dynamicScreen, arguments: DynamicListViewParams(LocaleKeys.ticketBalance.tr(), "HMG_TKT_NEW_EIT_SS")); + Navigator.pushNamed(context, AppRoutes.myRequests,arguments: data.myRequest!.requestGroupId); }, ) ], diff --git a/lib/ui/screens/my_requests/my_requests.dart b/lib/ui/screens/my_requests/my_requests.dart index dd6147f..a9166b4 100644 --- a/lib/ui/screens/my_requests/my_requests.dart +++ b/lib/ui/screens/my_requests/my_requests.dart @@ -33,21 +33,26 @@ class _MyRequestsState extends State { List getCCPTransactionsList = []; + int? groupId; bool isNewRequest = false; @override void initState() { - getConcurrentPrograms(); super.initState(); } @override Widget build(BuildContext context) { + if (groupId == null) { + groupId = ModalRoute.of(context)!.settings.arguments as int; + getConcurrentPrograms(); + } + return Scaffold( backgroundColor: Colors.white, appBar: AppBarWidget( context, - title: LocaleKeys.concurrentReports, + title: LocaleKeys.concurrentReports.tr(), ), body: Column( children: [ @@ -76,70 +81,72 @@ class _MyRequestsState extends State { }), ), 12.height, - getCCPTransactionsList.isNotEmpty ? Expanded( - child: ListView.separated( - physics: const BouncingScrollPhysics(), - shrinkWrap: true, - itemBuilder: (BuildContext context, int index) { - return Container( - width: double.infinity, - padding: const EdgeInsets.only(left: 12, right: 12, top: 10, bottom: 12), - margin: const EdgeInsets.only(left: 12, right: 12, top: 10, bottom: 0), - decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.circular(10), - boxShadow: [ - BoxShadow( - color: const Color(0xff000000).withOpacity(.05), - blurRadius: 26, - offset: const Offset(0, -3), - ), - ], - ), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Row( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - ("Request ID: " + getCCPTransactionsList[index].rEQUESTID.toString()).toText12(color: MyColors.grey57Color), - DateUtil.formatDateToDate(DateUtil.convertStringToDate(getCCPTransactionsList[index].rEQUESTDATE!), false).toText12(color: MyColors.grey70Color), - ], - ), - Container( - padding: const EdgeInsets.only(top: 10.0), - child: ("Phase: " + getCCPTransactionsList[index].cCPPHASE!).toText12(color: MyColors.grey57Color, isBold: true), - ), - Container( - padding: const EdgeInsets.only(top: 10.0), - child: "Program Name: ".toText12(color: MyColors.grey57Color, isBold: true), - ), - getCCPTransactionsList[index].cONCURRENTPROGRAMNAME!.toText12(color: MyColors.gradiantEndColor), - Container( - padding: const EdgeInsets.only(top: 10.0), - child: InkWell( - onTap: () { - getCCPOutput(getCCPTransactionsList[index].rEQUESTID.toString()); - }, - child: Row( - children: [ - "Output: ".toText12(color: MyColors.grey57Color), - 8.width, - "Open PDF".toText12(color: MyColors.grey57Color), - 6.width, - const Icon(Icons.launch, size: 16.0), - ], - ), + getCCPTransactionsList.isNotEmpty + ? Expanded( + child: ListView.separated( + physics: const BouncingScrollPhysics(), + shrinkWrap: true, + itemBuilder: (BuildContext context, int index) { + return Container( + width: double.infinity, + padding: const EdgeInsets.only(left: 12, right: 12, top: 10, bottom: 12), + margin: const EdgeInsets.only(left: 12, right: 12, top: 10, bottom: 0), + decoration: BoxDecoration( + color: Colors.white, + borderRadius: BorderRadius.circular(10), + boxShadow: [ + BoxShadow( + color: const Color(0xff000000).withOpacity(.05), + blurRadius: 26, + offset: const Offset(0, -3), + ), + ], + ), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + ("Request ID: " + getCCPTransactionsList[index].rEQUESTID.toString()).toText12(color: MyColors.grey57Color), + DateUtil.formatDateToDate(DateUtil.convertStringToDate(getCCPTransactionsList[index].rEQUESTDATE!), false).toText12(color: MyColors.grey70Color), + ], + ), + Container( + padding: const EdgeInsets.only(top: 10.0), + child: ("Phase: " + getCCPTransactionsList[index].cCPPHASE!).toText12(color: MyColors.grey57Color, isBold: true), + ), + Container( + padding: const EdgeInsets.only(top: 10.0), + child: "Program Name: ".toText12(color: MyColors.grey57Color, isBold: true), + ), + getCCPTransactionsList[index].cONCURRENTPROGRAMNAME!.toText12(color: MyColors.gradiantEndColor), + Container( + padding: const EdgeInsets.only(top: 10.0), + child: InkWell( + onTap: () { + getCCPOutput(getCCPTransactionsList[index].rEQUESTID.toString()); + }, + child: Row( + children: [ + "Output: ".toText12(color: MyColors.grey57Color), + 8.width, + "Open PDF".toText12(color: MyColors.grey57Color), + 6.width, + const Icon(Icons.launch, size: 16.0), + ], + ), + ), + ), + ], ), - ), - ], - ), - ); - }, - separatorBuilder: (BuildContext context, int index) => 12.height, - itemCount: getCCPTransactionsList.length), - ) : Container(), + ); + }, + separatorBuilder: (BuildContext context, int index) => 12.height, + itemCount: getCCPTransactionsList.length), + ) + : Container(), ], ).expanded, 1.divider, @@ -160,7 +167,7 @@ class _MyRequestsState extends State { void getConcurrentPrograms() async { try { Utils.showLoading(context); - getConcurrentProgramsList = await MyRequestsApiClient().getConcurrentPrograms(); + getConcurrentProgramsList = await MyRequestsApiClient().getConcurrentPrograms(groupId!); Utils.hideLoading(context); setState(() {}); } catch (ex) { diff --git a/lib/ui/screens/my_requests/new_request.dart b/lib/ui/screens/my_requests/new_request.dart index 3b138b8..27cd29d 100644 --- a/lib/ui/screens/my_requests/new_request.dart +++ b/lib/ui/screens/my_requests/new_request.dart @@ -34,20 +34,25 @@ class _NewRequestState extends State { List? getCCPDFFStructureModelList; DateTime selectedDate = DateTime.now(); + int? groupId; @override void initState() { - getConcurrentPrograms(); super.initState(); } @override Widget build(BuildContext context) { + if (groupId == null) { + groupId = ModalRoute.of(context)!.settings.arguments as int; + getConcurrentPrograms(); + } + return Scaffold( backgroundColor: Colors.white, appBar: AppBarWidget( context, - title: LocaleKeys.concurrentReports, + title: LocaleKeys.concurrentReports.tr(), ), body: Column( children: [ @@ -135,7 +140,7 @@ class _NewRequestState extends State { void getConcurrentPrograms() async { try { Utils.showLoading(context); - getConcurrentProgramsList = await MyRequestsApiClient().getConcurrentPrograms(); + getConcurrentProgramsList = await MyRequestsApiClient().getConcurrentPrograms(groupId!); Utils.hideLoading(context); setState(() {}); } catch (ex) { @@ -215,13 +220,15 @@ class _NewRequestState extends State { pIDCOLUMNNAME: DateFormat('yyyy/MM/dd HH:MM:SS', "en_US").format(date1), pRETURNMSG: "null", pRETURNSTATUS: getCCPDFFStructureModelList![index].dEFAULTVALUE, - pVALUECOLUMNNAME: getCCPDFFStructureModelList![index].isDefaultTypeIsCDPS ? DateFormat('yyyy/MM/dd HH:MM:SS', "en_US").format(date) : DateFormat('yyyy-MM-ddThh:mm:ss.s').format(date)); + pVALUECOLUMNNAME: + getCCPDFFStructureModelList![index].isDefaultTypeIsCDPS ? DateFormat('yyyy/MM/dd HH:MM:SS', "en_US").format(date) : DateFormat('yyyy-MM-ddThh:mm:ss.s').format(date)); } else { eservicesdv = ESERVICESDV( pIDCOLUMNNAME: DateFormat('yyyy-MM-dd', "en_US").format(date1), pRETURNMSG: "null", pRETURNSTATUS: getCCPDFFStructureModelList![index].dEFAULTVALUE, - pVALUECOLUMNNAME: getCCPDFFStructureModelList![index].isDefaultTypeIsCDPS ? DateFormat('yyyy-MM-dd hh:mm:ss', "en_US").format(date) : DateFormat('yyyy-MM-ddThh:mm:ss.s').format(date)); + pVALUECOLUMNNAME: + getCCPDFFStructureModelList![index].isDefaultTypeIsCDPS ? DateFormat('yyyy-MM-dd hh:mm:ss', "en_US").format(date) : DateFormat('yyyy-MM-ddThh:mm:ss.s').format(date)); } getCCPDFFStructureModelList![index].eSERVICESDV = eservicesdv; setState(() {});