zoukankan      html  css  js  c++  java
  • 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>
    
  • 相关阅读:
    poj 3261 Milk Patterns 后缀数组+二分
    poj 2774 Long Long Message(后缀数组入门题)
    hdu 5719 Arrange
    hdu 5720 Wool
    DROP TABLE 恢复
    MySQL数据库改名的三种方法
    MySQL 误操作后数据恢复(update,delete忘加where条件)
    MySQL常用SQL语句优化
    EXPLAIN 命令详解
    mysql sql语句大全
  • 原文地址:https://www.cnblogs.com/frankzye/p/2016177.html
Copyright © 2011-2022 走看看