2
1
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2023-12-13 21:00:40 +01:00

Handling archived tiers for offer list

This commit is contained in:
Princi Vershwal 2023-11-07 18:02:45 +05:30 committed by GitHub
parent 1d8adc6e86
commit 13b9ba9627
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View file

@ -127,6 +127,10 @@ const OffersModal = () => {
{offers.filter(offer => offer.status === selectedTab).map((offer) => {
const offerTier = paidActiveTiers.find(tier => tier.id === offer?.tier.id);
if (!offerTier) {
return null;
}
return (
<OfferCard
key={offer?.id}

View file

@ -133,7 +133,7 @@ const TierDetailModalContent: React.FC<{tier?: Tier}> = ({tier}) => {
const promptTitle = tier.active ? 'Archive tier' : 'Reactivate tier';
const prompt = tier.active ? <>
<div className='mb-6'>Members will no longer be able to subscribe to <strong>{tier.name}</strong> and it will be removed from the list of available tiers in portal.</div>
<div>Existing members on this tier will remain unchanged.</div>
<div>Existing members on this tier will remain unchanged. Offers using this tier will be disabled.</div>
</> : <>
<div className='mb-6'>Reactivating <strong>{tier.name}</strong> will re-enable it as an option in portal and allow new members to subscribe to this tier.</div>
<div>Existing members will remain unchanged.</div>