2004-11-14 00:42:02 +00:00
|
|
|
<?php
|
2008-08-05 22:43:14 +00:00
|
|
|
// This file is part of BOINC.
|
|
|
|
// http://boinc.berkeley.edu
|
|
|
|
// Copyright (C) 2008 University of California
|
|
|
|
//
|
|
|
|
// BOINC is free software; you can redistribute it and/or modify it
|
|
|
|
// under the terms of the GNU Lesser General Public License
|
|
|
|
// as published by the Free Software Foundation,
|
|
|
|
// either version 3 of the License, or (at your option) any later version.
|
|
|
|
//
|
|
|
|
// BOINC is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
// See the GNU Lesser General Public License for more details.
|
|
|
|
//
|
|
|
|
// You should have received a copy of the GNU Lesser General Public License
|
|
|
|
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
|
2004-11-14 00:42:02 +00:00
|
|
|
|
|
|
|
// cancel a WU:
|
|
|
|
// - mark unsent results as OVER, outcome DIDNT_NEED
|
|
|
|
// - set CANCELLED bit in WU error mask
|
|
|
|
//
|
|
|
|
|
|
|
|
require_once("../inc/db.inc");
|
2005-02-08 04:38:31 +00:00
|
|
|
require_once("../inc/util_ops.inc");
|
2004-11-14 00:42:02 +00:00
|
|
|
|
|
|
|
db_init();
|
|
|
|
|
2013-05-06 23:41:55 +00:00
|
|
|
$wuid1 = get_int('wuid1');
|
|
|
|
$wuid2 = get_int('wuid2');
|
2013-07-30 21:07:34 +00:00
|
|
|
$unsent_only = get_str('unsent_only', true);
|
2004-11-14 00:42:02 +00:00
|
|
|
|
|
|
|
if ($wuid1<1 || $wuid2<$wuid1) {
|
2014-10-29 19:25:35 +00:00
|
|
|
admin_error_page(
|
2013-07-30 21:07:34 +00:00
|
|
|
"<h2>Workunit IDs fail to satisfy the conditions:<p> 0 < ID1 <= ID2"
|
|
|
|
);
|
2004-11-14 00:42:02 +00:00
|
|
|
}
|
|
|
|
|
2013-07-30 21:07:34 +00:00
|
|
|
if ($unsent_only) {
|
|
|
|
cancel_wus_if_unsent($wuid1, $wuid2);
|
2004-11-14 17:49:16 +00:00
|
|
|
} else {
|
2013-07-30 21:07:34 +00:00
|
|
|
cancel_wus($wuid1, $wuid2);
|
2004-11-14 17:49:16 +00:00
|
|
|
}
|
2004-11-14 00:42:02 +00:00
|
|
|
|
2013-07-30 21:07:34 +00:00
|
|
|
admin_page_head("Cancel jobs");
|
|
|
|
echo " canceled jobs with $wuid1 <= workunit ID <= $wuid2</h2>";
|
2005-02-08 04:38:31 +00:00
|
|
|
admin_page_tail();
|
2013-07-30 21:07:34 +00:00
|
|
|
|
2008-08-05 22:43:14 +00:00
|
|
|
$cvs_version_tracker[]="\$Id$"; //Generated automatically - do not edit
|
2004-11-14 00:42:02 +00:00
|
|
|
?>
|