Skip to content

Commit

Permalink
Merge branch hotfix/v2.3.29
Browse files Browse the repository at this point in the history
  • Loading branch information
roadiz-ci committed Oct 11, 2024
1 parent 66059b3 commit b215805
Show file tree
Hide file tree
Showing 71 changed files with 755 additions and 636 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/run-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
php-version: ['8.0', '8.1']
php-version: ['8.1', '8.2', '8.3']
steps:
- uses: shivammathur/setup-php@v2
with:
Expand Down
16 changes: 0 additions & 16 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright © 2023 Ambroise Maupate, Julien Blanchet
Copyright © 2024 Ambroise Maupate, Julien Blanchet

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ security:
custom_authenticator:
- RZ\Roadiz\RozierBundle\Security\RozierAuthenticator
access_control:
- { path: ^/rz-admin/login, roles: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: ^/rz-admin/login, roles: PUBLIC_ACCESS }
- { path: ^/rz-admin, roles: ROLE_BACKEND_USER }
```
- Add custom routes:
Expand All @@ -106,6 +106,8 @@ roadiz_rozier:
open_id:
# Verify User info in JWT at each login
verify_user_info: false
# Force generating redirect uri with https scheme. (required by some OpenID providers)
force_ssl_on_redirect_uri: true
# Standard OpenID autodiscovery URL, required to enable OpenId login in Roadiz CMS.
discovery_url: '%env(string:OPEN_ID_DISCOVERY_URL)%'
# For public identity providers (such as Google), restrict users emails by their domain.
Expand Down
19 changes: 11 additions & 8 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"keywords": [
"cms",
"backoffice",
"roadiz",
"rezo zero"
],
"authors": [
Expand All @@ -15,13 +16,15 @@
}
],
"type": "symfony-bundle",
"minimum-stability": "dev",
"prefer-stable": true,
"require": {
"php": ">=8.0",
"symfony/framework-bundle": "5.4.*",
"roadiz/core-bundle": "2.1.*",
"roadiz/rozier": "2.1.*",
"roadiz/compat-bundle": "2.1.*",
"roadiz/openid": "2.1.*"
"php": ">=8.1",
"symfony/framework-bundle": "6.4.*",
"roadiz/core-bundle": "2.3.*",
"roadiz/rozier": "2.3.*",
"roadiz/compat-bundle": "2.3.*",
"roadiz/openid": "2.3.*"
},
"require-dev": {
"php-coveralls/php-coveralls": "^2.4",
Expand Down Expand Up @@ -52,8 +55,8 @@
},
"extra": {
"branch-alias": {
"dev-main": "2.1.x-dev",
"dev-develop": "2.2.x-dev"
"dev-main": "2.3.x-dev",
"dev-develop": "2.4.x-dev"
}
}
}
6 changes: 6 additions & 0 deletions config/packages/roadiz_rozier.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
---
parameters:
env(OPEN_ID_DISCOVERY_URL): ''
env(OPEN_ID_HOSTED_DOMAIN): ''
env(OPEN_ID_CLIENT_ID): ''
env(OPEN_ID_CLIENT_SECRET): ''
roadiz_rozier:
theme_dir: '%kernel.project_dir%/vendor/roadiz/rozier/src'
open_id:
Expand All @@ -13,6 +18,7 @@ roadiz_rozier:
# OpenID identity provider OAuth2 client secret
oauth_client_secret: '%env(string:OPEN_ID_CLIENT_SECRET)%'
requires_local_user: false
force_ssl_on_redirect_uri: true
# Only when local users are not required, creating virtual users
# with following roles.
granted_roles:
Expand Down
6 changes: 1 addition & 5 deletions config/routing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ tagsRoutes:
# USERS
usersHomePage:
path: /rz-admin/users
controller: Themes\Rozier\Controllers\Users\UsersController::indexAction
controller: Themes\Rozier\Controllers\Users\UsersController::defaultAction
usersRoutes:
resource: "routing/users.yml"
prefix: /rz-admin/users
Expand Down Expand Up @@ -214,10 +214,6 @@ webhooksRoutes:
# CSS to style with main color
# NOT SECURED ROUTES
#
cssMainColor:
path : /css/main-color.css
controller: Themes\Rozier\RozierApp::cssAction

loginImagePage:
path: /css/login/image
controller: Themes\Rozier\Controllers\LoginController::imageAction
Expand Down
5 changes: 5 additions & 0 deletions config/routing/attributes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ attributesDeletePage:
_controller: Themes\Rozier\Controllers\Attributes\AttributeController::deleteAction
requirements: { id : "[0-9]+" }

attributesBulkDeletePage:
methods: [GET, POST]
path: /bulk-delete
defaults:
_controller: Themes\Rozier\Controllers\Attributes\AttributeController::bulkDeleteAction

attributeGroupsHomePage:
path: /groups
Expand Down
5 changes: 5 additions & 0 deletions config/routing/custom-forms.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,8 @@ customFormsDuplicatePage:
requirements: { id : "[0-9]+" }
defaults:
_controller: Themes\Rozier\Controllers\CustomForms\CustomFormsUtilsController::duplicateAction
customFormsBulkDeletePage:
methods: [GET, POST]
path: /bulk-delete
defaults:
_controller: Themes\Rozier\Controllers\CustomForms\CustomFormsController::bulkDeleteAction
5 changes: 5 additions & 0 deletions config/routing/documents.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ documentsDownloadPage:
defaults:
_controller: Themes\Rozier\Controllers\Documents\DocumentsController::downloadAction
requirements: { documentId : "[0-9]+" }
documentsDownloadInlinePage:
path: /download-inline/{documentId}
defaults:
_controller: Themes\Rozier\Controllers\Documents\DocumentsController::downloadInlineAction
requirements: { documentId : "[0-9]+" }
documentsUsagePage:
path: /usage/{documentId}
defaults:
Expand Down
8 changes: 8 additions & 0 deletions config/routing/nodes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,14 @@ nodesTreePage:
requirements:
nodeId : "[0-9]+"
translationId : "[0-9]+"
nodesMainTreePage:
path: /tree/main/{translationId}
defaults:
_controller: Themes\Rozier\Controllers\Nodes\NodesTreesController::treeAction
nodeId : null
translationId : null
requirements:
translationId : "[0-9]+"
nodesBulkDeletePage:
path: /bulk-delete
defaults:
Expand Down
5 changes: 5 additions & 0 deletions config/routing/redirections.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,8 @@ redirectionsDeletePage:
defaults:
_controller: Themes\Rozier\Controllers\RedirectionsController::deleteAction
requirements: { id : "[0-9]+" }
redirectionsBulkDeletePage:
methods: [GET, POST]
path: /bulk-delete
defaults:
_controller: Themes\Rozier\Controllers\RedirectionsController::bulkDeleteAction
29 changes: 22 additions & 7 deletions config/routing/users.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,28 @@
usersEditPage:
path: /edit/{userId}
path: /edit/{id}
defaults:
_controller: Themes\Rozier\Controllers\Users\UsersController::editAction
requirements: { userId : "[0-9]+" }
requirements: { id : "[0-9]+" }
usersBulkDeletePage:
methods: [GET, POST]
path: /bulk-delete
defaults:
_controller: Themes\Rozier\Controllers\Users\UsersController::bulkDeleteAction
usersBulkEnablePage:
methods: [GET, POST]
path: /bulk-enable
defaults:
_controller: Themes\Rozier\Controllers\Users\UsersController::bulkEnableAction
usersBulkDisablePage:
methods: [GET, POST]
path: /bulk-disable
defaults:
_controller: Themes\Rozier\Controllers\Users\UsersController::bulkDisableAction
usersEditDetailsPage:
path: /edit/{userId}/details
path: /edit/{id}/details
defaults:
_controller: Themes\Rozier\Controllers\Users\UsersController::editDetailsAction
requirements: { userId : "[0-9]+" }
requirements: { id : "[0-9]+" }
usersEditRolesPage:
path: /edit/{userId}/roles
defaults:
Expand All @@ -31,13 +46,13 @@ usersRemoveGroupsPage:
usersAddPage:
path: /add
defaults:
_type: Themes\Rozier\Forms\AddUserType
_controller: Themes\Rozier\Controllers\Users\UsersController::addAction
usersDeletePage:
path: /delete/{userId}
path: /delete/{id}
defaults:
_controller: Themes\Rozier\Controllers\Users\UsersController::deleteAction
requirements: { userId : "[0-9]+" }

requirements: { id : "[0-9]+" }
usersSecurityPage:
path: /edit/{userId}/security
defaults:
Expand Down
5 changes: 5 additions & 0 deletions config/routing/webhooks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,8 @@ webhooksDeletePage:
defaults:
_controller: Themes\Rozier\Controllers\WebhookController::deleteAction
requirements: { id : "[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}" }
webhooksBulkDeletePage:
methods: [GET, POST]
path: /bulk-delete
defaults:
_controller: Themes\Rozier\Controllers\WebhookController::bulkDeleteAction
5 changes: 5 additions & 0 deletions config/services.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ services:
$addNodeFormTypeClass: '%roadiz_rozier.add_node_form.class%'
$googleServerId: '%roadiz_core.medias.google_server_id%'
$soundcloudClientId: '%roadiz_core.medias.soundcloud_client_id%'
$allowNodeTypeEdition: '%kernel.debug%'
$forceSslOnRedirectUri: '%roadiz_rozier.open_id.force_ssl_on_redirect_uri%'
$useGravatar: '%roadiz_core.use_gravatar%'

RZ\Roadiz\RozierBundle\:
resource: '../src/'
Expand Down Expand Up @@ -72,6 +75,8 @@ services:
calls:
- prependPath: [ '%roadiz_core.documents_lib_dir%/Resources/views' ]
- addPath: [ '%roadiz_rozier.theme_dir%/Resources/views', 'RoadizRozier' ]
# Add a second path to make RoadizRozier templates extendable with @!RoadizRozier namespace
- addPath: [ '%roadiz_rozier.theme_dir%/Resources/views', '!RoadizRozier' ]
tags: [ 'twig.loader' ]

#
Expand Down
8 changes: 5 additions & 3 deletions phpstan.neon
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
parameters:
level: 6
level: 7
paths:
- src
doctrine:
Expand All @@ -9,6 +9,8 @@ parameters:
- */bower_components/*
- */static/*
ignoreErrors:
- identifier: missingType.iterableValue
- identifier: missingType.generics
- '#Call to an undefined method RZ\\Roadiz\\CoreBundle\\Repository#'
- '#Call to an undefined method RZ\\Roadiz\\UserBundle\\Repository#'
- '#Call to an undefined method Doctrine\\Persistence\\ObjectRepository#'
Expand All @@ -28,10 +30,10 @@ parameters:
- '#Doctrine\\ORM\\Mapping\\GeneratedValue constructor expects#'
- '#type mapping mismatch: property can contain Doctrine\\Common\\Collections\\Collection<int, [^\>]+> but database expects Doctrine\\Common\\Collections\\Collection&iterable<[^\>]+>#'
- '#should return Doctrine\\Common\\Collections\\Collection<int, [^\>]+Interface> but returns Doctrine\\Common\\Collections\\Collection<int, [^\>]+>#'
- '#but returns Doctrine\\Common\\Collections\\ReadableCollection<int, [^\>]+>#'
- '#does not accept Doctrine\\Common\\Collections\\ReadableCollection<int, [^\>]+>#'

reportUnmatchedIgnoredErrors: false
checkGenericClassInNonGenericObjectType: false
checkMissingIterableValueType: false
includes:
- vendor/phpstan/phpstan-doctrine/extension.neon
- vendor/phpstan/phpstan-doctrine/rules.neon
7 changes: 1 addition & 6 deletions src/Aliases.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@ final class Aliases
*/
public static function getAliases(): array
{
return [
\RZ\Roadiz\RozierBundle\Controller\BackendController::class => \RZ\Roadiz\CMS\Controllers\BackendController::class,
\RZ\Roadiz\RozierBundle\Form\DocumentTranslationType::class => \Themes\Rozier\Forms\DocumentTranslationType::class,
\RZ\Roadiz\RozierBundle\Form\CustomFormType::class => \Themes\Rozier\Forms\CustomFormType::class,
\RZ\Roadiz\RozierBundle\ListManager\SessionListFilters::class => \Themes\Rozier\Utils\SessionListFilters::class,
];
return [];
}
}
63 changes: 0 additions & 63 deletions src/Controller/BackendController.php

This file was deleted.

Loading

0 comments on commit b215805

Please sign in to comment.