• Home
  • Demo
  • Buy Now
RISE - Ultimate Project Manager & CRM
    RISE - Ultimate Project Manager & CRMInstallation & MaintenancePersonalizationSettingsClient ManagementAI AssistantInvoices & PaymentsProjects & TasksTeam & CollaborationProductivity ToolsSales & ServicesRISE ReportsPluginsFAQChange logs
Mailbox PluginLanding Page Builder PluginEasy Backup PluginSquare Payment Method PluginLogin as Client PluginAsset Management Plugin2 Factor Authentication PluginPassword Manager PluginSocial Login PluginGoogle Meet Integration PluginSpreadsheets PluginZoom Integration PluginAuto Attendance PluginWhiteboards PluginDocs PluginBlog Manager PluginWhatsApp Link PluginMicrosoft Teams Integration PluginProperty Management PluginTelegram Notification PluginAWS S3 Integration PluginWhatsApp Notification PluginWasabi Integration PluginBackblaze Integration PluginCloudflare R2 Integration PluginDigitalOcean Spaces Integration PluginAdyen Payment Method PluginbKash Payment Method Pluginiyzico Payment Method PluginJazzCash Payment Method PluginMercado Pago Payment Method PluginMidtrans Payment Method PluginMontonio Payment Method PluginN-Genius Payment Method PluginNagad Payment Method PluginPayFast Payment Method PluginPaysera Payment Method PluginPaystack Payment Method PluginPix Payment Method PluginRazorpay Payment Method PluginRocket Payment Method PluginSSLCommerz Payment Method Plugin
  1. Docs
  2. RISE - Ultimate Project Manager & CRM
  3. Plugins

Decide who can review store items from a plugin

By default, a client can review a store item after an order with that item is delivered. Your plugin can change this, for example to allow reviews only while the client's license is active.

The filter

Use the app_filter_store_item_review_permission filter. It runs when the review form is shown and when a review is saved or edited.

app_hooks()->add_filter('app_filter_store_item_review_permission', function ($permission, $context) {
    //$permission: array("allowed" => true or false, "message" => "...", "order_id" => ...)
    //$context: item_info, user, client_id, delivered_order_ids, review_info

    if ($permission["allowed"] && !my_plugin_has_active_license($context["client_id"], $context["item_info"]->id)) {
        return array("allowed" => false, "message" => "Your license has expired.");
    }

    return $permission;
}, 10, 2);

What you can return

  • allowed: true to show the review form and save the review, false to block it.
  • message: shown to the client when the review is blocked.
  • order_id: the order saved with the review. Keep the default unless the review belongs to another order.

You can also allow clients who have no delivered order, for example when they bought a license outside RISE. Only clients who can open the store can write reviews.

review_info is the client's existing review, or null for a new one. Use it if you want to allow editing an old review after the license ends.

Refunded items

An order item closed with the app_filter_store_order_item_delivery_available filter doesn't count as a delivered order. So after a refund, the client can't write a new review of that item.

To remove the review the client already wrote, call this after the refund:

\App\Libraries\Store_feedback::delete_review_of_order_item($order_item_id);

It deletes the client's review of the item. The review stays if the client has another delivered order of the same item. It returns the number of deleted reviews.

Was this article helpful? Yes No
How can we improve this article?
© 2026 Fairsketch
Home Get Support Buy Now

Delete?

Are you sure? You won't be able to undo this action!
To do