mirror of
https://github.com/HendrikRauh/inventree-app.git
synced 2026-01-13 03:26:24 +00:00
Same thing, but for the "part" display
This commit is contained in:
parent
faf8e45138
commit
6c3b83c05b
1 changed files with 8 additions and 1 deletions
|
|
@ -86,7 +86,14 @@ class _PartDisplayState extends RefreshableState<PartDetailWidget> {
|
|||
|
||||
@override
|
||||
Future<void> request(BuildContext context) async {
|
||||
await part.reload();
|
||||
|
||||
final bool result = await part.reload();
|
||||
|
||||
if (!result || part.pk == -1) {
|
||||
// Part could not be loaded, for some reason
|
||||
Navigator.of(context).pop();
|
||||
}
|
||||
|
||||
await part.getTestTemplates();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue