phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] admin/templates/default addressmaster.xsl, NONE, 1.1


From: Bettina Gille <address@hidden>
Subject: [Phpgroupware-cvs] admin/templates/default addressmaster.xsl, NONE, 1.1
Date: Thu, 13 Nov 2003 13:53:19 +0000

Update of /cvsroot/phpgroupware/admin/templates/default
In directory subversions:/tmp/cvs-serv18346

Added Files:
        addressmaster.xsl 
Log Message:
update groups

--- NEW FILE: addressmaster.xsl ---
<!-- $Id: addressmaster.xsl,v 1.1 2003/11/13 13:53:16 ceb Exp $ -->

        <xsl:template name="addressmaster">
                <xsl:choose>
                        <xsl:when test="addressmaster_list">
                                <xsl:apply-templates 
select="addressmaster_list"/>
                        </xsl:when>
                        <xsl:when test="addressmaster_edit">
                                <xsl:apply-templates 
select="addressmaster_edit"/>
                        </xsl:when>
                        <xsl:otherwise>
                                <xsl:apply-templates select="list"/>
                        </xsl:otherwise>
                </xsl:choose>
        </xsl:template>

<!-- BEGIN addressmaster list -->

        <xsl:template match="addressmaster_list">
                <center>
                <table width="80%" border="0" cellpadding="2" cellspacing="2">  
                        <tr class="th">
                                <td colspan="3"><xsl:value-of 
select="lang_users"/></td>
                        </tr>
                        <tr class="th">
                                <td width="33%"><xsl:value-of 
select="sort_lid"/></td>
                                <td width="33%"><xsl:value-of 
select="sort_firstname"/></td>
                                <td width="33%"><xsl:value-of 
select="sort_lastname"/></td>
                        </tr>

<!-- BEGIN user_list -->
                        <xsl:if test="addressmaster_user != ''">
                                <xsl:apply-templates 
select="addressmaster_user"/>
                        </xsl:if>
<!-- END user_list -->

                        <tr height="5">
                                <td>&nbsp;</td>
                        </tr>
                        <tr class="th">
                                <td colspan="3"><xsl:value-of 
select="lang_groups"/></td>
                        </tr>
                        <tr class="th">
                                <td width="33%"><xsl:value-of 
select="sort_lid"/></td>
                                <td width="33%">&nbsp;</td>
                                <td width="33%">&nbsp;</td>
                        </tr>

<!-- BEGIN group_list -->
                        <xsl:if test="addressmaster_group != ''">
                                <xsl:apply-templates 
select="addressmaster_group"/>
                        </xsl:if>
<!-- END group_list -->

                        <tr valign="bottom" height="50">
                                <xsl:variable name="action_url" 
select="action_url"/>
                                <xsl:variable name="lang_edit" 
select="lang_edit"/>
                                <xsl:variable name="lang_done" 
select="lang_done"/>
                                <form method="POST" action="{$action_url}">
                                <td colspan="2"><input type="submit" 
name="edit" value="{$lang_edit}"/></td>
                                <td colspan="2" align="right"><input 
type="submit" name="done" value="{$lang_done}"/></td>
                                </form>
                        </tr>
                </table>
                </center>
        </xsl:template>

        <xsl:template match="addressmaster_user">
                <tr>                                                            
                                                                                
 
                        <xsl:attribute name="class">
                                <xsl:choose>
                                        <xsl:when test="@class">
                                                <xsl:value-of select="@class"/>
                                        </xsl:when>
                                        <xsl:when test="position() mod 2 = 0">
                                                <xsl:text>row_off</xsl:text>
                                        </xsl:when>
                                        <xsl:otherwise>
                                                <xsl:text>row_on</xsl:text>
                                        </xsl:otherwise>
                                </xsl:choose>
                        </xsl:attribute>
                        <td><xsl:value-of select="lid"/></td>
                        <td><xsl:value-of select="firstname"/></td>
                        <td><xsl:value-of select="lastname"/></td>
                </tr>
        </xsl:template>

        <xsl:template match="addressmaster_group">
                <tr>                                                            
                                                                                
 
                        <xsl:attribute name="class">
                                <xsl:choose>
                                        <xsl:when test="@class">
                                                <xsl:value-of select="@class"/>
                                        </xsl:when>
                                        <xsl:when test="position() mod 2 = 0">
                                                <xsl:text>row_off</xsl:text>
                                        </xsl:when>
                                        <xsl:otherwise>
                                                <xsl:text>row_on</xsl:text>
                                        </xsl:otherwise>
                                </xsl:choose>
                        </xsl:attribute>
                        <td><xsl:value-of select="lid"/></td>
                        <td>&nbsp;</td>
                        <td>&nbsp;</td>
                </tr>
        </xsl:template>

        <xsl:template match="addressmaster_edit">
                <xsl:variable name="action_url" select="action_url"/>
                <xsl:variable name="lang_save" select="lang_save"/>
                <xsl:variable name="lang_cancel" select="lang_cancel"/>
                <center>
                        <xsl:value-of select="error_message"/>
                        <table border="0" width="80%" cellpadding="2" 
cellspacing="2">
                                <form method="POST" action="{$action_url}" 
name="app_form">
                                        <tr>
                                                <td valign="top"><xsl:value-of 
select="lang_select_addressmasters"/>:</td>
                                                <td>
                                                        <xsl:choose>
                                                                <xsl:when 
test="select_user != ''">
                                                                        
<xsl:apply-templates select="select_user"/>
                                                                </xsl:when>
                                                                <xsl:otherwise>
                                                                        
<xsl:apply-templates select="popwin_user"/>
                                                                </xsl:otherwise>
                                                        </xsl:choose>
                                                </td>
                                        </tr>
                                        <tr height="50" valign="bottom">
                                                <td><input type="submit" 
name="save" value="{$lang_save}"/></td>
                                                <td align="right"><input 
type="submit" name="cancel" value="{$lang_cancel}"/></td>
                                        </tr>
                                </form>
                        </table>
                </center>
        </xsl:template>

<!-- BEGIN select -->

        <xsl:template match="select_user">
                <xsl:variable name="u_select_size" select="u_select_size"/>
                <xsl:variable name="g_select_size" select="g_select_size"/>
                <table>
                        <tr>
                                <td valign="top"><xsl:value-of 
select="lang_select_users"/>:</td>
                                <td>
                                        <select name="account_addressmaster[]" 
multiple="multiple" size="{$u_select_size}">
                                <xsl:apply-templates select="user_list"/>
                        </select>
                                </td>
                        </tr>
                        <tr>
                                <td valign="top"><xsl:value-of 
select="lang_select_groups"/>:</td>
                                <td>
                                        <select name="group_addressmaster[]" 
multiple="multiple" size="{$g_select_size}">
                                <xsl:apply-templates select="group_list"/>
                        </select>
                                </td>
                        </tr>
                </table>
        </xsl:template>

<!-- END select -->

<!-- BEGIN popwin -->

        <xsl:template match="popwin_user">
                <xsl:variable name="select_size" select="select_size"/>
                <xsl:variable name="lang_open_popup" select="lang_open_popup"/>
                <xsl:variable name="url" select="url"/>
                <xsl:variable name="width" select="width"/>
                <xsl:variable name="height" select="height"/>
                <table>
                        <tr>
                                <td>
                                        <select name="account_addressmaster[]" 
multiple="multiple" size="{$select_size}">
                                                <xsl:if test="user_list != ''">
                                                        <xsl:apply-templates 
select="user_list"/>
                                                </xsl:if>
                                        </select>
                                </td>
                                <td valign="top">
                                <input type="button" value="{$lang_open_popup}" 
onClick="openwindow({$url},{$width},{$height})"/>
                                </td>
                        </tr>
                </table>
        </xsl:template>

<!-- END popwin -->

        <xsl:template match="user_list">
                <xsl:variable name="account_id" select="account_id"/>
                <xsl:choose>
                        <xsl:when test="select_value != ''">
                                <option value="{$account_id}" 
selected="selected"><xsl:value-of select="fullname"/></option>
                        </xsl:when>
                        <xsl:otherwise>
                                <option value="{$account_id}"><xsl:value-of 
select="fullname"/></option>
                        </xsl:otherwise>
                </xsl:choose>
        </xsl:template>

        <xsl:template match="group_list">
                <xsl:variable name="account_id" select="account_id"/>
                <xsl:choose>
                        <xsl:when test="select_value != ''">
                                <option value="{$account_id}" 
selected="selected"><xsl:value-of select="fullname"/></option>
                        </xsl:when>
                        <xsl:otherwise>
                                <option value="{$account_id}"><xsl:value-of 
select="fullname"/></option>
                        </xsl:otherwise>
                </xsl:choose>
        </xsl:template>





reply via email to

[Prev in Thread] Current Thread [Next in Thread]