• DataForm Webpart Inside (3)


    find the xsl files in folder 

    

    C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS\XSL
    

    sequence of DataForm xslt

    first:

    1. construct the class

    <xsl:variable name="ViewClassName">
        <xsl:choose>
          <xsl:when test="$dvt_RowCount=0">ms-emptyView</xsl:when>
          <xsl:otherwise>ms-listviewtable</xsl:otherwise>
        </xsl:choose>
     </xsl:variable>
    

    2. Root match

    <xsl:template match="/">
    

    alwarys go here

    <xsl:template name="View_Default_RootTemplate" mode="RootTemplate" match="View" ddwrt:dvt_mode="root">
    

    3. ToolBar

    <xsl:call-template name="ListViewToolbar"/>
    

    4. List Body( actually it just a html table )

    <xsl:template match="View" mode="full">
    

    5. Header Columns

    <xsl:apply-templates mode="header" select="ViewFields/FieldRef[not(@Explicit='TRUE')]"/>
    

    it is many kinds of columns , such as datetime, string , integer , each kind of columns has it's own template

      <xsl:template match="FieldRef[@FieldType='BusinessData']" mode="header" ddwrt:dvt_mode="header">
        <th class="ms-vh2" nowrap="nowrap" scope="col" onmouseover="OnChildColumn(this)">
          <xsl:call-template name="dvt_headerfield">
            <xsl:with-param name="fieldname">
              <xsl:value-of select="@Name"/>
            </xsl:with-param>
            <xsl:with-param name="fieldtitle">
              <xsl:value-of select="@DisplayName"/>
            </xsl:with-param>
            <xsl:with-param name="displayname">
              <xsl:value-of select="@DisplayName"/>
            </xsl:with-param>
            <xsl:with-param name="fieldtype">BusinessData</xsl:with-param>
          </xsl:call-template>
        </th>
     </xsl:template>
    
  • 相关阅读:
    校园网络安全CTF 第一题 和 你真了解我吗?
    href="#" 链接到当前页面
    Redis的Set无序集合命令
    Redis的List链表类型命令
    Redis的String、Hash类型命令
    redis2.8.xx安装配置
    ZendFramework安装配置
    复选框的全选、反选
    列表中被点击的行加亮背景色
    SQL中的替换函数replace()使用
  • 原文地址:https://www.cnblogs.com/frankzye/p/2016177.html
Copyright © 2020-2023  润新知