improvements.

merge-requests/22/head
Sikander Saleem 3 years ago
parent 534aab3ceb
commit 4f37bb9476

@ -1,9 +1,9 @@
class URLs{
URLs._();
static const host2 = "http://194.163.164.213/atoms/api";
// static const host1 = "https://atomsdev.hmg.com/api"; // uat url
static const host1 = "https://atomsuat.hmg.com"; // uat url
static const host1 = "http://109.123.243.118:9000";
// static const host1 = "http://109.123.243.118:9000";
static String _baseUrl = "$_host/mobile";

@ -53,7 +53,7 @@ class NotificationsProvider extends ChangeNotifier{
// userId = 397.toString(); // testing id to view data
try{
response = await get(
Uri.parse(host+URLs.getNotifications
Uri.parse(URLs.getNotifications
+"?uid=${user.id}"
"&token=${user.token}"
"&page=${(notifications?.length ?? 0) ~/pageItemNumber}"),

@ -330,13 +330,13 @@ class _LandPageState extends State<LandPage> {
),
],
),
DrawerItem(
icon: Icons.notifications,
title: _subtitle.notifications,
onPressed: () {
Navigator.of(context).pushNamed(NotificationsPage.id);
},
),
// DrawerItem(
// icon: Icons.notifications,
// title: _subtitle.notifications,
// onPressed: () {
// Navigator.of(context).pushNamed(NotificationsPage.id);
// },
// ),
DrawerItem(
icon: Icons.mail,
title: _subtitle.email,

@ -43,18 +43,7 @@ class _AutoCompletePartsFieldState extends State<AutoCompletePartsField> {
_userProvider = Provider.of<UserProvider>(context);
_partsProvider = Provider.of<PartsProvider>(context);
//Subtitle _subtitle = AppLocalization.of(context).subtitle;
return LoadingManager(
isLoading: _partsProvider.isLoading,
isFailedLoading: _partsProvider.parts == null,
stateCode: _partsProvider.stateCode,
onRefresh: () async {
_partsProvider.reset();
await _partsProvider.getParts(
host: _settingProvider.host,
user: _userProvider.user,
);
},
child: Container(
return Container(
padding: const EdgeInsets.symmetric(
horizontal: 16
),
@ -102,7 +91,6 @@ class _AutoCompletePartsFieldState extends State<AutoCompletePartsField> {
widget.onPick(part);
},
),
),
);
}
}

Loading…
Cancel
Save