mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-06 22:40:14 -05:00
Added tier type
in API response
refs https://github.com/TryGhost/Team/issues/1037 Tiers now have a `type` column to differentiate between `free` and `paid` tiers. This change allows `type` data for a tier in Admin and Portal API output.
This commit is contained in:
parent
e54395eab5
commit
345eb5828c
2 changed files with 2 additions and 0 deletions
|
@ -73,6 +73,7 @@ function serializeProduct(product, options, apiType) {
|
|||
name: json.name,
|
||||
description: json.description,
|
||||
slug: json.slug,
|
||||
type: json.type,
|
||||
created_at: json.created_at,
|
||||
updated_at: json.updated_at,
|
||||
stripe_prices: json.stripePrices ? json.stripePrices.map(price => serializeStripePrice(price, hideStripeData)) : null,
|
||||
|
|
|
@ -109,6 +109,7 @@ const getPortalProductPrices = async function () {
|
|||
monthlyPrice: product.monthlyPrice,
|
||||
yearlyPrice: product.yearlyPrice,
|
||||
benefits: product.benefits,
|
||||
type: product.type,
|
||||
prices: productPrices
|
||||
};
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue