feat: free edit and publish/unpublish toggle for paid listings within 30-day period

This commit is contained in:
2026-02-08 10:07:47 +01:00
parent c66b77dbf8
commit e7c73f85b9
12 changed files with 152 additions and 24 deletions

View File

@@ -422,6 +422,8 @@ class DirectusService {
'shipping',
'shipping_cost',
'views',
'paid_at',
'payment_status',
'expires_at',
'date_created',
'user_created',

View File

@@ -69,6 +69,12 @@ class ListingsService {
search: filters.search
})
}
isPaidAndActive(listing) {
return listing.paid_at
&& listing.expires_at
&& new Date(listing.expires_at) > new Date()
}
}
export const listingsService = new ListingsService()