mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Add users in cc in workflow: fix code style
This commit is contained in:
parent
295406d9b7
commit
a3db67fd1e
@ -228,7 +228,6 @@ class WorkflowController extends AbstractController
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Route("/{_locale}/main/workflow/list/cc", name="chill_main_workflow_list_cc")
|
* @Route("/{_locale}/main/workflow/list/cc", name="chill_main_workflow_list_cc")
|
||||||
*/
|
*/
|
||||||
|
@ -126,19 +126,19 @@ class EntityWorkflowStep
|
|||||||
$this->accessKey = bin2hex(openssl_random_pseudo_bytes(32));
|
$this->accessKey = bin2hex(openssl_random_pseudo_bytes(32));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function addDestEmail(string $email): self
|
public function addCcUser(User $user): self
|
||||||
{
|
{
|
||||||
if (!in_array($email, $this->destEmail, true)) {
|
if (!$this->ccUser->contains($user)) {
|
||||||
$this->destEmail[] = $email;
|
$this->ccUser[] = $user;
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function addCcUser(User $user): self
|
public function addDestEmail(string $email): self
|
||||||
{
|
{
|
||||||
if (!$this->ccUser->contains($user)) {
|
if (!in_array($email, $this->destEmail, true)) {
|
||||||
$this->ccUser[] = $user;
|
$this->destEmail[] = $email;
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
|
@ -160,7 +160,7 @@ class WorkflowStepType extends AbstractType
|
|||||||
'label' => 'workflow.cc for next steps',
|
'label' => 'workflow.cc for next steps',
|
||||||
'multiple' => true,
|
'multiple' => true,
|
||||||
'mapped' => false,
|
'mapped' => false,
|
||||||
'required' => false
|
'required' => false,
|
||||||
])
|
])
|
||||||
->add('future_dest_emails', ChillCollectionType::class, [
|
->add('future_dest_emails', ChillCollectionType::class, [
|
||||||
'label' => 'workflow.dest by email',
|
'label' => 'workflow.dest by email',
|
||||||
|
@ -2,6 +2,13 @@
|
|||||||
|
|
||||||
declare(strict_types=1);
|
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\Main;
|
namespace Chill\Migrations\Main;
|
||||||
|
|
||||||
use Doctrine\DBAL\Schema\Schema;
|
use Doctrine\DBAL\Schema\Schema;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user