@Michal
I'm trying to implement this by adding the following in osclas_pay/functions.php:
// FLASH MESSAGE FOR ORDERS THAT NEED PROCESSING
function osp_new_orders_notification() {
if(osc_is_web_user_logged_in()) {
$sellers = array_filter(explode(',', osp_param('seller_users')));
$is_seller = false;
if(in_array(osc_logged_user_id(), $sellers) || osp_param('seller_all') == 1) {
$is_seller = true;
}
if($is_seller && osp_param('enable_user_management') == 1) {
$params = Params::getParamsAsArray();
$order_items = isset($order['order_items']) ? $order['order_items'] : 0;
if( (isset($order_items['i_status']) == OSP_ORDER_PROCESSING) > 0 ) {
osc_add_flash_warning_message(__('You have orders that need processing. <a href="' . osc_route_url('osp-manager') . '">Click here</a> to fulfill them.', 'osclass_pay'));
}
}
}
}
osc_add_hook('header', 'osp_new_orders_notification');
However, the flash message always appears, for all users.
The idea is to have it appear only for sellers that have orders with the status Processing.
Any feedback?
Thanks!