| | <?php |
| |
|
| | namespace Kanboard\Formatter; |
| |
|
| | use Kanboard\Core\Filter\FormatterInterface; |
| | use Kanboard\Core\Group\GroupProviderInterface; |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | class GroupAutoCompleteFormatter extends BaseFormatter implements FormatterInterface |
| | { |
| | |
| | |
| | |
| | |
| | |
| | |
| | protected $groups; |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function withGroups(array $groups) |
| | { |
| | $this->groups = $groups; |
| | return $this; |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | public function format() |
| | { |
| | $result = array(); |
| |
|
| | foreach ($this->groups as $group) { |
| | $result[] = array( |
| | 'id' => $group->getInternalId(), |
| | 'external_id' => $group->getExternalId(), |
| | 'value' => $group->getName(), |
| | 'label' => $group->getName(), |
| | ); |
| | } |
| |
|
| | return $result; |
| | } |
| | } |
| |
|