templetSelectList.jsp 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
  2. <script>
  3. var leaseContractId = null;
  4. var titleFormatter = function(value , row , index){
  5. if(row.templetType== 1){
  6. return "<a title='合同打印' href='leaseContractAction_print?templet.id=" + row.id + "&leaseContract.id=" + leaseContractId + "' target='_blank' style='cursor:pointer'> " + row.title + " </a>";
  7. }
  8. };
  9. function templet_load(id){
  10. leaseContractId = id;
  11. /**合同模板信息列表**/
  12. $('#templetSelectDataGrid').datagrid({
  13. rownumbers:true,
  14. fit:true,
  15. fitColumns:false,
  16. border:false,
  17. sortOrder:'desc',
  18. nowrap:true,
  19. url:whzl.basePath + '/templetAction_List?templet.templetType=1',
  20. singleSelect: true,
  21. loadFilter:function(result){
  22. if(result.success){
  23. return result.obj;
  24. }else{
  25. alert(result.message);
  26. return ;
  27. }
  28. }
  29. });
  30. }
  31. </script>
  32. <div class="easyui-layout" data-options="fit:true,border:false" style="margin: 0px;padding: 0px;">
  33. <div data-options="region:'center',border:false">
  34. <table id="templetSelectDataGrid" >
  35. <thead>
  36. <tr>
  37. <th data-options="field:'title',sortable:false,width:320,formatter:titleFormatter">模板标题</th>
  38. </tr>
  39. </thead>
  40. </table>
  41. </div>
  42. </div>