public function tagsList($attachment)
    {
        $tagsString = '';
        if (empty($attachment->tags)) {
            return $tagsString;
        }
        $Table = TableRegistry::get($attachment->model);

        foreach ($attachment->tags as $tag) {
            $tagsString .= '<label class="label label-default">' . $Table->getTagCaption($tag) . '</label> ';
        }
        return $tagsString;
    }