I have some account type call Standard, ID Certified, VIP, Premium and Admin. Then I have 9 User roles. Such as (Default) Free, Good, Better, Best, RealID, VIP, Primium and Max. I made default User roles on Standard account type is Free. and ID Certified account type is RealID.
Hello Kelvin,
Sorry it took a while to respond.
We've have checked your report with the Oxwall Video plugin. Here is what we've done:
- created two roles: Free and Paid;
- created two account types: Standard and Good;
- unchecked the Add Video option for both Free and Paid roles;
- set the 20 credits for the Add Video service for both Standard and Good account types;
- logged in under regular user's account: Paid role, Good account type;
- went to the Video page and could see the Add New button.
Please check it once again with the standard Oxwall Video plugin. If this does not work with the standard video plugin, please provide us with the screenshots of settings for account types, roles and user credits plugin. If it does not work with the third-party plugins - you need to contact these plugins developers and ask them to check into this issue. Most probably their plugins work incorrectly with the User Credits plugin.
I've asked you to check this functionality with the standard Oxwall Video plugin, because we 100% sure that they are using the methods and events provided by our plugin correctly. In the Video plugin there is a condition in the ow_plugins/video/controllers/video.php file:
// check auth
$showAddButton = true;
$status = BOL_AuthorizationService::getInstance()->getActionStatus('video', 'add');
if ( $status['status'] == BOL_AuthorizationService::STATUS_AVAILABLE )
{
$script = '$("#btn-add-new-video").click(function(){
document.location.href = ' . json_encode(OW::getRouter()->urlFor('VIDEO_CTRL_Add', 'index')) . ';
});';
OW::getDocument()->addOnloadScript($script);
}
else if ( $status['status'] == BOL_AuthorizationService::STATUS_PROMOTED )
{
$script = '$("#btn-add-new-video").click(function(){
OW.authorizationLimitedFloatbox('.json_encode($status['msg']).');
});';
OW::getDocument()->addOnloadScript($script);
}
else
{
$showAddButton = false;
}
$this->assign('showAddButton', $showAddButton);
This condition allows system to check if the Add New button should be visible or not. This condition in the Video plugin functionality, but not in our plugin.
If the third-party plugins use our conditions incorrectly, they will not behave the correct way as it does the Video plugin.
Anyway, as we can see the VideoPlus and Video Upload are not compatible with the Oxwall 1.7.2 - this also can result the issue. So, you should contact these plugins developers and ask them to check into this issue.
I hope my explanation is clear enough. If not, please don't hesitate to get back to me for clarifications or additional instructions.
Kelvin, we have already sorted it out through PM - the problem is not in the User Credits plugin. You shouldn't re-install it. The problem is caused by the VideoPlus and Video Upload plugins. These plugins do not work with the User Credits plugin correctly. You should contact these plugins developers and ask them to solve the problem, by applying the code I've provided above.
This function was added in 1.7.1 version of Oxwall software or even in 1.7.0 and if they want their plugins to work with our plugin correctly - they should implement this functionality.