From 38492a612ba1608f96bf61a9d08f7589e688209b Mon Sep 17 00:00:00 2001
From: Yusei Tahara <yusei@nexedi.com>
Date: Fri, 23 Nov 2007 13:07:13 +0000
Subject: [PATCH] 2007-11-23 Yusei * Add bookmark box in
 WebSite_viewDashboardRenderer.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@17761 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../WebSite_viewDashboardRenderer.xml         | 37 +++++++++++++++----
 bt5/erp5_web/bt/change_log                    |  3 ++
 bt5/erp5_web/bt/revision                      |  2 +-
 3 files changed, 33 insertions(+), 9 deletions(-)

diff --git a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web_widget_library/WebSite_viewDashboardRenderer.xml b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web_widget_library/WebSite_viewDashboardRenderer.xml
index 04ae4c8b35..be1c48028d 100644
--- a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web_widget_library/WebSite_viewDashboardRenderer.xml
+++ b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web_widget_library/WebSite_viewDashboardRenderer.xml
@@ -3,11 +3,8 @@
   <record id="1" aka="AAAAAAAAAAE=">
     <pickle>
       <tuple>
-        <tuple>
-          <string>Products.PageTemplates.ZopePageTemplate</string>
-          <string>ZopePageTemplate</string>
-        </tuple>
-        <none/>
+        <global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
+        <tuple/>
       </tuple>
     </pickle>
     <pickle>
@@ -69,8 +66,8 @@
             <span tal:replace="doc/getTitle"/>\n
             <span tal:condition="python: hasattr(doc, \'getVersion\') and doc.getVersion()" \n
                         tal:replace="python: \'ver. %s\' % doc.getVersion()"/>\n
-            (<span tal:content="python: doc.getValidationStateTitle()" \n
-                    tal:attributes="class python:doc.getTranslatedValidationStateTitle()"/>)\n
+            (<span tal:content="python: getattr(doc, \'getValidationStateTitle\',None) and doc.getValidationStateTitle()" \n
+                    tal:attributes="class doc/getTranslatedValidationStateTitle|nothing"/>)\n
           </a>\n
          </tal:block>\n
         </li>\n
@@ -166,7 +163,31 @@
     </div>\n
   </tal:block>\n
 </tal:block>\n
-</tal:block>
+\n
+<tal:block metal:define-macro="bookmark">\n
+  <tal:block tal:define="content_list python: here.WebSite_getBookmarkContentValueList()">\n
+    <div class="boxHeader">\n
+      Bookmark\n
+    </div>\n
+    <div class="boxContent">\n
+      <ul>\n
+        <li tal:repeat="item python: content_list">\n
+          <a tal:define="url python: \'%s/view\' % item.absolute_url()"\n
+            tal:attributes="href url">\n
+            <tal:block tal:replace="python: here.WebSite_getFancyRelativeDate(item.getCreationDate())"\n
+                       tal:on-error="string:"/>&mdash;\n
+            <tal:block tal:replace="item/getTitleOrId"\n
+                       tal:on-error="string:"/>\n
+          </a>\n
+          <tal:block tal:replace="python: \'(%s)\' % item.getPortalType()"\n
+                     tal:on-error="string:"/>\n
+        </li>\n
+      </ul>\n
+    </div>\n
+  </tal:block>\n
+</tal:block>\n
+</tal:block>\n
+
 
 ]]></string> </value>
         </item>
diff --git a/bt5/erp5_web/bt/change_log b/bt5/erp5_web/bt/change_log
index f1b6efee7d..a04f7b6d46 100644
--- a/bt5/erp5_web/bt/change_log
+++ b/bt5/erp5_web/bt/change_log
@@ -1,3 +1,6 @@
+2007-11-23 Yusei
+* Add bookmark box in WebSite_viewDashboardRenderer.
+
 2007-11-21 Yusei
 * if document's title is empty, then display its id in document relation box.
 
diff --git a/bt5/erp5_web/bt/revision b/bt5/erp5_web/bt/revision
index 7dfce3516b..d63356f400 100644
--- a/bt5/erp5_web/bt/revision
+++ b/bt5/erp5_web/bt/revision
@@ -1 +1 @@
-594
\ No newline at end of file
+596
\ No newline at end of file
-- 
2.30.9