mirror of
				https://github.com/inventree/InvenTree.git
				synced 2025-10-30 20:55:42 +00:00 
			
		
		
		
	[UI] Refactor stock adjustment actions (#9937)
* Refactor stock actions into a hook * Cleanup hooks * Allow transfer of "incomplete" outputs * Simplify even further * Enable transfer of stock allocated to build order * Remove StockItemBriefSerializer entirely * stock actions for items allocated to sales order * Refactor <PartDetail> page * Refactor <StockDetail> * Refactor <LocationDetail> * Bump API version * Control serializer arguments
This commit is contained in:
		| @@ -1228,7 +1228,14 @@ class BuildItemSerializer(DataImportExportSerializerMixin, InvenTreeModelSeriali | ||||
|     ) | ||||
|  | ||||
|     stock_item_detail = StockItemSerializer( | ||||
|         source='stock_item', read_only=True, allow_null=True, label=_('Stock Item') | ||||
|         source='stock_item', | ||||
|         read_only=True, | ||||
|         allow_null=True, | ||||
|         label=_('Stock Item'), | ||||
|         part_detail=False, | ||||
|         location_detail=False, | ||||
|         supplier_part_detail=False, | ||||
|         path_detail=False, | ||||
|     ) | ||||
|  | ||||
|     location = serializers.PrimaryKeyRelatedField( | ||||
|   | ||||
| @@ -1431,7 +1431,13 @@ class SalesOrderAllocationSerializer(InvenTreeModelSerializer): | ||||
|         source='item.part', many=False, read_only=True, allow_null=True | ||||
|     ) | ||||
|     item_detail = stock.serializers.StockItemSerializer( | ||||
|         source='item', many=False, read_only=True, allow_null=True | ||||
|         source='item', | ||||
|         many=False, | ||||
|         read_only=True, | ||||
|         allow_null=True, | ||||
|         part_detail=False, | ||||
|         location_detail=False, | ||||
|         supplier_part_detail=False, | ||||
|     ) | ||||
|     location_detail = stock.serializers.LocationBriefSerializer( | ||||
|         source='item.location', many=False, read_only=True, allow_null=True | ||||
|   | ||||
		Reference in New Issue
	
	Block a user