版本比较

标识

  • 该行被添加。
  • 该行被删除。
  • Formatting was changed.
Localtab Group
定义table

tablecol

tablebutton

示例

示例1

显示检查计划列表

Code Block
languagehtml/xml
 	  <jxui:table jboname="PS_PGC_SAFE_CKPLAN" id="ps_pgc_safe_ckplan_table" trwhereattr="WFT_BACKFLAG" trwhere="==" trwherevalue="T" trfontcolor="red" trbgcolor="rgb(241,237,237)" selectmode="multiple" bottomtipvalue="注:红色表示回退的单据。" bottomtipcolor="red" apprestrictions="valid_status is not null">
	  	<jxui:tablecol  dataattribute="CKPLAN_NUM"  type="link" mxevent="selectrecord"/>
	  	<jxui:tablecol  dataattribute="CKPLAN_NAME" />
	  	<jxui:tablecol  dataattribute="CKUSER_NAME" />
	  	<jxui:tablecol  dataattribute="TIME_LIMIT" />
	  	<jxui:tablecol  dataattribute="START_DATE" />
	  	<jxui:tablecol  dataattribute="END_DATE" />
	  	<jxui:tablecol  dataattribute="PLAN_HERALD" />
	  </jxui:table>

示例2

对列表添加查询条件,使用EL表达式。

Code Block
languagehtml/xml
 	  <jxui:table jboname="PS_SCHEDULE_PLAN" id="listtable" selectmode="none" 
 	  			apprestrictions="PLAN_TYPE=1 ${jxfn:userProjectCause(' and project_id=')}">
	  	<jxui:tablecol  dataattribute="PLAN_NAME"  type="link" mxevent="selectrecord"/>
	  	<jxui:tablecol  dataattribute="PS_SCHEDULE_PLANOBJECT_ID.Project_name" label="项目名称" />
	  	<jxui:tablecol  dataattribute="PS_SCHEDULE_PLAN_INSURE_STATUS.item_name" label="有效?"/>
	  </jxui:table>

当登录用户的project_id为空时,整个条件解析结果为:PLAN_TYPE=1,否则解析为 PLAN_TYPE=1 and object_id='000001'

示例3:filterable

使用filterable来快速过滤表格数据

Code Block
title参考:http://svn.jxtech.net/svn/清蓄施工现场检查与整改移动平台/开发库/源代码/JxPlatform/PlatformSrc/jxweb/WEB-INF/content/app/servicecontract/condservercontract/lookup_list-table.jsp
languagexml
 <jxui:table jboname="PS_SERVICE_CONTRACT" id="listtable" selectmode="none" filterable="true">
    <jxui:tablecol label="选择" dataattribute="SERVICE_CONTRACT_ID" mxevent="lookup"/>
    <jxui:tablecol dataattribute="SERVICE_CONTRACT_CODE" />
    <jxui:tablecol dataattribute="SERVICE_CONTRACT_NAME" />
    <jxui:tablecol dataattribute="VENDOR_COMPANY"  label="承包商"/>
</jxui:table>

效果图:

Image Removed

查询结果图:

Image Removed

直接使用SQL示例

参考:myidr-month-table.ftl

Code Block
titleftl
languagexml
<#assign jxui=JspTaglibs["/WEB-INF/tlds/jxui.tld"] />
<@jxui.table jboname="SQL_IDR_YEAR" id="idryear"  selectmode="none" orderby="startdate desc" 
    sql="select a.projectnum, sum(taskhour)/8 taskhour, startdate,b.projectname 
    from (select projectnum, taskhour, to_char(startdate, 'yyyy') startdate 
    from idr where ownerid='${jxuserinfo.userid}') a,jxproject b 
    where a.projectnum=b.projectnum and taskhour>0 
    group by a.projectnum, startdate,b.projectname ">
    <@jxui.tablecol dataattribute="startdate" label='${lang["table.idr.startdate"]}'/>
    <@jxui.tablecol dataattribute="taskhour" label='${lang["table.idr.days"]}'/>
    <@jxui.tablecol dataattribute="projectnum" label='${lang["table.idr.projectnum"]}'  />
    <@jxui.tablecol dataattribute="projectname" label='${lang["table.idr.projectname"]}'  />
</@jxui.table>

 

 

问题处理

  1. 列表界面查询条件会记忆,需要设定不记忆条件

...