mirror of
https://github.com/inventree/inventree-app.git
synced 2025-04-28 13:36:50 +00:00
Don't display a location tile if the location is null
This commit is contained in:
parent
47929c888b
commit
39c0470b2a
@ -267,6 +267,7 @@ class InvenTreeStockItem extends InvenTreeModel {
|
||||
loc = jsondata['location_detail']['name'] ?? '';
|
||||
}
|
||||
|
||||
// Old-style name
|
||||
if (loc.isEmpty) {
|
||||
loc = jsondata['location__name'] ?? '';
|
||||
}
|
||||
|
@ -380,7 +380,7 @@ class _StockItemDisplayState extends RefreshableState<StockDetailWidget> {
|
||||
}
|
||||
|
||||
// Location information
|
||||
if (item.locationName.isNotEmpty) {
|
||||
if ((item.locationId > 0) && (item.locationName != null) && (item.locationName.isNotEmpty)) {
|
||||
tiles.add(
|
||||
ListTile(
|
||||
title: Text("Stock Location"),
|
||||
|
Loading…
x
Reference in New Issue
Block a user