Changeset 326 for trunk/web/addons/job_monarch/image.php
- Timestamp:
- 04/21/07 16:22:47 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/web/addons/job_monarch/image.php
r305 r326 29 29 } 30 30 31 function checkSessionData() { 32 33 global $_SESSION; 34 35 session_start(); 36 37 if( isset( $_SESSION["data"] ) ) { 38 $myxml_data = &$_SESSION["data"]; 39 } else { 40 $myxml_data = 0; 41 } 42 43 if( !$myxml_data ) { 44 $ds = new DataSource(); 45 $myxml_data = $ds->getData(); 46 47 print_f( "%s\n", $myxml_data ); 48 } 49 return $myxml_data; 50 } 51 52 31 53 $httpvars = new HTTPVariables( $HTTP_GET_VARS, $_GET ); 32 54 $view = $httpvars->getHttpVar( "view" ); … … 41 63 function drawHostImage() { 42 64 43 global $clustername, $hostname ;65 global $clustername, $hostname, $data_gatherer; 44 66 45 $data_gatherer = new DataGatherer( $clustername ); 46 $data_gatherer->parseXML(); 67 $ds = new DataSource(); 68 $myxml_data = $ds->getData(); 69 70 $data_gatherer = new DataGatherer( $clustername ); 71 72 $data_gatherer->parseXML( $myxml_data ); 47 73 48 74 if( $data_gatherer->isJobmonRunning() ) … … 56 82 function drawSmallClusterImage() { 57 83 58 global $clustername ;84 global $clustername, $data_gatherer; 59 85 60 $data_gatherer = new DataGatherer( $clustername ); 61 $data_gatherer->parseXML(); 86 $ds = new DataSource(); 87 $myxml_data = $ds->getData(); 88 89 $data_gatherer = new DataGatherer( $clustername ); 90 91 $data_gatherer->parseXML( $myxml_data ); 62 92 63 93 if( $data_gatherer->isJobmonRunning() ) { 64 $ic = new ClusterImage( $ clustername );94 $ic = new ClusterImage( $myxml_data, $clustername ); 65 95 $ic->setSmall(); 66 96 } else { … … 75 105 global $filter, $clustername; 76 106 77 $ic = new ClusterImage( $clustername ); 107 $myxml_data = checkSessionData(); 108 109 $ic = new ClusterImage( $myxml_data, $clustername ); 78 110 $ic->setBig(); 79 111
Note: See TracChangeset
for help on using the changeset viewer.