Scarab commit: svn commit: r10858 - branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue

Johannes Höchstädter <[email protected]>
Newsgroups gmane.comp.java.scarab.cvs
Message-ID <[email protected]>
Author: jhoech
Date: 2009-10-26 06:19:02-0700
New Revision: 10858

Modified:
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueBody.vm
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab1.vm
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab2.vm
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab3.vm
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Att.vm
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Dep.vm
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Url.vm
   branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab5.vm

Log:
FIX - Isse SCB3002 Event handler by which the user can expand or collapse a single tab is disabled in tabbed view now.

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueBody.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueBody.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueBody.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueBody.vm	2009-10-26 06:19:02-0700
@@ -39,6 +39,17 @@
 ##   </div>
 ## #end
 
+## Creates heading for given tab and title.
+## Toggles event handler, which makes it possible to the user
+## to switch current tab on or off.
+#macro (tabHeading $tabId $title)
+	#if($tab.equals("all"))
+		#set($imgName = $tabId.concat(".state"))
+		<h3 onClick=smartToggleVisibility('$tabId')><img name="$imgName" src="$staticLink.setPath($iconCollapse)"/>$title</h3>
+	#else
+		<h3>$title</h3>
+	#end
+#end
 
 <div class="scarab-canvas">
 

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab1.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab1.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab1.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab1.vm	2009-10-26 06:19:02-0700
@@ -1,7 +1,7 @@
 #set ($canAddComment = $scarabR.hasPermission($scarabG.Permission.ISSUE__COMMENT, $module) && $rmit.Active)
 #set ($isEditAttributes = $canEdit && $data.Parameters.getBoolean("edit_attributes"))
 
-<h3 onClick=smartToggleVisibility('properties')><img name="properties.state" src="$staticLink.setPath($iconCollapse)"/>$l10n.IssueAttributesNavi</h3>
+#tabHeading("properties" $l10n.IssueAttributesNavi)
 <div id='properties'>
 
   <div class="axial2">

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab2.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab2.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab2.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab2.vm	2009-10-26 06:19:02-0700
@@ -1,5 +1,5 @@
 ### PERSONNEL
-<h3 onClick=smartToggleVisibility('personnel')><img name="personnel.state" src="$staticLink.setPath($iconCollapse)"/>$l10n.format("PersonnelNavi", $numUsers)</h3>
+#tabHeading("personnel" $l10n.format("PersonnelNavi", $numUsers))
 <div id='personnel'>
   <table width="100%" border="1" cellspacing="2" cellpadding="3">
     <tr>

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab3.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab3.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab3.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab3.vm	2009-10-26 06:19:02-0700
@@ -18,7 +18,7 @@
    #end
 #end
 
-<h3 onClick=smartToggleVisibility('comments')><img name="comments.state" src="$staticLink.setPath($iconCollapse)"/>$l10n.format("CommentsNavi", $numComments)</h3>
+#tabHeading("comments" $l10n.format("CommentsNavi", $numComments))
 <div id='comments'>
 #if ($comments.isEmpty() && !$canAddComment)
   $l10n.NoComments

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Att.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Att.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Att.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Att.vm	2009-10-26 06:19:02-0700
@@ -4,7 +4,7 @@
 #set ($intakeAttachment = $intake.Attachment.setKey("fileKey$currentIssue.QueryKey"))
 #set ($attachments = $currentIssue.ExistingAttachments)
 
-<h3 onClick=smartToggleVisibility('attachments')><img name="attachments.state" src="$staticLink.setPath($iconCollapse)"/>$l10n.format("AttachmentsNavi",$currentIssue.ExistingAttachments.size())</h3>
+#tabHeading("attachments" $l10n.format("AttachmentsNavi",$currentIssue.ExistingAttachments.size()))
 <div id='attachments'>
 #if ($attachments.isEmpty() && !$canAddAttachment)
 $l10n.NoAttachments

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Dep.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Dep.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Dep.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Dep.vm	2009-10-26 06:19:02-0700
@@ -269,7 +269,7 @@
 ####   dependencies
 ################################################################################
 
-<h3 onClick=smartToggleVisibility('dependencies')><img name="dependencies.state" src="$staticLink.setPath($iconCollapse)"/>$l10n.format("RelationsNavi", $numDependencies)</h3>
+#tabHeading("dependencies" $l10n.format("RelationsNavi", $numDependencies))
 <div id='dependencies'>
   #if ($numDependencies > 0)
 

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Url.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Url.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Url.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab4Url.vm	2009-10-26 06:19:02-0700
@@ -1,4 +1,4 @@
-<h3 onClick=smartToggleVisibility('related')><img name="related.state" src="$staticLink.setPath($iconCollapse)"/>$l10n.format("RelatedLinksNavi",$currentIssue.Urls.size())</h3>
+#tabHeading("related" $l10n.format("RelatedLinksNavi",$currentIssue.Urls.size()))
 <div id="related">
 
 #if ($currentIssue.Urls.isEmpty() && !$canEdit)

Modified: branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab5.vm
Url: http://scarab.tigris.org/source/browse/scarab/branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab5.vm?view=diff&pathrev=10858&r1=10857&r2=10858
==============================================================================
--- branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab5.vm	(original)
+++ branches/release/0.22/src/webapp/WEB-INF/templates/viewIssue/ViewIssueTab5.vm	2009-10-26 06:19:02-0700
@@ -4,7 +4,7 @@
 #end
 
 #if (!$allActivitySets.isEmpty())
-<h3 onClick=smartToggleVisibility('history')><img name="history.state" src="$staticLink.setPath($iconCollapse)"/>$l10n.ChangeHistory</h3>
+#tabHeading("history" $l10n.ChangeHistory)
 <div id="history">
 
   #foreach ($activitySet in $allActivitySets)

------------------------------------------------------
http://scarab.tigris.org/ds/viewMessage.do?dsForumId=3577&dsMessageId=2411379
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.