Changeset 880 for branches/1.0/web/addons/job_monarch/libtoga.php
- Timestamp:
- 05/18/13 18:25:10 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/1.0/web/addons/job_monarch/libtoga.php
r874 r880 211 211 } 212 212 213 function searchDbase( $id = null, $queue = null, $owner = null, $name = null, $start_from_time = null, $start_to_time = null, $end_from_time = null, $end_to_time = null )213 function searchDbase( $id = null, $queue = null, $owner = null, $name = null, $start_from_time = null, $start_to_time = null, $end_from_time = null, $end_to_time = null, $include_running = false ) 214 214 { 215 215 global $SEARCH_RESULT_LIMIT; 216 216 217 if( $include_running ) 218 { 219 $status_query = " AND job_status != 'Q'"; 220 } 221 else 222 { 223 $status_query = " AND job_status = 'F'"; 224 } 225 217 226 if( $id ) 218 227 { 219 $select_query = "SELECT job_id FROM jobs WHERE job_id = '$id' AND job_status = 'F'";228 $select_query = "SELECT job_id FROM jobs WHERE job_id = '$id'" . $status_query; 220 229 $this->resultcount = 1; 221 230 } … … 253 262 } 254 263 255 $query = "FROM jobs WHERE job_status = 'F' AND";264 $query = "FROM jobs WHERE "; 256 265 $extra_query_args = ''; 257 266 … … 267 276 } 268 277 } 269 $query .= $extra_query_args ;278 $query .= $extra_query_args . $status_query; 270 279 271 280 $count_result_idname = "COUNT(job_id)";
Note: See TracChangeset
for help on using the changeset viewer.