saleor-dashboard/src/fragments/warehouses.ts

36 lines
699 B
TypeScript
Raw Normal View History

import gql from "graphql-tag";
import { fragmentAddress } from "./address";
export const warehouseFragment = gql`
fragment WarehouseFragment on Warehouse {
id
name
}
`;
export const warehouseWithShippingFragment = gql`
${warehouseFragment}
fragment WarehouseWithShippingFragment on Warehouse {
...WarehouseFragment
shippingZones(first: 100) {
edges {
node {
id
name
}
}
}
}
`;
export const warehouseDetailsFragment = gql`
${fragmentAddress}
${warehouseWithShippingFragment}
fragment WarehouseDetailsFragment on Warehouse {
...WarehouseWithShippingFragment
address {
...AddressFragment
}
}
`;