2
0
mirror of https://github.com/inventree/inventree-app.git synced 2025-04-28 13:36:50 +00:00

Fix bug which prevented creation of stock item at top level location

This commit is contained in:
Oliver Walters 2022-04-02 11:29:45 +11:00
parent ad97fb0f92
commit e620cfa515

View File

@ -170,7 +170,7 @@ class _LocationDisplayState extends RefreshableState<LocationDisplayWidget> {
int pk = location?.pk ?? -1; int pk = location?.pk ?? -1;
if (pk <= 0) { if (location != null && pk <= 0) {
return; return;
} }
@ -178,7 +178,7 @@ class _LocationDisplayState extends RefreshableState<LocationDisplayWidget> {
context, context,
L10().stockItemCreate, L10().stockItemCreate,
data: { data: {
"location": pk, "location": location != null ? pk : null,
}, },
onSuccess: (result) async { onSuccess: (result) async {