[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] api/skins/default/widgets.xsl, 1.1.1.1.2.18
From: |
nomail |
Subject: |
[Phpgroupware-cvs] api/skins/default/widgets.xsl, 1.1.1.1.2.18 |
Date: |
Thu, 20 May 2004 21:40:02 -0000 |
Update of /api/skins/default
Modified Files:
Branch: proposal-branch
widgets.xsl
date: 2004/04/18 08:05:27; author: jengo; state: Exp; lines: +31 -3
Log Message:
Added in support for history rollbacks on an item, in order for an app to
support this there are some strict guidelines
=====================================================================
Index: api/skins/default/widgets.xsl
diff -u api/skins/default/widgets.xsl:1.1.1.1.2.17
api/skins/default/widgets.xsl:1.1.1.1.2.18
--- api/skins/default/widgets.xsl:1.1.1.1.2.17 Fri Apr 16 20:59:49 2004
+++ api/skins/default/widgets.xsl Sun Apr 18 08:05:27 2004
@@ -483,9 +483,23 @@
</tr>
</xsl:template>
+<xsl:template match="APP[action_type='api_history_rollback']">
+ <xsl:if test="count(dialog) > 0">
+ <br />
+ <xsl:call-template name="widget_dialog_yesno">
+ <xsl:with-param name="question"
select="dialog/question" />
+ <xsl:with-param name="yes_op" select="dialog/yes_op" />
+ <xsl:with-param name="no_op" select="dialog/no_op" />
+ <xsl:with-param name="inputs"
select="dialog/current_inputs/current_inputs_item" />
+ </xsl:call-template>
+ <p> </p>
+ </xsl:if>
+</xsl:template>
+
<xsl:template name="record_history">
<xsl:param name="history_data" />
<xsl:param name="title" select="'History'" />
+ <xsl:param name="location" select="''" />
<table border="0" width="95%">
<tr>
@@ -531,7 +545,21 @@
<tr class="{$class}">
<xsl:choose>
<xsl:when test="position() = 1">
-
<td width="22%"><font color="#000000"><xsl:value-of select="timestamp"
/></font></td>
+
<td width="22%">
+
<font color="#000000">
+
<!-- FIXME: This doesn't work right now, I need to find a way
to get the total number of unique nodes -->
+
<xsl:choose>
+
<xsl:when
test="count(.|key('key_history_timestamps',timestamp)[1]) > 0">
+
<a
href="{$baseurl}&op=api.base.history_rollback&location={$location}&history_id={id}">
+
<xsl:value-of select="timestamp" />
+
</a>
+
</xsl:when>
+
<xsl:otherwise>
+
<xsl:value-of select="timestamp" />
+
</xsl:otherwise>
+
</xsl:choose>
+
</font>
+
</td>
</xsl:when>
<xsl:otherwise><td width="22%"> </td></xsl:otherwise>
</xsl:choose>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] api/skins/default/widgets.xsl, 1.1.1.1.2.18,
nomail <=