Paywall Check
Some sites want to restrict access to content unless users have paid. The Paywall check is implemented at the Subscription level.
On the subscription there is a setting called “No access until paid”, if you check this the user will be only able to access to the “\pay” screen as long as:
- The user has a subscription
- The subscription has the value “No access until paid” = True.
- The invoice is not paid in full and the due date is now past (including equal to today) (if you set the Grace period_ days on the Subscription term payment to 0 the invoice is due as soon as it is created). You can set different due dates for different subscription types.
- The user does not have Staff or Administrator Roles (as we cannot prevent staff from being able to perform their duties if they have not paid their dues and most likely staff members were testing the subscription process, so we do not want to lock them out either.
Note: The paywall is not able to be tested when impersonating users either, as this setting is checked on Login (not on impersonation). This may change in future versions.
Trial access, then paywall.
By using this same method, but setting the Grace period_ days to 30 the due date for this invoice would be 30 days from the start of the subscription, which you could use to allow user a trial of a subscription and once the due date is reached users are required to pay to continue access.
Only 1 paywall needs to be found for a user in order to block the user from anything but the /pay screen.
If a user has a paid membership but adds a 2nd subscription, if you enforce a paywall on that subscription they / the user will be locked out of the entire system until the 2nd subscription is paid for. So test your common scenarios well.