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")
|
||||
*/
|
||||
|
@ -126,19 +126,19 @@ class EntityWorkflowStep
|
||||
$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)) {
|
||||
$this->destEmail[] = $email;
|
||||
if (!$this->ccUser->contains($user)) {
|
||||
$this->ccUser[] = $user;
|
||||
}
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function addCcUser(User $user): self
|
||||
public function addDestEmail(string $email): self
|
||||
{
|
||||
if (!$this->ccUser->contains($user)) {
|
||||
$this->ccUser[] = $user;
|
||||
if (!in_array($email, $this->destEmail, true)) {
|
||||
$this->destEmail[] = $email;
|
||||
}
|
||||
|
||||
return $this;
|
||||
|
@ -160,7 +160,7 @@ class WorkflowStepType extends AbstractType
|
||||
'label' => 'workflow.cc for next steps',
|
||||
'multiple' => true,
|
||||
'mapped' => false,
|
||||
'required' => false
|
||||
'required' => false,
|
||||
])
|
||||
->add('future_dest_emails', ChillCollectionType::class, [
|
||||
'label' => 'workflow.dest by email',
|
||||
|
@ -2,6 +2,13 @@
|
||||
|
||||
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;
|
||||
|
||||
use Doctrine\DBAL\Schema\Schema;
|
||||
|
Loading…
x
Reference in New Issue
Block a user