mirror of
https://github.com/HendrikRauh/inventree-app.git
synced 2026-01-13 11:36:24 +00:00
Stock display (#379)
* Display stock quantity more prominently * Cleanup search widget * Update for stock_detail widget * More tweaks * Change bottom bar icon * Display boolean parameters appropriately * Adds ability to edit part parameters * Bump icon size a bit * Improvements to filter options - Allow filtering by "option" type - To start with, filter stock by status code * Remove debug message * Remove getTriState method - No longer needed - Remove associated unit tests * Adjust filters based on server API version * Muted colors
This commit is contained in:
parent
8076887e39
commit
e9eb84eace
20 changed files with 278 additions and 167 deletions
|
|
@ -23,6 +23,26 @@ class InvenTreeStatusCode {
|
|||
// Internal status code data loaded from server
|
||||
Map<String, dynamic> data = {};
|
||||
|
||||
/*
|
||||
* Construct a list of "choices" suitable for a form
|
||||
*/
|
||||
List<dynamic> get choices {
|
||||
List<dynamic> _choices = [];
|
||||
|
||||
for (String key in data.keys) {
|
||||
dynamic _entry = data[key];
|
||||
|
||||
if (_entry is Map<String, dynamic>) {
|
||||
_choices.add({
|
||||
"value": _entry["key"],
|
||||
"display_name": _entry["label"]
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
return _choices;
|
||||
}
|
||||
|
||||
// Load status code information from the server
|
||||
Future<void> load({bool forceReload = false}) async {
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue