﻿<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
    <xsl:template name="NewItemSummary">

        <xsl:param name="TemplatePathURL" select="'Not Available'"></xsl:param>
        <xsl:param name="SiblingID" select="'Not Available'"></xsl:param>
        <xsl:param name="ItemDivPrefix" select="'Not Available'"></xsl:param>
        <xsl:param name="GoalID" select="'NA'"></xsl:param>
        <xsl:param name="ParentID" select="'NA'"></xsl:param>
        <xsl:param name="Version" select="'NA'"></xsl:param>

        <div style="margin:0px; padding:0px;">
            <table width='100%'>
                <tr>
                    <td colspan='3'></td>
                </tr>
                <tr>
                    <td style="width: 90px;">
                        <xsl:choose>
                            <xsl:when test="$Version = '1.1' or $Version = '1.2'">
                                <a onclick='return ItemSummary_Save_ForVersion(
                                                       "txt_Item_{$SiblingID}_Sibling_Title",
                                                       "{$SiblingID}",
                                                       "{$ParentID}",
                                                       "{$GoalID}",
                                                       "divTxtAddAction",
                                                       "span_item_{$SiblingID}_Sibling_ErrorMessage",
                                                       "{$Version}"
                                                     );'
                                    class="anchorButton" style="color: white; text-decoration: none;" tabindex="2">
                                    Save
                                </a>
                            </xsl:when>
                            <xsl:otherwise>
                                <a onclick='return ItemSummary_Save(
                                           "txt_Item_{$SiblingID}_Sibling_Title",
                                           "{$SiblingID}",
                                           "{$ParentID}",
                                           "{$GoalID}",
                                           "divTxtAddAction",
                                           "span_item_{$SiblingID}_Sibling_ErrorMessage");'
                                   class="anchorButton" style="color: white; text-decoration: none;" tabindex="2">
                                    Save
                                </a>
                            </xsl:otherwise>
                        </xsl:choose>

                    </td>
                    <td colspan="2">
                        <a onclick='return TaskNew_CancelAction(
                                            "{$ItemDivPrefix}_Sibling");'
                           class="anchorButton" style="color: white; text-decoration: none;" tabindex="3">
                            Cancel
                        </a>
                    </td>
                </tr>
            </table>
        </div>
    </xsl:template>
</xsl:stylesheet>
