﻿<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
    <xsl:template match="/">
        <xsl:call-template name="AddBrandScheduleProfile">
            <xsl:with-param name="Title" select="normalize-space(AjaxRequest/Params/SectionTitle)"></xsl:with-param>
            <xsl:with-param name="SectionHTML" select="normalize-space(AjaxRequest/Params/SectionHTML)"></xsl:with-param>
            <xsl:with-param name="SectionSummary" select="normalize-space(AjaxRequest/Params/SectionSummary)"></xsl:with-param>

            <xsl:with-param name="BrandID" select="normalize-space(AjaxRequest/Params/BrandID)"></xsl:with-param>
            <xsl:with-param name="BrandTabID" select="normalize-space(AjaxRequest/Params/BrandTabID)"></xsl:with-param>

        </xsl:call-template>
    </xsl:template>

    <xsl:template name="AddBrandScheduleProfile">
        <xsl:param name="Title" select="'N/A'"></xsl:param>
        <xsl:param name="SectionHTML" select="'N/A'"></xsl:param>
        <xsl:param name="SectionSummary" select="'N/A'"></xsl:param>

        <xsl:param name="BrandID" select="'N/A'"></xsl:param>
        <xsl:param name="BrandTabID" select="'N/A'"></xsl:param>

        <div id="divEditBrandScheduleProfile">
            <div>
                <span class="labelSize12">
                    <xsl:value-of select="$Title" ></xsl:value-of>
                </span>
            </div>

            <hr></hr>

            <div>
                <xsl:value-of select="$SectionHTML" disable-output-escaping="yes"></xsl:value-of>
            </div>

            <div style="padding-top:10px;">
                <span class="button" id="btnEditScheduleProfile" style="display:none; width:30px; text-align:center;"
                      onclick="UpdateBrandScheduleProfile({$BrandID}, {$BrandTabID}, 'divBrandProfileOperations')">
                    Edit
                </span>
            </div>
        </div>

    </xsl:template>

</xsl:stylesheet>
