{{define "item:add_relation"}} {{ $relation_name := printf "%s%v" "ItemRelation-New-" .relatedItem.Id }} {{.relatedItem.Type_title}} : {{.relatedItem.Title}} {{ if gt (len .relatedItem.Categories) 0 }} {{ range (stringToArray .relatedItem.Categories "|")}} {{ $category_name := index $.categoriesMap .}}
{{ $category_name }}
{{ end }} {{ end }} {{ if gt (len .relatedItem.Tags) 0 }} {{ range (stringToArray .relatedItem.Tags ",")}}
{{ . }}
{{ end }} {{ end }} {{ widget_relation_type $relation_name "Link" `id="$relation_name" class="w3-input w3-border"` }}
Remove
{{ end }}