2
0
mirror of https://github.com/inventree/inventree-app.git synced 2025-04-28 05:26:47 +00:00

Display "batch code" for stock item

This commit is contained in:
Oliver Walters 2021-08-10 00:10:20 +10:00
parent 2d005ba86b
commit baa3d3a1bb
4 changed files with 14 additions and 2 deletions

2
.gitmodules vendored
View File

@ -1,3 +1,3 @@
[submodule "lib/l10n"]
path = lib/l10n
url = https://github.com/inventree/inventree-app-i18n
url = git@github.com:SchrodingersGat/inventreeapp.git

View File

@ -220,6 +220,8 @@ class InvenTreeStockItem extends InvenTreeModel {
int get status => jsondata['status'] ?? -1;
String get batch => jsondata["batch"] ?? "";
int get partId => jsondata['part'] ?? -1;
String get purchasePrice => jsondata['purchase_price'] ?? "";

@ -1 +1 @@
Subproject commit c19a9d9af449f6a36df780c69cf1bd2bb087c252
Subproject commit 1e1e4f9b2494121098d2862f65e995ef8e420b8b

View File

@ -458,6 +458,16 @@ class _StockItemDisplayState extends RefreshableState<StockDetailWidget> {
);
}
if (item.batch.isNotEmpty) {
tiles.add(
ListTile(
title: Text(L10().batchCode),
subtitle: Text(item.batch),
leading: FaIcon(FontAwesomeIcons.layerGroup),
)
);
}
// Last update?
var update_date = item.updatedDateString;