From 8f0e0f7f923a91e17c11a3f1dcd636004a5f4f2a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com>
Date: Thu, 27 Aug 2009 08:49:55 +0000
Subject: [PATCH] backport a Formulator change to display field descriptions in
 the ZMI

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@28650 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/Formulator/dtml/fieldEdit.dtml       | 7 +++++--
 product/Formulator/dtml/fieldListHeader.dtml | 7 +++++++
 product/Formulator/dtml/fieldOverride.dtml   | 2 +-
 product/Formulator/dtml/fieldTales.dtml      | 2 +-
 4 files changed, 14 insertions(+), 4 deletions(-)

diff --git a/product/Formulator/dtml/fieldEdit.dtml b/product/Formulator/dtml/fieldEdit.dtml
index bae25d5f34..05296f7b04 100644
--- a/product/Formulator/dtml/fieldEdit.dtml
+++ b/product/Formulator/dtml/fieldEdit.dtml
@@ -15,7 +15,7 @@ Edit <dtml-var meta_type> properties here.
 
 <dtml-if fields>
 <tr>
-<td colspan="3" class="form-title">
+<td colspan="4" class="form-title">
   <dtml-var "_.string.capitalize(group)"> properties
 </td>
 </tr>
@@ -37,9 +37,12 @@ Edit <dtml-var meta_type> properties here.
     <td align="left" valign="top">
     <dtml-var "field.render(value)">
     </td>
-    <td><div class="form-element">
+    <td valign="top" ><div class="form-element">
     <dtml-var "field.meta_type">
     </div></td>
+    <td align="left" valign="top"><div class="form-element">
+    <dtml-var "field.get_value('description')">
+    </div></td>
   </tr>
 </dtml-let>
 </dtml-in>
diff --git a/product/Formulator/dtml/fieldListHeader.dtml b/product/Formulator/dtml/fieldListHeader.dtml
index e30fef5dfe..f6a11e008f 100644
--- a/product/Formulator/dtml/fieldListHeader.dtml
+++ b/product/Formulator/dtml/fieldListHeader.dtml
@@ -14,4 +14,11 @@
   Field
   </div>
   </td>
+  <dtml-if "_['URL'].find('manage_main')>-1">
+  <td align="left" valign="top">
+  <div class="form-label">
+  Description
+  </div>
+  </td>
+  </dtml-if>
 </tr>
\ No newline at end of file
diff --git a/product/Formulator/dtml/fieldOverride.dtml b/product/Formulator/dtml/fieldOverride.dtml
index 86b6133350..ea4ab6454f 100644
--- a/product/Formulator/dtml/fieldOverride.dtml
+++ b/product/Formulator/dtml/fieldOverride.dtml
@@ -33,7 +33,7 @@ Edit <dtml-var meta_type> method overrides here.
     <td align="left" valign="top">
     <dtml-var "field.render(value)">
     </td>
-    <td><div class="form-element">
+    <td valign="top"><div class="form-element">
     <dtml-var "current_field.form.get_field(field.id).meta_type">
     </div></td>
   </tr>
diff --git a/product/Formulator/dtml/fieldTales.dtml b/product/Formulator/dtml/fieldTales.dtml
index 352b0a18c5..c00c7b4a4f 100644
--- a/product/Formulator/dtml/fieldTales.dtml
+++ b/product/Formulator/dtml/fieldTales.dtml
@@ -39,7 +39,7 @@ This tab can therefore not be used.
     <td align="left" valign="top">
     <dtml-var "field.render(value)">
     </td>
-    <td><div class="form-element">
+    <td valign="top"><div class="form-element">
     <dtml-var "current_field.form.get_field(field.id).meta_type">
     </div></td>
   </tr>
-- 
2.30.9