Resolve merge with master

This commit is contained in:
2024-12-11 10:46:06 +01:00
667 changed files with 37245 additions and 7119 deletions

View File

@@ -13,7 +13,9 @@ namespace Chill\TaskBundle\DataFixtures\ORM;
use Chill\MainBundle\DataFixtures\ORM\LoadPermissionsGroup;
use Chill\MainBundle\DataFixtures\ORM\LoadScopes;
use Chill\MainBundle\Entity\PermissionsGroup;
use Chill\MainBundle\Entity\RoleScope;
use Chill\MainBundle\Entity\Scope;
use Chill\TaskBundle\Security\Authorization\TaskVoter;
use Doctrine\Common\DataFixtures\AbstractFixture;
use Doctrine\Common\DataFixtures\OrderedFixtureInterface;
@@ -25,18 +27,18 @@ use Doctrine\Persistence\ObjectManager;
*/
class LoadTaskACL extends AbstractFixture implements OrderedFixtureInterface
{
public function getOrder()
public function getOrder(): int
{
return 16000;
}
public function load(ObjectManager $manager)
public function load(ObjectManager $manager): void
{
foreach (LoadPermissionsGroup::$refs as $permissionsGroupRef) {
$permissionsGroup = $this->getReference($permissionsGroupRef);
$permissionsGroup = $this->getReference($permissionsGroupRef, PermissionsGroup::class);
foreach (LoadScopes::$references as $scopeRef) {
$scope = $this->getReference($scopeRef);
$scope = $this->getReference($scopeRef, Scope::class);
// create permission group
switch ($permissionsGroup->getName()) {
case 'social':

View File

@@ -39,8 +39,10 @@
{% block css %}
{{ parent() }}
{{ encore_entry_link_tags('page_task_list') }}
{{ encore_entry_link_tags('mod_pickentity_type') }}
{% endblock %}
{% block js %}
{{ parent() }}
{{ encore_entry_script_tags('page_task_list') }}
{{ encore_entry_script_tags('mod_pickentity_type') }}
{% endblock %}

View File

@@ -38,7 +38,9 @@
{% block css %}
{{ encore_entry_link_tags('page_task_list') }}
{{ encore_entry_link_tags('mod_pickentity_type') }}
{% endblock %}
{% block js %}
{{ encore_entry_script_tags('page_task_list') }}
{{ encore_entry_script_tags('mod_pickentity_type') }}
{% endblock %}

View File

@@ -0,0 +1,36 @@
<?php
declare(strict_types=1);
/*
* Chill is a software for social workers
*
* For the full copyright and license information, please view
* the LICENSE file that was distributed with this source code.
*/
namespace Chill\Migrations\Task;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
final class Version20241101093514 extends AbstractMigration
{
public function getDescription(): string
{
return 'Set a default for task current_states';
}
public function up(Schema $schema): void
{
$this->addSql('ALTER TABLE chill_task.recurring_task ALTER current_states SET DEFAULT \'[]\'');
$this->addSql('ALTER TABLE chill_task.single_task ALTER current_states SET DEFAULT \'[]\'');
}
public function down(Schema $schema): void
{
$this->addSql('ALTER TABLE chill_task.single_task ALTER current_states DROP DEFAULT');
$this->addSql('ALTER TABLE chill_task.recurring_task ALTER current_states DROP DEFAULT');
}
}