-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some fixes for multiple content assign to single user #10
base: release-1.1.0
Are you sure you want to change the base?
Conversation
src/administrator/includes/rbacl.php
Outdated
* | ||
* @since 1.6 | ||
*/ | ||
public function getAuthorizedActions($agencyId = null, $userId = null, $roleId = null) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are there hardcoded references to com_multiagency ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed the variable name.
if (!empty($userRoleId)) | ||
{ | ||
$db = JFactory::getDBO(); | ||
$subInQuery = $db->getQuery(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sanjivani1812 Move the DB operations in the model
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@thite-amol - getRoleByUser function having DB operation so I put there. Can please suggest a model name.
In this file, I have added array_intersect in check function, because when multiple client_id assign to a single user then only first client_id check. need to check all roles across the system.
In this file two changes needed
2.a) In getTable table add table file
2.b) In getAssociatedContentRole function contentId variable make optional and changed query result to get all role column result.