Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Remove field `quantity_allocated` from StockInput

Mira Szewczykf6daa367c9b2
diff --git a/saleor/graphql/schema.graphql b/saleor/graphql/schema.graphql
index 1395573af9..5533af8e00 100644
--- a/saleor/graphql/schema.graphql
+++ b/saleor/graphql/schema.graphql
@@ -4210,7 +4210,6 @@ input StockInput {
productVariant: ID!
warehouse: ID!
quantity: Int
- quantityAllocated: Int
}
type StockUpdate {
diff --git a/saleor/graphql/warehouse/types.py b/saleor/graphql/warehouse/types.py
index 6fb154e0b9..023edd3b9c 100644
--- a/saleor/graphql/warehouse/types.py
+++ b/saleor/graphql/warehouse/types.py
@@ -63,7 +63,6 @@ class StockInput(graphene.InputObjectType):
required=True, description="Warehouse in which stock is lockated."
)
quantity = graphene.Int(description="Quantity of items available for sell.")
- quantity_allocated = graphene.Int(description="Quantity allocated for orders.")
class Stock(CountableDjangoObjectType):
diff --git a/tests/api/test_stock.py b/tests/api/test_stock.py
index 774ef582a6..4ad6c4ac5d 100644
--- a/tests/api/test_stock.py
+++ b/tests/api/test_stock.py
@@ -130,7 +130,6 @@ def test_stock_cannot_be_created_without_permission(
"warehouse": warehouse_id,
"productVariant": variant_id,
"quantity": 100,
- "quantityAllocated": 23,
}
}
@@ -151,7 +150,6 @@ def test_create_stock_mutation(
"productVariant": variant_id,
"warehouse": warehouse_id,
"quantity": 100,
- "quantityAllocated": 27,
}
}
response = staff_api_client.post_graphql(MUTATION_CREATE_STOCK, variables)