Changeset 7649:cefb68d8a450
- Timestamp:
- 11/08/07 14:55:13 (6 years ago)
- Branch:
- default
- Children:
- 7650:bc80ecdd8c32, 8374:65b1f782c84d
- Location:
- sage/dsage/web
- Files:
-
- 2 edited
-
index.html (modified) (1 diff)
-
static/dsage_web.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
sage/dsage/web/index.html
r7645 r7649 21 21 <ul id="tabnav"> 22 22 <li class="tab1"> 23 <a href="#jobs" rel="history" onClick=" getJobs(count)">Job Status</a>23 <a href="#jobs" rel="history" onClick="showJobs()">Job Status</a> 24 24 </li> 25 25 <li class="tab2"> -
sage/dsage/web/static/dsage_web.js
r7645 r7649 2 2 3 3 function getServerDetails () { 4 $('#server_details').load('get_server_details'); 5 showServer() 6 } 7 8 function showServer () { 4 9 $('#jobs_table').hide(); 5 10 $('#job_details').hide(); 6 11 $('#help').hide(); 12 $('#server_details').show(); 13 $('#navigator').hide(); 14 } 15 function getJobs (c) { 16 count = c // Set global variable count to the selected count. 7 17 8 $('#server_details').load('get_server_details'); 9 $('#server_details').show(); 18 // Load jobs table with the given number of jobs. 19 $('#jobs_table').load('get_jobs', {'count': c}, function() { 20 $("#jobs_table").tablesorter(); } ); 21 22 // Change current selected count to red 23 $('#navigator > a').css('color', 'black') 24 $('#' + c).css('color', 'red') 10 25 } 11 26 12 function getJobs (c) { 13 count = c 14 $('#server_details').hide(); 27 function showJobs () { 28 $('#server_details').hide(); 15 29 $('#job_details').hide(); 16 30 $('#help').hide(); 17 $('#jobs_table').load('get_jobs', {'count': count}, function() {18 $("#jobs_table").tablesorter(); } );19 31 $('#jobs_table').show(); 20 32 } 21 33 22 34 function getJobDetails (job_id) { 35 $('#job_details').load('get_details', {'job_id': job_id}, function() { 36 $("#job_details").tablesorter(); } ); 37 showJobDetails() 38 } 39 40 function showJobDetails () { 23 41 $('#jobs_table').hide(); 42 $('#navigator').hide(); 24 43 $('#server_details').hide(); 25 44 $('#help').hide(); 26 $('#job_details').load('get_details', {'job_id': job_id}, function() {27 $("#job_details").tablesorter(); } );28 45 $('#job_details').show(); 29 46 } 30 47 31 48 function getHelp () { 49 $('#help').load('get_help'); 50 showHelp() 51 } 52 53 function showHelp () { 32 54 $('#jobs_table').hide(); 55 $('#navigator').hide(); 33 56 $('#server_details').hide(); 34 57 $('#job_details').hide(); 35 $('#help').load('get_help');36 58 $('#help').show(); 37 59 } … … 40 62 { 41 63 getJobs(count) // Run it the first time 42 setInterval('getJobs(count)', 5000); // Update it every 5 seconds. 64 showJobs() // Show jobs 65 // setInterval('getJobs(count)', 5000); // Update it every 5 seconds. 43 66 } 44 67 );
Note: See TracChangeset
for help on using the changeset viewer.
