The WordPress Posts & WooCommerce Products Restrict Access / Scheduler (WPPS) plugin is a powerful tool by which the Site admin can schedule or restrict access of posts, custom posts (like wordpress pages, bbpress posts or any other 3rd party custom posts ) and product visibility by “date rules” and for user roles. WooCommerce products can also be setted as “Unpurchasable” (visible but cannot be added to cart).
HOW IT WORKS
It’s very easy, once installed and activated, the site admin will find a new “Scheduler” menu voice on the main menu by which he can access to the Scheduling rules configurator. By this menu, the shop admin can set up scheduling rules to automatically publish/unpublish post, custom post (like wordpress pages, bbpress posts or any other 3rd party custom posts) and products. He can also simply restrict access to contets by user roles. In case you are restricting posts/pages by user role, you can also choose to redirect to a page.
NOTE:\ To restrict access to not logged users you have just to select at least one role in the user role selection section.
SET PRODUCT AS UNPURCHASABLE
Feature not compatible with Measurement Price Calculator Shop admin, for WooCommerce products, can use the special Unpurchasable option. Enabling this and setting visibility https to Visible the selected product will be visible but cannot be added to the cart by the customers (or the ones belonging to the roles chosen on the roles restriction option area) due to the “add to cart” button removal. After and before the Unpurchasable period the shop admin can choose if the product has to be set as Purchasable or Unpublished.
During the Unpurchasable period can be also optionally displayed two different messages on product and shop pages.
Note: Make sure that the theme you are using is correctly using the woocommerce_after_single_product, woocommerce_loop_add_to_cart_link and woocommerce_single_product_summary actions in the shop and single product page (as the woocommerce reference templates do) otherwise the plugin cannot hook properly to the theme to remove the add to cart button. All well-designed theme correctly use these actions.
Note: In case the WooCommerce Availability Scheduler plugin is active, the unpurchasable feature won’t work.
SCHEDULING/RESTRICT ACCESS RULES
The site admin can assign to a set of posts/products (directly selecting them or a set of categories) multiple scheduling rule. Each scheduling rule has the following option:
- Rule name/id
- Item type (WordPress post or WooCommerce product)
- Item(s) selection
- Category(es) selection
- Assignment strategy (the rule can be assigned to the selected items/categories or to all items except the ones selected)
- “Children” categories (if a category was selected, that rule can be assigned also to its children)
- Scheduling dates (for every scheduled time period is also possible to restrict visibility by user roles)
For each scheduling rule, the site admin can create different scheduling dates (configuring day(s), month(s), hour, …) for each of which different httpses (published or unpublished) can be assigned. Here two examples of what can be done: