Open
Description
As a visitor I want to see prices in my cart with the proper tax formatting so that I can accurately view my prices.
AC
Discount
should includeprice_incl_tax
andprice_excl_tax
and amount should probably be deprecated?SelectedShippingMethod
should includeprice_incl_tax
andprice_excl_tax
andamount
should probably be deprecated?
CartItemPrices
should includeprice_incl_tax
SelectedShippingMethod
should provide including and excluding tax pricesStoreConfig
should communicate how to render the cart
Suggested Schema
SelectedShippingMethod
should include price_incl_tax
and price_excl_tax
and amount
should probably be deprecated?
magento2/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
Lines 356 to 359 in 8de016a
Should be:
type Discount @doc(description:"Defines an individual discount. A discount can be applied to the cart as a whole or to an item.") {
amount: Money! @doc(description:"The amount of the discount.") @deprecated(reason: "use price_incl_tax and price_excl_tax")
price_incl_tax: Money! @doc(description:"The amount of the discount including tax.")
price_excl_tax: Money! @doc(description:"The amount of the discount excluding tax.")
label: String! @doc(description:"A description of the discount.")
}
Should be:
type CartItemPrices @doc(description: "Contains details about the price of the item, including taxes and discounts.") {
#other stuff
total_item_discount: Money @doc(description: "The total of all discounts applied to the item.") @deprecated(reason: "use total_item_discount_incl_tax or total_item_discount_excl_tax")
total_item_discount_incl_tax: Money @doc(description: "The total of all discounts applied to the item.")
total_item_discount_excl_tax: Money @doc(description: "The total of all discounts applied to the item.")
}
CartItemPrices
should include price_incl_tax
type CartItemPrices @doc(description: "Contains details about the price of the item, including taxes and discounts.") {
price: Money! @doc(description: "The price of the item before any discounts were applied. The price that might include tax, depending on the configured display settings for cart.") @deprecated(reason: "use price_excl_tax or price_incl_tax instead")
price_excluding_tax: Money! @doc(description: "The price of the item before any discounts were applied.")
price_including_tax: Money! @doc(description: "The price of the item before any discounts were applied.")
# other stuff
}
SelectedShippingMethod
should provide including and excluding tax prices
magento2/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
Lines 263 to 270 in 8de016a
Should be:
type SelectedShippingMethod @doc(description: "Contains details about the selected shipping method and carrier.") {
carrier_code: String! @doc(description: "A string that identifies a commercial carrier or an offline shipping method.")
method_code: String! @doc(description: "A shipping method code associated with a carrier.")
carrier_title: String! @doc(description: "The label for the carrier code.")
method_title: String! @doc(description: "The label for the method code.")
amount: Money! @doc(description: "The cost of shipping using this shipping method.") @deprecated(reason "use price_incl_tax or price_excl_tax")
price_incl_tax: Money!
price_excl_tax: Money!
base_amount: Money @deprecated(reason: "The field should not be used on the storefront.")
}
StoreConfig
should communicate how to render the cart
enum CartTaxDisplayOptions {
INCL
EXCL
BOTH
}
type StoreConfig {
cart_display_prices: CartTaxDisplayOptions!
cart_display_shipping_prices: CartTaxDisplayOptions!
cart_display_subtotal: CartTaxDisplayOptions!
cart_display_grandtotal: CartTaxDisplayOptions! #This will
cart_display_tax_summary: Boolean!
cart_display_tax_when_zero: Boolean!
}
This will incorporate these settings:
(there are many more missing store config values, i can write them down, improve on them, etc. but one step at a time 😄 )
Related
Metadata
Metadata
Assignees
Type
Projects
Status
Ready for Grooming