ui updates

master
Sultan khan 2 days ago
parent f483c858ef
commit c32b155718

@ -7,6 +7,7 @@ import 'package:mohem_flutter_app/models/generic_response_model.dart';
import 'package:mohem_flutter_app/models/member_information_list_model.dart';
import 'package:mohem_flutter_app/models/member_login_list_model.dart';
import 'package:mohem_flutter_app/models/my_team/get_employee_subordinates_list.dart';
import 'package:mohem_flutter_app/models/offers_and_discounts/wala_plus_city_model.dart';
import 'package:mohem_flutter_app/models/post_params_model.dart';
import 'package:mohem_flutter_app/models/privilege_list_model.dart';
import 'package:mohem_flutter_app/models/worklist_response_model.dart';
@ -140,6 +141,12 @@ class AppState {
set setIsEmpLastLoginToDevice(bool? val) => _isEmpLastLoginToDevice = val;
WalaPlusCityModel? _selectedMazayaCity;
WalaPlusCityModel? get selectedMazayaCity => _selectedMazayaCity;
set setSelectedMazayaCity(WalaPlusCityModel? city) => _selectedMazayaCity = city;
void setPostParamsInitConfig() {
isAuthenticated = false;
isLogged = false;
@ -151,6 +158,7 @@ class AppState {
_dependentDob = null;
_authenticationTokenID = null;
_isEmpLastLoginToDevice = null;
_selectedMazayaCity = null;
_postParamsInitConfig.pLegislationCode = null;
_postParams = _postParamsInitConfig;
}

@ -4,12 +4,12 @@ class ApiConsts {
// static String baseUrl = "http://10.201.214.101:2027"; // Local server
// static String baseUrl = "https://erptstapp.srca.org.sa"; // SRCA server
static String baseUrl = "https://uat.hmgwebservices.com"; // UAT server
// static String baseUrl = "https://uat.hmgwebservices.com"; // UAT server
// static String baseUrl = "http://10.201.204.101:2024";
// static String baseUrl = "https://webservices.hmg.com"; // PreProd
// static String baseUrl = "https://hmgwebservices.com"; // Live server
// static String baseUrl = "https://mohemm.hmg.com"; // New Live server
static String baseUrl = "https://mohemm.hmg.com"; // New Live server
static String ssoBaseUrl = "https://sso.hmg.com"; // New Live server
//
// static String baseUrl = "https://uat.hmgwebservices.com"; //

@ -27,14 +27,14 @@ class ChatHome extends StatefulWidget {
class _ChatHomeState extends State<ChatHome> {
int tabIndex = 0;
PageController controller = PageController();
late ChatProviderModel data;
late ChatProviderModel data;
@override
void initState() {
super.initState();
data = Provider.of<ChatProviderModel>(context, listen: false);
if (chatHubConnection?.state == HubConnectionState.Connected) {
data = Provider.of<ChatProviderModel>(context, listen: false);
data.registerEvents();
}
}

@ -1,4 +1,5 @@
import 'dart:async';
import 'dart:convert';
import 'package:easy_localization/easy_localization.dart';
import 'package:flutter/material.dart';
@ -65,7 +66,7 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
// Fixed-category sections - to point a section at a different category, change only the id
// passed here. Everything else (fetch, title, UI) reads off the _MazayaCategorySection object.
final _MazayaCategorySection _travelSection = _MazayaCategorySection('Q4');
final _MazayaCategorySection _travelSection = _MazayaCategorySection('p03');
final _MazayaCategorySection _homeKitchenSection = _MazayaCategorySection(
'Bw',
);
@ -73,11 +74,33 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
@override
void initState() {
super.initState();
selectedCity = AppState().selectedMazayaCity;
_fetchCategories();
_fetchExclusiveOffers();
_fetchLatestOnMazaya();
_fetchCategorySection(_travelSection);
_fetchCategorySection(_homeKitchenSection);
_initCityAndFetchSections();
}
Future<void> _initCityAndFetchSections() async {
if (selectedCity == null) {
String savedCityJson = await Utils.getStringFromPrefs("MAZAYA_SELECTED_CITY");
if (savedCityJson.isNotEmpty && mounted) {
try {
WalaPlusCityModel city = WalaPlusCityModel.fromJson(jsonDecode(savedCityJson));
if (!city.isAllCities) {
AppState().setSelectedMazayaCity = city;
selectedCity = city;
if (mounted) setState(() {});
}
} catch (e) {
debugPrint("Error restoring saved city: $e");
}
}
}
if (mounted) {
_fetchLatestOnMazaya();
_fetchCategorySection(_travelSection);
_fetchCategorySection(_homeKitchenSection);
}
}
@override
@ -185,9 +208,15 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
// embedded in each retailer (kept as a fallback for when the id isn't in the top-level list).
// fallbackTitle only shows while neither source has resolved a name yet.
String _sectionTitle(_MazayaCategorySection section, String fallbackTitle) {
bool isAr = mounted ? AppState().isArabic(context) : false;
for (WalaPlusCategoryModel c in _categories) {
if (c.id == section.categoryId && (c.name ?? '').isNotEmpty) {
return c.name!;
if (c.id == section.categoryId) {
if (isAr && c.countryNameAr != null && c.countryNameAr!.trim().isNotEmpty) {
return c.countryNameAr!.trim();
}
if ((c.name ?? '').isNotEmpty) {
return c.name!;
}
}
}
if (section.resolvedName != null && section.resolvedName!.isNotEmpty) {
@ -261,8 +290,8 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
);
}
void _openRetailersGrid({WalaPlusCategoryModel? category}) {
Navigator.pushNamed(
Future<void> _openRetailersGrid({WalaPlusCategoryModel? category}) async {
await Navigator.pushNamed(
context,
AppRoutes.retailersListScreen,
// Carries the currently selected city along so RetailersListScreen starts on it instead
@ -272,13 +301,19 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
if (selectedCity != null) 'city': selectedCity,
},
);
if (mounted && selectedCity?.cityId != AppState().selectedMazayaCity?.cityId) {
setState(() => selectedCity = AppState().selectedMazayaCity);
_fetchLatestOnMazaya();
_fetchCategorySection(_travelSection);
_fetchCategorySection(_homeKitchenSection);
}
}
// Exclusive offers reuse the legacy Offers & Discounts API (see fetchExclusiveOffers in both
// this screen and RetailersListScreen), so "See all" opens RetailersListScreen's exclusive
// mode instead of a WalaPlus category.
void _openExclusiveOffersGrid() {
Navigator.pushNamed(
Future<void> _openExclusiveOffersGrid() async {
await Navigator.pushNamed(
context,
AppRoutes.retailersListScreen,
arguments: <String, dynamic>{
@ -286,13 +321,19 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
if (selectedCity != null) 'city': selectedCity,
},
);
if (mounted && selectedCity?.cityId != AppState().selectedMazayaCity?.cityId) {
setState(() => selectedCity = AppState().selectedMazayaCity);
_fetchLatestOnMazaya();
_fetchCategorySection(_travelSection);
_fetchCategorySection(_homeKitchenSection);
}
}
// Tapping the search field opens the same "all categories / newest" data as "Latest on
// Mazaya"'s See all, but with the category hero hidden and the search bar auto-focused with
// the keyboard open (see RetailersListScreen's isSearchMode) instead of landing on Travel.
void _openSearchGrid() {
Navigator.pushNamed(
Future<void> _openSearchGrid() async {
await Navigator.pushNamed(
context,
AppRoutes.retailersListScreen,
arguments: <String, dynamic>{
@ -304,6 +345,12 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
if (selectedCity != null) 'city': selectedCity,
},
);
if (mounted && selectedCity?.cityId != AppState().selectedMazayaCity?.cityId) {
setState(() => selectedCity = AppState().selectedMazayaCity);
_fetchLatestOnMazaya();
_fetchCategorySection(_travelSection);
_fetchCategorySection(_homeKitchenSection);
}
}
Future<void> _onRefresh() async {
@ -326,6 +373,7 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
await Utils.removeStringFromPrefs("P_DEP_MOBILE_NUMBER");
await Utils.removeStringFromPrefs("P_DEPENDENT_NAME");
await Utils.removeStringFromPrefs("P_DEP_LOGIN_TYPE");
await Utils.removeStringFromPrefs("MAZAYA_SELECTED_CITY");
}
// Same app bar actions as the previous dependent-login landing page
@ -349,6 +397,8 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
AppState().setDependentDob = null;
AppState().setDependentLoginType = null;
AppState().setWalaplusDepInfoModel = null;
AppState().setSelectedMazayaCity = null;
await Utils.removeStringFromPrefs("MAZAYA_SELECTED_CITY");
AppState().setPostParamsInitConfig();
if (mounted) {
Navigator.pushNamedAndRemoveUntil(
@ -407,11 +457,11 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
appBar: AppBarWidget(
context,
title: LocaleKeys.mazayaDeals.tr(),
showHomeButton: false,
showHomeButton: true,
// Discover is the dependent-login landing page - no back button there (logout is still
// reachable via the explicit logout action below). Employees reaching Discover from the
// regular dashboard can still pop back normally.
showBackButton: !ApiConsts.isDependetLogin,
showBackButton: false,
onBackTapped: () {
if (Navigator.canPop(context)) {
Navigator.pop(context);
@ -587,7 +637,17 @@ class _MazayaDiscoverScreenState extends State<MazayaDiscoverScreen> {
context,
selectedCityId: selectedCity?.cityId,
onCitySelected: (city) {
setState(() => selectedCity = city);
WalaPlusCityModel? newCity = city.isAllCities ? null : city;
AppState().setSelectedMazayaCity = newCity;
if (newCity != null) {
Utils.saveStringFromPrefs(
"MAZAYA_SELECTED_CITY",
jsonEncode(newCity.toJson()),
);
} else {
Utils.removeStringFromPrefs("MAZAYA_SELECTED_CITY");
}
setState(() => selectedCity = newCity);
_fetchLatestOnMazaya();
_fetchCategorySection(_travelSection);
_fetchCategorySection(_homeKitchenSection);

@ -843,10 +843,11 @@ class _RetailerDetailsScreenState extends State<RetailerDetailsScreen> {
// 5. Locations Section (Preview Cards + View All)
_buildLocationsSection(isAr),
// 6. Good to Know Section
_buildGoodToKnowSection(isAr),
20.height,
// 6. Good to Know & Terms and Conditions Section (standard Mazaya only)
if (_retailer?.isExclusive != true) ...[
_buildGoodToKnowSection(isAr),
20.height,
],
],
),
),
@ -1459,6 +1460,9 @@ class _RetailerDetailsScreenState extends State<RetailerDetailsScreen> {
}
Widget _buildGoodToKnowSection(bool isAr) {
if (_retailer?.isExclusive == true) {
return const SizedBox.shrink();
}
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
@ -1490,9 +1494,7 @@ class _RetailerDetailsScreenState extends State<RetailerDetailsScreen> {
const Divider(height: 1, thickness: 1, color: Color(0xFFE2E8F0)),
14.height,
InkWell(
onTap: () {
// Terms & conditions link will be provided later
},
onTap:_openMerchantWebsite,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
@ -1511,23 +1513,23 @@ class _RetailerDetailsScreenState extends State<RetailerDetailsScreen> {
14.height,
const Divider(height: 1, thickness: 1, color: Color(0xFFE2E8F0)),
14.height,
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
LocaleKeys.haveAQuestionAboutOffer.tr().toText13(
color: const Color(0xFF64748B),
),
InkWell(
onTap: () {
// Get help link will be provided later
},
child: LocaleKeys.getHelp.tr().toText13(
color: const Color(0xFF0D9488),
isBold: true,
),
),
],
),
// Row(
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
// children: [
// LocaleKeys.haveAQuestionAboutOffer.tr().toText13(
// color: const Color(0xFF64748B),
// ),
// InkWell(
// onTap: () {
// // Get help link will be provided later
// },
// child: LocaleKeys.getHelp.tr().toText13(
// color: const Color(0xFF0D9488),
// isBold: true,
// ),
// ),
// ],
// ),
],
);
}

@ -1,4 +1,5 @@
import 'dart:async';
import 'dart:convert';
import 'package:easy_localization/easy_localization.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
@ -130,6 +131,8 @@ class _RetailersListScreenState extends State<RetailersListScreen> {
// resetting back to "All Cities" until the user explicitly changes it on this page.
if (args is Map && args['city'] is WalaPlusCityModel) {
selectedCity = args['city'] as WalaPlusCityModel;
} else if (AppState().selectedMazayaCity != null) {
selectedCity = AppState().selectedMazayaCity;
}
}
}
@ -519,7 +522,10 @@ class _RetailersListScreenState extends State<RetailersListScreen> {
sortBy: _filterSortBy,
radius: radiusParam,
minDiscount: minDiscountParam,
cityId: selectedCity?.cityId,
cityId:
(selectedCity != null && !selectedCity!.isAllCities)
? selectedCity!.cityId
: null,
context: wantsNearest ? context : null,
userReference: null,
);
@ -588,7 +594,10 @@ class _RetailersListScreenState extends State<RetailersListScreen> {
sortBy: _filterSortBy,
radius: radiusParam,
minDiscount: minDiscountParam,
cityId: selectedCity?.cityId,
cityId:
(selectedCity != null && !selectedCity!.isAllCities)
? selectedCity!.cityId
: null,
context: wantsNearest ? context : null,
userReference: null,
);
@ -1039,6 +1048,7 @@ class _RetailersListScreenState extends State<RetailersListScreen> {
isLoadingMore: isLoadingMore,
onTapRetailer: _openRetailer,
onFavoriteTap: _toggleFavorite,
mainAxisExtent: isExclusiveMode ? 190 : null,
),
],
),
@ -1494,7 +1504,17 @@ class _RetailersListScreenState extends State<RetailersListScreen> {
context,
selectedCityId: selectedCity?.cityId,
onCitySelected: (city) {
setState(() => selectedCity = city);
WalaPlusCityModel? newCity = city.isAllCities ? null : city;
AppState().setSelectedMazayaCity = newCity;
if (newCity != null) {
Utils.saveStringFromPrefs(
"MAZAYA_SELECTED_CITY",
jsonEncode(newCity.toJson()),
);
} else {
Utils.removeStringFromPrefs("MAZAYA_SELECTED_CITY");
}
setState(() => selectedCity = newCity);
String effectiveCategoryId =
_selectedSubcategoryId ??
(currentCategoryId.isEmpty
@ -1946,6 +1966,10 @@ class WalaPlusRetailerCard extends StatelessWidget {
if (cityText.trim().isEmpty) {
cityText = item.displayCity;
}
bool hasChips =
offerTypes.isNotEmpty ||
cityText.trim().isNotEmpty ||
usageText.trim().isNotEmpty;
return InkWell(
borderRadius: BorderRadius.circular(18),
@ -2092,64 +2116,66 @@ class WalaPlusRetailerCard extends StatelessWidget {
isBold: true,
color: const Color(0xFF147D6B),
),
const SizedBox(height: 6),
// Fully-rounded pill badges (no icon, no border) matching the new design - type
// chips in blue (In-store) / green (Online), city in grey.
SizedBox(
height: 28,
child: ListView(
scrollDirection: Axis.horizontal,
physics: const BouncingScrollPhysics(),
children: <Widget>[
for (String offerType in offerTypes) ...<Widget>[
InfoChipWidget(
text: getTypeFilterTitle(offerType),
backgroundColor:
offerType == 'online'
? const Color(0xFFEAF3EE)
: const Color(0x14062CFF),
textColor:
offerType == 'online'
? const Color(0xFF147D6B)
: const Color(0xFF2A56B6),
borderColor: Colors.transparent,
borderWidth: 0,
isBold: false,
horizontalPadding: 10,
verticalPadding: 6,
borderRadius: 99,
),
const SizedBox(width: 5),
],
if (cityText.trim().isNotEmpty) ...<Widget>[
InfoChipWidget(
text: cityText,
backgroundColor: const Color(0xFFEFF2EF),
textColor: const Color(0xFF464746),
borderColor: Colors.transparent,
borderWidth: 0,
isBold: false,
horizontalPadding: 10,
verticalPadding: 6,
borderRadius: 99,
),
const SizedBox(width: 5),
if (hasChips) ...<Widget>[
const SizedBox(height: 6),
// Fully-rounded pill badges (no icon, no border) matching the new design - type
// chips in blue (In-store) / green (Online), city in grey.
SizedBox(
height: 28,
child: ListView(
scrollDirection: Axis.horizontal,
physics: const BouncingScrollPhysics(),
children: <Widget>[
for (String offerType in offerTypes) ...<Widget>[
InfoChipWidget(
text: getTypeFilterTitle(offerType),
backgroundColor:
offerType == 'online'
? const Color(0xFFEAF3EE)
: const Color(0x14062CFF),
textColor:
offerType == 'online'
? const Color(0xFF147D6B)
: const Color(0xFF2A56B6),
borderColor: Colors.transparent,
borderWidth: 0,
isBold: false,
horizontalPadding: 10,
verticalPadding: 6,
borderRadius: 99,
),
const SizedBox(width: 5),
],
if (cityText.trim().isNotEmpty) ...<Widget>[
InfoChipWidget(
text: cityText,
backgroundColor: const Color(0xFFEFF2EF),
textColor: const Color(0xFF464746),
borderColor: Colors.transparent,
borderWidth: 0,
isBold: false,
horizontalPadding: 10,
verticalPadding: 6,
borderRadius: 99,
),
const SizedBox(width: 5),
],
if (usageText.trim().isNotEmpty)
InfoChipWidget(
text: usageText,
backgroundColor: const Color(0xFFFEF3C7),
textColor: const Color(0xFFB45309),
borderColor: Colors.transparent,
borderWidth: 0,
isBold: false,
horizontalPadding: 10,
verticalPadding: 6,
borderRadius: 99,
),
],
if (usageText.trim().isNotEmpty)
InfoChipWidget(
text: usageText,
backgroundColor: const Color(0xFFFEF3C7),
textColor: const Color(0xFFB45309),
borderColor: Colors.transparent,
borderWidth: 0,
isBold: false,
horizontalPadding: 10,
verticalPadding: 6,
borderRadius: 99,
),
],
),
),
),
],
],
),
),

@ -260,7 +260,7 @@ class _SavedRetailersScreenState extends State<SavedRetailersScreen> {
showHomeButton: false,
// Reached from the Mazaya bottom nav - same as Discover, no back button for a
// dependent-login session since this is one of their root tabs, not a pushed screen.
showBackButton: !ApiConsts.isDependetLogin,
showBackButton: false,
),
bottomNavigationBar: const MazayaBottomNav(currentTab: MazayaTab.saved),
body: Column(

@ -16,6 +16,7 @@ class WalaPlusRetailerGrid extends StatelessWidget {
final void Function(WalaPlusRetailerModel item) onFavoriteTap;
final bool isLoadingMore;
final int shimmerItemCount;
final double? mainAxisExtent;
const WalaPlusRetailerGrid({
Key? key,
@ -26,10 +27,33 @@ class WalaPlusRetailerGrid extends StatelessWidget {
required this.onFavoriteTap,
this.isLoadingMore = false,
this.shimmerItemCount = 4,
this.mainAxisExtent,
}) : super(key: key);
bool get _hasAnyChips {
for (WalaPlusRetailerModel r in retailers) {
if (r.normalizedTypes.isNotEmpty ||
r.displayCity.trim().isNotEmpty ||
r.displayUsage.trim().isNotEmpty) {
return true;
}
}
return false;
}
double get _effectiveMainAxisExtent {
if (mainAxisExtent != null) return mainAxisExtent!;
if (retailers.isNotEmpty && !_hasAnyChips) return 190;
return 235;
}
SliverGridDelegateWithFixedCrossAxisCount get _gridDelegate =>
SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: isTablet ? 4 : 2, mainAxisExtent: 235, crossAxisSpacing: 12, mainAxisSpacing: 16);
SliverGridDelegateWithFixedCrossAxisCount(
crossAxisCount: isTablet ? 4 : 2,
mainAxisExtent: _effectiveMainAxisExtent,
crossAxisSpacing: 12,
mainAxisSpacing: 16,
);
@override
Widget build(BuildContext context) {
@ -71,25 +95,28 @@ class WalaPlusRetailerGrid extends StatelessWidget {
}
Widget _buildShimmerCard() {
bool showChips = _effectiveMainAxisExtent > 200;
return Container(
decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(20)),
padding: const EdgeInsets.all(10),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Container(height: 120, width: double.infinity, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(14))),
Container(height: 110, width: double.infinity, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(14))),
const SizedBox(height: 8),
Container(height: 14, width: 110, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(4))),
const SizedBox(height: 6),
Container(height: 14, width: 80, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(4))),
const SizedBox(height: 6),
Row(
children: <Widget>[
Container(height: 28, width: 50, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(6))),
const SizedBox(width: 5),
Container(height: 28, width: 45, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(6))),
],
),
if (showChips) ...<Widget>[
const SizedBox(height: 6),
Row(
children: <Widget>[
Container(height: 28, width: 50, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(6))),
const SizedBox(width: 5),
Container(height: 28, width: 45, decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(6))),
],
),
],
],
),
);

@ -203,11 +203,11 @@ class _FamilyMembersState extends State<FamilyMembers> {
padding: const EdgeInsets.symmetric(horizontal: 16),
child: Row(
children: <Widget>[
InkWell(
!fromMazaya? InkWell(
borderRadius: BorderRadius.circular(20),
onTap: () => Navigator.pop(context),
child: const Padding(padding: EdgeInsets.all(8.0), child: Icon(Icons.arrow_back_ios_new_rounded, size: 20, color: Color(0xFF1E293B))),
),
):SizedBox(),
const SizedBox(width: 8),
// Same title style as the other Mazaya tabs' headers (Discover/Saved use
// AppBarWidget's title.toText24(isBold: true, color: MyColors.darkTextColor)) -

@ -212,13 +212,19 @@ class SelectedItemSheet extends StatelessWidget {
var requestDetails = AppState().requestAllList![AppState().itgWorkListIndex!];
if (apiMode == "Delegate") {
await WorkListApiClient().delegateITGRequest(requestDetails.requestType!, requestDetails.iD, requestDetails.itemID, AppState().memberInformationList?.eMPLOYEENUMBER ?? "",
isITGRequest ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
//commented the previous one because we need the replacement in both cases
favoriteReplacements !=null ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
// isITGRequest ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
} else if (apiMode == "RequestInformation") {
await WorkListApiClient().informationITGRequest(requestDetails.requestType!, requestDetails.iD, requestDetails.itemID, AppState().memberInformationList?.eMPLOYEENUMBER ?? "",
isITGRequest ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
//commented the previous one because we need the replacement in both cases
// isITGRequest ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
favoriteReplacements !=null ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
} else if (apiMode == "Answer") {
await WorkListApiClient().answerITGRequest(requestDetails.requestType!, requestDetails.iD, requestDetails.itemID, AppState().memberInformationList?.eMPLOYEENUMBER ?? "",
isITGRequest ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
//commented the previous one because we need the replacement in both cases
favoriteReplacements !=null ? favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
//favoriteReplacements!.userName! : actionHistoryList!.uSERNAME!, comment);
}
Utils.hideLoading(context);
Navigator.pop(context, "delegate_reload");

Loading…
Cancel
Save