mirror of
https://git.meshkee.com/applications/cssd.git
synced 2026-10-14 04:58:54 +03:30
Fix loading bug in item
This commit is contained in:
@@ -64,12 +64,17 @@ class _ItemAddScreenState extends State<ItemAddScreen> {
|
||||
batchId,
|
||||
)
|
||||
.then(
|
||||
(result) {
|
||||
(result) async {
|
||||
setState(() {
|
||||
isLoading = false;
|
||||
});
|
||||
if (result == 'done') {
|
||||
Navigator.of(context).popAndPushNamed(Routes.itemResultScreen);
|
||||
// Navigator.of(context).popAndPushNamed(Routes.itemResultScreen);
|
||||
Navigator.of(context).pop();
|
||||
var items = await Provider.of<ItemProvider>(context, listen: false);
|
||||
items.setLoading();
|
||||
items.resetPageNumber();
|
||||
items.getItemResults().then((value) => {items.resetLoading()});
|
||||
Fluttertoast.showToast(
|
||||
msg: "Item added.",
|
||||
toastLength: Toast.LENGTH_SHORT,
|
||||
|
||||
Reference in New Issue
Block a user