62c3bcc4340734268d9555ea98eef8b6716beb51.svn-base 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. var grid = null;
  2. var paramsEw = { "listId" :'365', "condition" : " 1=1 and IS_DEL='0' and is_alert = '0' and is_send = '3' " } ;
  3. function initComplete(){
  4. grid = $("#ewgrid").quiGrid({
  5. columns:[
  6. {name: 'FD_OBJECTID365', hide : true},
  7. { display: "名称", name: "EARLY_WARNING_NAME_365", align:"center", width:"30%",
  8. render : function(rowdata, rowindex, value, column){
  9. return "<span style='color:#FFFFFF;'>" + value + "</span>" ;
  10. }
  11. },
  12. { display: "时间", name: "RELEASE_RELIEVE_DATE_365", align:"center", width:"40%",
  13. render : function(rowdata, rowindex, value, column){
  14. return "<span style='color:#FFFFFF;'>" + value + "</span>" ;
  15. }
  16. },
  17. { display: "级别", name: "CURRENT_EW_LEVEL_365_SHOW", align:"center", width:"10%",
  18. render : function(rowdata, rowindex, value, column){
  19. return "<span style='color:#FFFFFF;'>" + value + "</span>" ;
  20. }
  21. },
  22. { display: "概要", name: "EW_SUMMARY_365", align:"center", width:"20%",
  23. render : function(rowdata, rowindex, value, column){
  24. return "<span style='color:#FFFFFF;'>" + value + "</span>" ;
  25. }
  26. }] ,
  27. url: $.pathname() + '/ws/crud/CRUDService/queryQui',
  28. "params":paramsEw,
  29. pageSize: 10,
  30. sortName: "CURRENT_EW_LEVEL_365",
  31. width:"300",
  32. height:"auto",
  33. showTitle:true,
  34. showPageInfo:false,
  35. fixedCellHeight:true,
  36. alternatingRow: false,
  37. rowHeight:30,
  38. rowAttrRender: function(rowdata, rowindex, rowid){
  39. return rowdata["__index"] % 2 == 0 ? "style='background-color:#212749;'" : "style='background-color:#2C3A54;'" ;
  40. }
  41. }
  42. )};
  43. //查询
  44. function searchEw(query){
  45. grid.setOptions({ params : query});
  46. grid.setNewPage(1);
  47. grid.loadData();//加载数据
  48. };