mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
remove some deprecations
This commit is contained in:
parent
47c3be6217
commit
912f7d3211
@ -31,7 +31,7 @@ class PersistNotificationOnTerminateEventSubscriber implements EventSubscriberIn
|
||||
|
||||
public function onKernelTerminate(TerminateEvent $event): void
|
||||
{
|
||||
if ($event->isMasterRequest()) {
|
||||
if ($event->isMainRequest()) {
|
||||
$this->persistNotifications();
|
||||
}
|
||||
}
|
||||
|
@ -31,7 +31,7 @@
|
||||
{{ render(controller('Chill\\MainBundle\\Controller\\UIController::showNotificationUserCounterAction')) }}
|
||||
</b>
|
||||
|
||||
{% if is_granted('ROLE_PREVIOUS_ADMIN') %}
|
||||
{% if is_granted('IS_IMPERSONATOR') %}
|
||||
<i class="fa fa-wrench fa-lg" title="Impersonate mode"></i>
|
||||
{% endif %}
|
||||
|
||||
@ -39,7 +39,7 @@
|
||||
<div class="dropdown-menu dropdown-menu-end dropdown-menu-dark" aria-labelledby="menu-user">
|
||||
|
||||
{% for menu in menus %}
|
||||
{% if is_granted('ROLE_PREVIOUS_ADMIN') and menu.name == 'Logout' %}
|
||||
{% if is_granted('IS_IMPERSONATOR') and menu.name == 'Logout' %}
|
||||
<a class="dropdown-item list-group-item bg-dark text-white"
|
||||
href="{{ path('chill_crud_admin_user_index', {'_switch_user': '_exit'}) }}">
|
||||
{{ 'Exit impersonation'|trans }}
|
||||
|
@ -36,7 +36,7 @@ final class PersistNotificationOnTerminateEventSubscriberTest extends TestCase
|
||||
$em->persist(Argument::type(Notification::class))->shouldBeCalledTimes(1);
|
||||
$em->flush()->shouldBeCalledTimes(1);
|
||||
$event = $this->prophesize(TerminateEvent::class);
|
||||
$event->isMasterRequest()->willReturn(true);
|
||||
$event->isMainRequest()->willReturn(true);
|
||||
|
||||
$eventSubscriber = new PersistNotificationOnTerminateEventSubscriber($em->reveal(), $persister);
|
||||
|
||||
|
@ -112,7 +112,7 @@ final class PersonControllerUpdateTest extends WebTestCase
|
||||
/**
|
||||
* Test the edit page are accessible.
|
||||
*
|
||||
* @dataProvider providePerson *
|
||||
* @dataProvider providePerson
|
||||
*/
|
||||
public function testEditPageIsSuccessful(int $personId)
|
||||
{
|
||||
|
@ -50,7 +50,7 @@ final class RelationshipApiControllerTest extends WebTestCase
|
||||
->join('p.centerCurrent', 'center_current')
|
||||
->join('center_current.center', 'c')
|
||||
->where('c.name LIKE :name')
|
||||
->andWhere('EXISTS (SELECT 1 FROM ' . Relationship::class . ' r WHERE r.fromPerson = p OR r.toPerson = p)')
|
||||
->andWhere('EXISTS (SELECT 1 FROM '.Relationship::class.' r WHERE r.fromPerson = p OR r.toPerson = p)')
|
||||
->setParameter('name', 'Center A')
|
||||
->getQuery()
|
||||
->setMaxResults(1)
|
||||
@ -62,7 +62,7 @@ final class RelationshipApiControllerTest extends WebTestCase
|
||||
->join('p.centerCurrent', 'center_current')
|
||||
->join('center_current.center', 'c')
|
||||
->where('c.name LIKE :name')
|
||||
->andWhere('NOT EXISTS (SELECT 1 FROM ' . Relationship::class . ' r WHERE r.fromPerson = p OR r.toPerson = p)')
|
||||
->andWhere('NOT EXISTS (SELECT 1 FROM '.Relationship::class.' r WHERE r.fromPerson = p OR r.toPerson = p)')
|
||||
->setParameter('name', 'Center A')
|
||||
->getQuery()
|
||||
->setMaxResults(1)
|
||||
@ -85,7 +85,7 @@ final class RelationshipApiControllerTest extends WebTestCase
|
||||
->join('p.centerCurrent', 'center_current')
|
||||
->join('center_current.center', 'c')
|
||||
->where('c.name LIKE :name')
|
||||
->andWhere('NOT EXISTS (SELECT 1 FROM ' . Relationship::class . ' r WHERE r.fromPerson = p OR r.toPerson = p)')
|
||||
->andWhere('NOT EXISTS (SELECT 1 FROM '.Relationship::class.' r WHERE r.fromPerson = p OR r.toPerson = p)')
|
||||
->setParameter('name', 'Center A')
|
||||
->getQuery()
|
||||
->setMaxResults(2)
|
||||
|
@ -38,7 +38,9 @@ class AvgDurationAPWorkPersonAssociatedOnAccompanyingPeriodTest extends Abstract
|
||||
|
||||
public function getFormData()
|
||||
{
|
||||
return [];
|
||||
return [
|
||||
[],
|
||||
];
|
||||
}
|
||||
|
||||
public function getModifiersCombination()
|
||||
|
Loading…
x
Reference in New Issue
Block a user