[Erp5-report] r33521 yusei - in /erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style: SkinT...

nobody at svn.erp5.org nobody at svn.erp5.org
Tue Mar 9 11:10:01 CET 2010


Author: yusei
Date: Tue Mar  9 11:10:00 2010
New Revision: 33521

URL: http://svn.erp5.org?rev=33521&view=rev
Log:
2010-03-09
* Display title in breadcrumb if getCompactTranslatedTitle does not exist.

Modified:
    erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/breadcrumbs.xml
    erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/change_log
    erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/breadcrumbs.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/breadcrumbs.xml?rev=33521&r1=33520&r2=33521&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/breadcrumbs.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/breadcrumbs.xml [utf8] Tue Mar  9 11:10:00 2010
@@ -196,7 +196,13 @@
 for name in relative:\n
     obj = obj.restrictedTraverse(name)\n
     now.append(name)\n
-    title = obj.getCompactTranslatedTitle()\n
+    try:\n
+      title = obj.getCompactTranslatedTitle()\n
+    except AttributeError:\n
+      # Some objects do not have getCompactTranslatedTitle.\n
+      # UI related codes must run at any cases even if context is non-erp5 objects.\n
+      # Otherwise some error messages can be overridden by getCompactTranslatedTitle attribute error.\n
+      title = obj.Title()\n
     if not name == \'talkback\':\n
         result.append( { \'id\'      : name\n
                        , \'title\'   : title\n
@@ -266,6 +272,7 @@
                             <string>_getiter_</string>
                             <string>name</string>
                             <string>title</string>
+                            <string>AttributeError</string>
                           </tuple>
                         </value>
                     </item>

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/change_log
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/change_log?rev=33521&r1=33520&r2=33521&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/change_log [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/change_log [utf8] Tue Mar  9 11:10:00 2010
@@ -1,3 +1,6 @@
+2010-03-09
+* Display title in breadcrumb if getCompactTranslatedTitle does not exist.
+
 2010-03-02 yusei
 * Remove short title.
 

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision?rev=33521&r1=33520&r2=33521&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision [utf8] Tue Mar  9 11:10:00 2010
@@ -1,1 +1,1 @@
-912
+913




More information about the Erp5-report mailing list