2
0
mirror of https://github.com/inventree/InvenTree.git synced 2026-04-15 07:48:51 +00:00

Display more output information in "build allocated stock" table (#11276)

* Add "install_into_detail" to BuildItem serializer

* Enhance the "resolveItem" function

* Add "StockColumn" renderer

* Fix output column for BuildAllocatedStockTable

* Replace column in stock item table

* More column refactoring

* Bump API version

* Add InvenTreeOutputOption descriptions

* Prefetch for better API performance

* Updated playwright testing
This commit is contained in:
Oliver
2026-02-11 23:25:56 +11:00
committed by GitHub
parent e963b8219b
commit 3ebf27df36
11 changed files with 282 additions and 235 deletions

View File

@@ -29,6 +29,11 @@ export function isTrue(value: any): boolean {
* Allows for retrieval of nested items in an object.
*/
export function resolveItem(obj: any, path: string): any {
// Return the top-level object if no path is provided
if (path == null || path === '') {
return obj;
}
const properties = path.split('.');
return properties.reduce((prev, curr) => prev?.[curr], obj);
}