浏览代码

limit size for the edit title

Thomas Rabaix 11 年之前
父节点
当前提交
634188df6b
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Resources/views/CRUD/base_edit.html.twig

+ 1 - 1
Resources/views/CRUD/base_edit.html.twig

@@ -13,7 +13,7 @@ file that was distributed with this source code.
 
 {% block title %}
     {% if admin.id(object) is not null %}
-        {{ "title_edit"|trans({'%name%': admin.toString(object) }, 'SonataAdminBundle') }}
+        {{ "title_edit"|trans({'%name%': admin.toString(object)|truncate(15) }, 'SonataAdminBundle') }}
     {% else %}
         {{ "title_create"|trans({}, 'SonataAdminBundle') }}
     {% endif %}