Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
CiviCRM Core
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container registry
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Development
CiviCRM Core
Commits
6ebc8f48
Unverified
Commit
6ebc8f48
authored
4 years ago
by
colemanw
Committed by
GitHub
4 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #19789 from eileenmcnaughton/permc
[REF] getCorePermissions cleanup
parents
b6873cd1
ce6b4d9b
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CRM/Core/Permission.php
+9
-6
9 additions, 6 deletions
CRM/Core/Permission.php
distmaker/utils/joomlaxml.php
+1
-1
1 addition, 1 deletion
distmaker/utils/joomlaxml.php
with
10 additions
and
7 deletions
CRM/Core/Permission.php
+
9
−
6
View file @
6ebc8f48
...
...
@@ -588,12 +588,7 @@ class CRM_Core_Permission {
*/
public
static
function
assembleBasicPermissions
(
$all
=
FALSE
,
$descriptions
=
FALSE
)
{
$config
=
CRM_Core_Config
::
singleton
();
$prefix
=
ts
(
'CiviCRM'
)
.
': '
;
$permissions
=
self
::
getCorePermissions
(
$descriptions
);
if
(
self
::
isMultisiteEnabled
())
{
$permissions
[
'administer Multiple Organizations'
]
=
[
$prefix
.
ts
(
'administer Multiple Organizations'
)];
}
$permissions
=
self
::
getCorePermissions
();
if
(
!
$descriptions
)
{
foreach
(
$permissions
as
$name
=>
$attr
)
{
...
...
@@ -909,6 +904,14 @@ class CRM_Core_Permission {
'description'
=>
ts
(
'Permit altering all restricted data options'
),
],
];
if
(
self
::
isMultisiteEnabled
())
{
// This could arguably be moved to the multisite extension but
// within core it does permit editing group-organization records.
$permissions
[
'administer Multiple Organizations'
]
=
[
'label'
=>
$prefix
.
ts
(
'administer Multiple Organizations'
),
'description'
=>
ts
(
'Administer multiple organizations. In practice this allows editing the group organization link'
),
];
}
foreach
(
self
::
getImpliedPermissions
()
as
$name
=>
$includes
)
{
foreach
(
$includes
as
$permission
)
{
$permissions
[
$name
][]
=
$permissions
[
$permission
];
...
...
This diff is collapsed.
Click to expand it.
distmaker/utils/joomlaxml.php
+
1
−
1
View file @
6ebc8f48
...
...
@@ -61,7 +61,7 @@ function generateJoomlaConfig($version) {
require_once
'CRM/Core/Permission.php'
;
require_once
'CRM/Utils/String.php'
;
require_once
'CRM/Core/I18n.php'
;
$permissions
=
CRM_Core_Permission
::
getCorePermissions
(
TRUE
);
$permissions
=
CRM_Core_Permission
::
getCorePermissions
();
$crmFolderDir
=
$sourceCheckoutDir
.
DIRECTORY_SEPARATOR
.
'CRM'
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment