12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364 |
- <%@ page pageEncoding="UTF-8"%>
- <%@ page contentType="text/html; charset=UTF-8" language="java" %>
- <%@ page import ="java.util.*"%>
- <%@ page language="java"
- import="com.sysmodel.XFormModelImpl,
- com.sysmodel.xformmodel.impl.*"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <head>
- <META http-equiv="Content-Type" content="text/html; charset=GB2312">
- <script type="text/javascript" src="../../../scripts/ext20/adapter/ext/ext-base.js"></script>
- <link rel="stylesheet" href="../../../scripts/ext20/resources/css/ext-all.css" type="text/css"></link>
- <script type="text/javascript" src="../../../scripts/ext20/ext-all.js"></script>
- <script type="text/javascript">
- Ext.onReady(function(){
- Ext.state.Manager.setProvider(new Ext.state.CookieProvider());
- var myData = [
- <%
- ArrayList JsFunctions=XFormModelImpl.getInstance().getJsFunctions();
- for(int j = 0; j < JsFunctions.size(); j++){
- JsFunctionImpl JsFunctionImpl=(JsFunctionImpl)JsFunctions.get(j);
- String code= JsFunctionImpl.getCode();
- String name= JsFunctionImpl.getName();
- String value=JsFunctionImpl.getValue();
- String Description=JsFunctionImpl.getDescription();
- out.print("['"+code+"','"+value+"','"+name+"','"+Description+"']");
- if (j != JsFunctions.size() - 1) out.print(",\n");
- }
- %>
- ];
-
- var store = new Ext.data.SimpleStore({
- fields: [
- {name: 'code', type: 'int'},
- {name: 'value'},
- {name: 'name'},
- {name: 'description'}
- ]
- });
- store.loadData(myData);
-
- var grid = new Ext.grid.GridPanel({
- store: store,
- columns: [new Ext.grid.RowNumberer(),
- {header: "编号", width: 75, sortable: true,dataIndex: 'code'},
- {header: "对应的value", width: 75, sortable: true,dataIndex: 'value'},
- {header: "名称", width: 75, sortable: true,dataIndex: 'name'},
- {header: "描述", width: 85, sortable: true,dataIndex: 'description'}
- ],
- stripeRows: true,
- height:500,
- width:750,
- title:'页面中通用JS函数配置'
- });
-
- grid.render('report');
- grid.getSelectionModel().selectFirstRow();
- });
- </script>
- </head>
- <body>
- <div id="report"></div>
- </body>
- </html>
|