* kanban column added for team column config data
* team contains jira filter id and kanban column config
This commit is contained in:
parent
a43b5e9d09
commit
c096510b3d
83
src/App/Entity/KanbanColumn.php
Normal file
83
src/App/Entity/KanbanColumn.php
Normal file
@ -0,0 +1,83 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
|
||||||
|
namespace App\Entity;
|
||||||
|
|
||||||
|
class KanbanColumn implements \JsonSerializable
|
||||||
|
{
|
||||||
|
/** @var string */
|
||||||
|
private $jiraStatusName = "";
|
||||||
|
|
||||||
|
/** @var string */
|
||||||
|
private $label = "";
|
||||||
|
|
||||||
|
/** @var integer */
|
||||||
|
private $wipLimit = 0;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public function getJiraStatusName(): ?string
|
||||||
|
{
|
||||||
|
return $this->jiraStatusName;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $jiraStatusName
|
||||||
|
* @return KanbanColumn
|
||||||
|
*/
|
||||||
|
public function setJiraStatusName(?string $jiraStatusName): KanbanColumn
|
||||||
|
{
|
||||||
|
$this->jiraStatusName = $jiraStatusName;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public function getLabel(): ?string
|
||||||
|
{
|
||||||
|
return $this->label;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $label
|
||||||
|
* @return KanbanColumn
|
||||||
|
*/
|
||||||
|
public function setLabel(?string $label): KanbanColumn
|
||||||
|
{
|
||||||
|
$this->label = $label;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
public function getWipLimit(): ?int
|
||||||
|
{
|
||||||
|
return $this->wipLimit;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param int $wipLimit
|
||||||
|
* @return KanbanColumn
|
||||||
|
*/
|
||||||
|
public function setWipLimit(?int $wipLimit): KanbanColumn
|
||||||
|
{
|
||||||
|
$this->wipLimit = $wipLimit;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array
|
||||||
|
*/
|
||||||
|
function jsonSerialize()
|
||||||
|
{
|
||||||
|
return [
|
||||||
|
'jiraStatusName' => $this->getJiraStatusName(),
|
||||||
|
'label' => $this->getLabel(),
|
||||||
|
'wipLimit' => $this->getWipLimit(),
|
||||||
|
];
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -309,7 +309,7 @@ class KanbanEntry implements \JsonSerializable
|
|||||||
/**
|
/**
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function getIssuePriority(): string
|
public function getIssuePriority(): ?string
|
||||||
{
|
{
|
||||||
return $this->issuePriority;
|
return $this->issuePriority;
|
||||||
}
|
}
|
||||||
@ -318,7 +318,7 @@ class KanbanEntry implements \JsonSerializable
|
|||||||
* @param string $issuePriority
|
* @param string $issuePriority
|
||||||
* @return KanbanEntry
|
* @return KanbanEntry
|
||||||
*/
|
*/
|
||||||
public function setIssuePriority(string $issuePriority): KanbanEntry
|
public function setIssuePriority(?string $issuePriority): KanbanEntry
|
||||||
{
|
{
|
||||||
$this->issuePriority = $issuePriority;
|
$this->issuePriority = $issuePriority;
|
||||||
return $this;
|
return $this;
|
||||||
@ -327,7 +327,7 @@ class KanbanEntry implements \JsonSerializable
|
|||||||
/**
|
/**
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function getIssuePriorityIcon(): string
|
public function getIssuePriorityIcon(): ?string
|
||||||
{
|
{
|
||||||
return $this->issuePriorityIcon;
|
return $this->issuePriorityIcon;
|
||||||
}
|
}
|
||||||
@ -336,7 +336,7 @@ class KanbanEntry implements \JsonSerializable
|
|||||||
* @param string $issuePriorityIcon
|
* @param string $issuePriorityIcon
|
||||||
* @return KanbanEntry
|
* @return KanbanEntry
|
||||||
*/
|
*/
|
||||||
public function setIssuePriorityIcon(string $issuePriorityIcon): KanbanEntry
|
public function setIssuePriorityIcon(?string $issuePriorityIcon): KanbanEntry
|
||||||
{
|
{
|
||||||
$this->issuePriorityIcon = $issuePriorityIcon;
|
$this->issuePriorityIcon = $issuePriorityIcon;
|
||||||
return $this;
|
return $this;
|
||||||
|
|||||||
@ -47,6 +47,36 @@ class Team implements JsonSerializable
|
|||||||
*/
|
*/
|
||||||
private $slides;
|
private $slides;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @ORM\Column(name="filter_id", type="integer", nullable=true)
|
||||||
|
* @var int
|
||||||
|
*/
|
||||||
|
private $filterId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @ORM\Column(name="backlog_column", type="json", nullable=true)
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $backlogColumn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @ORM\Column(name="inprogress_column", type="json", nullable=true)
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $inprogressColumn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @ORM\Column(name="verification_column", type="json", nullable=true)
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $verificationColumn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @ORM\Column(name="done_column", type="json", nullable=true)
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $doneColumn;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @ORM\Column(name="is_active", type="boolean")
|
* @ORM\Column(name="is_active", type="boolean")
|
||||||
* @var bool
|
* @var bool
|
||||||
@ -69,8 +99,13 @@ class Team implements JsonSerializable
|
|||||||
|
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
$this->slides = new ArrayCollection;
|
|
||||||
$this->members = new \ArrayObject;
|
$this->members = new \ArrayObject;
|
||||||
|
$this->slides = new ArrayCollection;
|
||||||
|
|
||||||
|
$this->backlogColumn = new KanbanColumn();
|
||||||
|
$this->inprogressColumn = new KanbanColumn();
|
||||||
|
$this->verificationColumn = new KanbanColumn();
|
||||||
|
$this->doneColumn = new KanbanColumn();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -159,6 +194,96 @@ class Team implements JsonSerializable
|
|||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
public function getFilterId(): ?int
|
||||||
|
{
|
||||||
|
return $this->filterId;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param int $filterId
|
||||||
|
* @return Team
|
||||||
|
*/
|
||||||
|
public function setFilterId(?int $filterId): Team
|
||||||
|
{
|
||||||
|
$this->filterId = $filterId;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array|KanbanColumn
|
||||||
|
*/
|
||||||
|
public function getBacklogColumn()
|
||||||
|
{
|
||||||
|
return $this->backlogColumn;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param array $backlogColumn
|
||||||
|
* @return Team
|
||||||
|
*/
|
||||||
|
public function setBacklogColumn(?array $backlogColumn): Team
|
||||||
|
{
|
||||||
|
$this->backlogColumn = $backlogColumn;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array|KanbanColumn
|
||||||
|
*/
|
||||||
|
public function getInprogressColumn()
|
||||||
|
{
|
||||||
|
return $this->inprogressColumn;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param array $inprogressColumn
|
||||||
|
* @return Team
|
||||||
|
*/
|
||||||
|
public function setInprogressColumn(array $inprogressColumn): Team
|
||||||
|
{
|
||||||
|
$this->inprogressColumn = $inprogressColumn;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array|KanbanColumn
|
||||||
|
*/
|
||||||
|
public function getVerificationColumn()
|
||||||
|
{
|
||||||
|
return $this->verificationColumn;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param array $verificationColumn
|
||||||
|
* @return Team
|
||||||
|
*/
|
||||||
|
public function setVerificationColumn(?array $verificationColumn): Team
|
||||||
|
{
|
||||||
|
$this->verificationColumn = $verificationColumn;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array|KanbanColumn
|
||||||
|
*/
|
||||||
|
public function getDoneColumn()
|
||||||
|
{
|
||||||
|
return $this->doneColumn;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param array $doneColumn
|
||||||
|
* @return Team
|
||||||
|
*/
|
||||||
|
public function setDoneColumn(?array $doneColumn): Team
|
||||||
|
{
|
||||||
|
$this->doneColumn = $doneColumn;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return bool
|
* @return bool
|
||||||
*/
|
*/
|
||||||
@ -222,6 +347,11 @@ class Team implements JsonSerializable
|
|||||||
'id' => $this->getId(),
|
'id' => $this->getId(),
|
||||||
'name' => $this->getName(),
|
'name' => $this->getName(),
|
||||||
'members' => $this->getMembers(),
|
'members' => $this->getMembers(),
|
||||||
|
'filterId' => $this->getFilterId(),
|
||||||
|
'backlogColumn' => $this->getBacklogColumn() ?? new KanbanColumn(),
|
||||||
|
'inprogressColumn' => $this->getInprogressColumn() ?? new KanbanColumn(),
|
||||||
|
'verificationColumn' => $this->getVerificationColumn() ?? new KanbanColumn(),
|
||||||
|
'doneColumn' => $this->getDoneColumn() ?? new KanbanColumn(),
|
||||||
'isActive' => $this->isActive(),
|
'isActive' => $this->isActive(),
|
||||||
'createdAt' => $this->getCreatedAt()
|
'createdAt' => $this->getCreatedAt()
|
||||||
? $this->getCreatedAt()->format("Y-m-d H:i:s")
|
? $this->getCreatedAt()->format("Y-m-d H:i:s")
|
||||||
|
|||||||
@ -4,6 +4,7 @@ declare(strict_types=1);
|
|||||||
|
|
||||||
namespace App\Form;
|
namespace App\Form;
|
||||||
|
|
||||||
|
use App\Entity\KanbanColumn;
|
||||||
use Zend\Form\Annotation;
|
use Zend\Form\Annotation;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -41,6 +42,60 @@ class Team
|
|||||||
*/
|
*/
|
||||||
private $members;
|
private $members;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Annotation\Type("Zend\Form\Element\Number")
|
||||||
|
* @Annotation\Required(true)
|
||||||
|
* @Annotation\Options({
|
||||||
|
* "label": "Jira filter id"
|
||||||
|
* })
|
||||||
|
* @var int
|
||||||
|
*/
|
||||||
|
private $filterId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This is a dummy field, not a text actually. Only used to filter the input
|
||||||
|
* @Annotation\Type("Zend\Form\Element\Text")
|
||||||
|
* @Annotation\Required(true)
|
||||||
|
* @Annotation\Options({
|
||||||
|
* "label": "1st column"
|
||||||
|
* })
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $backlogColumn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This is a dummy field, not a text actually. Only used to filter the input
|
||||||
|
* @Annotation\Type("Zend\Form\Element\Text")
|
||||||
|
* @Annotation\Required(true)
|
||||||
|
* @Annotation\Options({
|
||||||
|
* "label": "1st column"
|
||||||
|
* })
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $inprogressColumn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This is a dummy field, not a text actually. Only used to filter the input
|
||||||
|
* @Annotation\Type("Zend\Form\Element\Text")
|
||||||
|
* @Annotation\Required(true)
|
||||||
|
* @Annotation\Options({
|
||||||
|
* "label": "1st column"
|
||||||
|
* })
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $verificationColumn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This is a dummy field, not a text actually. Only used to filter the input
|
||||||
|
* @Annotation\Type("Zend\Form\Element\Text")
|
||||||
|
* @Annotation\Required(true)
|
||||||
|
* @Annotation\Options({
|
||||||
|
* "label": "1st column"
|
||||||
|
* })
|
||||||
|
* @var KanbanColumn
|
||||||
|
*/
|
||||||
|
private $doneColumn;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Also a dummy field, a
|
* Also a dummy field, a
|
||||||
* @Annotation\Type("Zend\Form\Element\Text")
|
* @Annotation\Type("Zend\Form\Element\Text")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user