mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
rector and cs-fixer
This commit is contained in:
parent
83c3621c26
commit
3e39c0ced7
7
.changes/unreleased/Feature-20231114-143558.yaml
Normal file
7
.changes/unreleased/Feature-20231114-143558.yaml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
kind: Feature
|
||||||
|
body: |+
|
||||||
|
Add 3 new filters and 3 new aggregators for work action creator (with jobs and scopes)
|
||||||
|
|
||||||
|
time: 2023-11-14T14:35:58.099418749+01:00
|
||||||
|
custom:
|
||||||
|
Issue: "204"
|
@ -673,8 +673,8 @@ final class ActivityController extends AbstractController
|
|||||||
throw $this->createNotFoundException('Accompanying Period not found');
|
throw $this->createNotFoundException('Accompanying Period not found');
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO Add permission
|
// TODO Add permission
|
||||||
// $this->denyAccessUnlessGranted('CHILL_PERSON_SEE', $person);
|
// $this->denyAccessUnlessGranted('CHILL_PERSON_SEE', $person);
|
||||||
} else {
|
} else {
|
||||||
throw $this->createNotFoundException('Person or Accompanying Period not found');
|
throw $this->createNotFoundException('Person or Accompanying Period not found');
|
||||||
}
|
}
|
||||||
|
@ -23,8 +23,8 @@ class CreatorAggregator implements AggregatorInterface
|
|||||||
private const PREFIX = 'acpw_aggr_creator';
|
private const PREFIX = 'acpw_aggr_creator';
|
||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private UserRepository $userRepository,
|
private readonly UserRepository $userRepository,
|
||||||
private UserRender $userRender
|
private readonly UserRender $userRender
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
@ -58,7 +58,7 @@ class CreatorAggregator implements AggregatorInterface
|
|||||||
return function ($value): string {
|
return function ($value): string {
|
||||||
if ('_header' === $value) {
|
if ('_header' === $value) {
|
||||||
return 'export.aggregator.course_work.by_creator.Creator';
|
return 'export.aggregator.course_work.by_creator.Creator';
|
||||||
};
|
}
|
||||||
|
|
||||||
if (null === $value || '' === $value) {
|
if (null === $value || '' === $value) {
|
||||||
return '';
|
return '';
|
||||||
|
@ -44,12 +44,12 @@ class CreatorJobAggregator implements AggregatorInterface
|
|||||||
"{$p}_history",
|
"{$p}_history",
|
||||||
Join::WITH,
|
Join::WITH,
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->eq("{$p}_history.user", "acpw.createdBy"),
|
$qb->expr()->eq("{$p}_history.user", 'acpw.createdBy'),
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->lte("{$p}_history.startDate", "acpw.createdAt"),
|
$qb->expr()->lte("{$p}_history.startDate", 'acpw.createdAt'),
|
||||||
$qb->expr()->orX(
|
$qb->expr()->orX(
|
||||||
$qb->expr()->isNull("{$p}_history.endDate"),
|
$qb->expr()->isNull("{$p}_history.endDate"),
|
||||||
$qb->expr()->gt("{$p}_history.endDate", "acpw.createdAt")
|
$qb->expr()->gt("{$p}_history.endDate", 'acpw.createdAt')
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -44,12 +44,12 @@ class CreatorScopeAggregator implements AggregatorInterface
|
|||||||
"{$p}_history",
|
"{$p}_history",
|
||||||
Join::WITH,
|
Join::WITH,
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->eq("{$p}_history.user", "acpw.createdBy"),
|
$qb->expr()->eq("{$p}_history.user", 'acpw.createdBy'),
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->lte("{$p}_history.startDate", "acpw.createdAt"),
|
$qb->expr()->lte("{$p}_history.startDate", 'acpw.createdAt'),
|
||||||
$qb->expr()->orX(
|
$qb->expr()->orX(
|
||||||
$qb->expr()->isNull("{$p}_history.endDate"),
|
$qb->expr()->isNull("{$p}_history.endDate"),
|
||||||
$qb->expr()->gt("{$p}_history.endDate", "acpw.createdAt")
|
$qb->expr()->gt("{$p}_history.endDate", 'acpw.createdAt')
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -46,12 +46,12 @@ class CreatorJobFilter implements FilterInterface
|
|||||||
"{$p}_history",
|
"{$p}_history",
|
||||||
Join::WITH,
|
Join::WITH,
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->eq("{$p}_history.user", "acpw.createdBy"),
|
$qb->expr()->eq("{$p}_history.user", 'acpw.createdBy'),
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->lte("{$p}_history.startDate", "acpw.createdAt"),
|
$qb->expr()->lte("{$p}_history.startDate", 'acpw.createdAt'),
|
||||||
$qb->expr()->orX(
|
$qb->expr()->orX(
|
||||||
$qb->expr()->isNull("{$p}_history.endDate"),
|
$qb->expr()->isNull("{$p}_history.endDate"),
|
||||||
$qb->expr()->gt("{$p}_history.endDate", "acpw.createdAt")
|
$qb->expr()->gt("{$p}_history.endDate", 'acpw.createdAt')
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -46,12 +46,12 @@ class CreatorScopeFilter implements FilterInterface
|
|||||||
"{$p}_history",
|
"{$p}_history",
|
||||||
Join::WITH,
|
Join::WITH,
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->eq("{$p}_history.user", "acpw.createdBy"),
|
$qb->expr()->eq("{$p}_history.user", 'acpw.createdBy'),
|
||||||
$qb->expr()->andX(
|
$qb->expr()->andX(
|
||||||
$qb->expr()->lte("{$p}_history.startDate", "acpw.createdAt"),
|
$qb->expr()->lte("{$p}_history.startDate", 'acpw.createdAt'),
|
||||||
$qb->expr()->orX(
|
$qb->expr()->orX(
|
||||||
$qb->expr()->isNull("{$p}_history.endDate"),
|
$qb->expr()->isNull("{$p}_history.endDate"),
|
||||||
$qb->expr()->gt("{$p}_history.endDate", "acpw.createdAt")
|
$qb->expr()->gt("{$p}_history.endDate", 'acpw.createdAt')
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -100,7 +100,7 @@ class ThirdPartyType extends AbstractType
|
|||||||
'label' => 'thirdparty.Contact data are confidential',
|
'label' => 'thirdparty.Contact data are confidential',
|
||||||
]);
|
]);
|
||||||
|
|
||||||
// Institutional ThirdParty (parent)
|
// Institutional ThirdParty (parent)
|
||||||
} else {
|
} else {
|
||||||
$builder
|
$builder
|
||||||
->add('nameCompany', TextType::class, [
|
->add('nameCompany', TextType::class, [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user