zoukankan      html  css  js  c++  java
  • extremecomponents

    具体教程:

    http://www.cnblogs.com/QQParadise/articles/1488920.html

    教程中涉及到springmvc的相关知识

    下载地址:http://sourceforge.net/projects/extremecomp/

    下载下来的jar包不知为何目录结构不对,换成项目中的jar包(extremecomponents-1.0.1.jar),可正常。

    Web.xml

    <!-- 配置tld文件,tomcat6以上,需要加jsp-config-->

        <jsp-config>

        <taglib>

            <taglib-uri>/tld/extremecomponents</taglib-uri>

            <taglib-location>/WEB-INF/tld/extremecomponents.tld</taglib-location>

        </taglib>

      </jsp-config>

      <!-- 配置过滤器-->

        <filter>

            <filter-name>eXtremeExport</filter-name>

            <filter-class>org.extremecomponents.table.filter.ExportFilter</filter-class>

            <!-- 在 调用过滤器的doFilter()方法前设置响应报头,默认在之后-->

            <init-param>

                  <param-name>responseHeadersSetBeforeDoFilter</param-name>

                  <param-value>true</param-value>

             </init-param>

        </filter>

        <filter-mapping>

            <filter-name>eXtremeExport</filter-name>

            <url-pattern>/*</url-pattern>

        </filter-mapping>

    拷贝test.jsp   css     images    到项目目录下。

    载入test.jsp

    JSP中ec标签解析

    <ec:table
      items="presidents"
      var="pres"
    imagePath="${pageContext.request.contextPath}/images/*.gif"
      action="${pageContext.request.contextPath}/presidents.run"
      filterable="false"  //过滤器
      sortable="false"  //排序
      >
     <ec:row highlightRow="true"> //鼠标移到上边时,高亮
        <ec:column property="name" filterCell="droplist"
    /> //列过滤器
        <ec:column property="lastName" sortable="false"/> //可排序
      
        <ec:column property="term"/>
     
    <ec:column property="lastName">
          ${pres.lastName} //指定page中的值
        </ec:column>
    //视图,和导出文件相关
    <ec:column property="lastName" viewsAllowed="pdf"/>
        <ec:column property="firstName" title=" "/> //表头
     
        
      </ec:row>
    </ec:table>
     

    添加样式

    <ec:row
      style=""
      styleClass=""
      highlightClass=""
      />

    添加js

    <ec:row
      onclick=""
      onmouseover=""
      onmouseout=""
      />

    Limit 分页显示,类似mysql中的limit

    Context context = new HttpServletRequestContext(request);
    LimitFactory limitFactory = new TableLimitFactory(context);
    Limit limit = new TableLimit(limitFactory);
    //设置总的行数,每页多少行
    limit.setRowAttributes(totalRows, DEFAULT_ROWS_DISPLAYED);
  • 相关阅读:
    Installing Python Modules
    《利用Python 进行数据分析》
    使用Python进行描述性统计
    各种数字证书区别
    数字证书及CA的扫盲介绍
    expect学习笔记及实例详解
    使用openssl命令制作ecc证书
    那些证书相关的玩意儿(SSL,X.509,PEM,DER,CRT,CER,KEY,CSR,P12等)
    Openssl与私有CA搭建
    Openssl编程--源码分析
  • 原文地址:https://www.cnblogs.com/amibandoufu/p/5343185.html
Copyright © 2011-2022 走看看