Replies
found the problem….wasn't serializing to javascript
dataSource: jQuery.parseJSON( data ),
Thanks
Al
since i'm encoding it in the php file, do i need to decode it when setting the grid data source. do i have to escape characters? this is a part of the exact text coming php get.
"{\"response\":{\"result\":[{\"DetailsPageURL\":\"\/showresource.do?resourceid=10156726&method=showResourceForResourceID&PRINTER_FRIENDLY=true\",\"TODAYUNAVAILPERCENT\":\"0.0\",\"Attribute\":[{\"DISPLAYNAME\":\"Response Time\",\"Value\":\"182\",\"Units\":\" ms\",\"AttributeID\":\"5002\"}],\"HEALTHATTRIBUTEID\":\"5001\",\"TARGETADDRESS\":\"\",\"RESOURCENAME\":\"FixFlyer Heartbeats\",\"TODAYAVAILPERCENT\":\"100.0\",\"TARGETNAME\":\"\",\"TODAYSCHEDDOWNPERCENT\":\"0.0\",\"AVAILABILITYATTRIBUTEID\":\"5000\",\"HEALTHSEVERITY\":\"5\",\"DISKUTIL\":\"-1\",\"MANAGED\":\"true\",\"PHYMEMUTIL\":\"-1\",\"AVAILABILITYMESSAGE\":\"Resource up.
The resource FixFlyer Heartbeats is available.\",\"AVAILABILITYSEVERITY\":\"5\",\"TYPESHORTNAME\":\"Database Query Monitor\",\"TYPE\":\"QueryMonitor\",\"DESCRIPTION\":\"QueryMonitor Monitoring: for FixFlyer Heartbeats\",\"LASTPOLLEDTIME\":\"May 5, 2015 3:37 PM\",\"RESOURCEID\":\"10156726\",\"TODAYUNMANGDPERCENT\":\"0.0\",\"HEALTHMESSAGE\":\"Health of FixFlyer Heartbeats is clear.
Root Cause :
Hi Maya, thank you for responding.
i'm actually using this ajax call and it's just not working. nothing is produced as output.
wouldnt it work this way?
$.ajax({
type: "GET",
url: "proxy.php",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function(data)
{
$("#monitorGrid").igGrid({
width: "80%",
caption: "App Monitor",
dataSource: data, //Array of objects defined above
autoGenerateColumns: true,
responseDataKey: "response.result"
});
}});
<table id="monitorGrid" border=1 ></table>
thanks again
{"response":{"result":[{"DetailsPageURL":"/showresource.do?resourceid=10156726&method=showResourceForResourceID&PRINTER_FRIENDLY=true","HEALTHATTRIBUTEID":"5001","ASSOCIATEDGROUPS":"-","RESOURCENAME":"FixFlyer Heartbeats","Managed":"true","HEALTHSEVERITY":"5","AVAILABILITYATTRIBUTEID":"5000","AVAILABILITYMESSAGE":"Resource up. <br>The resource FixFlyer Heartbeats is available.","TYPESHORTNAME":"Database Query Monitor","TYPE":"QueryMonitor","DESCRIPTION":"QueryMonitor Monitoring: for FixFlyer Heartbeats","AVAILABILITYSEVERITY":"5","RESOURCEID":"10156726","HEALTHMESSAGE":"Health of FixFlyer Heartbeats is clear. <br>Root Cause : <br>1. FixFlyer Heartbeats is up<br>2. select user_id, last_hb_time, case when (current_timestamp - interval '3' minute) > last_hb_time the is up<br>3. select user_id, current_timestamp, (systimestamp-last_hb_time) *60 as lastheartbeat_minutes, last_h is up<br>4. select user_id, current_timestamp, (systimestamp-last_hb_time) *60 as lastheartbeat_minutes, last_hb is up<br>5. select user_id, current_timestamp, (current_timestamp-last_hb_time) *60 as lastheartbeat_minutes, la is up<br>6. select user_id, current_timestamp, last_hb_time, case when (current_timestamp - interval '3' minute) is up<br>7. select user_id, to_char(current_timestamp,'YYYY-MM-DD HH24:MI:SS') as Current_TimeStamp , last_hb_ti is up<br>8. select user_id, to_char(current_timestamp,'YYYY-MM-DD HH24:MI:SS') as Current_TimeStamp , last_hb_ti is up<br>9. select user_id, to_char(current_timestamp,'YYYY-MM-DD HH24:MI:SS') as Current_TimeStamp , last_hb_ti is up<br>10. select upper(user_id) as user_id, to_char(current_timestamp,'YYYY-MM-DD HH24:MI:SS') as Current_Time is up<br>11. select upper(user_id) is up<br>12. select upper(user_id) 174174 ' HEARTBEAT' as user_id, to_char(current_timestamp,'YYYY-MM-DD HH24:MI: is up<br>13. select upper(user_id) 174174 ' HEARTBEAT' as user_id, to_char(current_timestamp,'YYYY-MM-DD HH24:MI: is up<br>14. select upper(user_id) as user_id, to_char(current_timestamp,'YYYY-MM-DD HH24:MI:SS') as Current_Tim is up<br>15. select sub.*, case when sub.okhb=1 then 'DOWN' else 'UP' end as status FROM (SELECT USER_ID, PROD_MO is up<br>16. ffhandler-BARX_TCR-CAXTONPRD_TCR is up<br>17. ffhandler-BARX_TCR-CAXTONPRD_TCR --> STATUS UP contains UP (threshold).<br>18. ffhandler-BLPTSOX-CXTNTSOX is up<br>19. ffhandler-BLPTSOX-CXTNTSOX --> STATUS UP contains UP (threshold).<br>20. ffhandler-CITIFX-CAXTON_VELOSTP is up<br>21. ffhandler-CITIFX-CAXTON_VELOSTP --> STATUS UP contains UP (threshold).<br>22. ffhandler-FIXFLYER is up<br>23. ffhandler-FIXFLYER --> STATUS UP contains UP (threshold).<br>24. ffhandler-GTX-caxton_stp is up<br>25. ffhandler-GTX-caxton_stp --> STATUS UP contains UP (threshold).<br>26. ffhandler-NEOVDC-FIXFLYERDC is up<br>27. ffhandler-NEOVDC-FIXFLYERDC --> STATUS UP contains UP (threshold).<br>28. ffhandler-TT_ORDER-CAXTON is up<br>29. ffhandler-TT_ORDER-CAXTON --> STATUS UP contains UP (threshold).<br>30. ffhandler-TT_ORDER-MGSCAXTDRCL is up<br>31. ffhandler-TT_ORDER-MGSCAXTDRCL --> STATUS UP contains UP (threshold).<br>32. ffhandler-prod.fxgrid-order.Caxton.STP is up<br>33. ffhandler-prod.fxgrid-order.Caxton.STP --> STATUS UP contains UP (threshold).<br>34. validator is up<br>35. validator --> STATUS UP contains UP (threshold).<br>36. validatordd is up<br>37. validatordd --> STATUS UP contains UP (threshold).<br>","DISPLAYNAME":"FixFlyer Heartbeats","RCAPageURL":"/jsp/RCA.jsp?resourceid=10156726&attributeid=5001","HEALTHSTATUS":"clear","IMAGEPATH":"/images/queryMonitoring.gif","AVAILABILITYSTATUS":"up","LASTALARMTIME":"1430322217222"}],"uri":"/AppManager/json/ListMonitor"},"response-code":"4000"}
hey Zdravko, i have a simliar question. i have a grid with a checkbox column (checkbox header to select all). when i click the checkboxes or the header checkbox i want to display count of total items checked in a seperate label.
i have it working for checking each individual checkbox but not the check all.
p.s. not using template column
how would i go about that?
thanks