23 lines
290 B
PHP
23 lines
290 B
PHP
<?php
|
|
/**
|
|
* Created by PhpStorm.
|
|
* User: Marco Glietsch
|
|
* Date: 09.11.2018
|
|
* Time: 16:29
|
|
*/
|
|
|
|
namespace App\Helpers;
|
|
|
|
class TagHelper
|
|
{
|
|
static function getTagNameByType($model, $type)
|
|
{
|
|
foreach($model->tags as $t)
|
|
{
|
|
if($t->type == $type)
|
|
{
|
|
return $t->name;
|
|
}
|
|
}
|
|
}
|
|
} |