mirror of https://github.com/BOINC/boinc.git
- web: when sending emails to other users, don't translate anything
(since they don't necessarily speak our language) svn path=/trunk/boinc/; revision=23948
This commit is contained in:
parent
578d5f924f
commit
12f7c6e04e
|
@ -4712,3 +4712,14 @@ David 7 Aug 2011
|
|||
html/user/
|
||||
submit_example.php
|
||||
submit.php
|
||||
|
||||
David 7 Aug 2011
|
||||
- web: when sending emails to other users, don't translate anything
|
||||
(since they don't necessarily speak our language)
|
||||
|
||||
html/
|
||||
ops/
|
||||
index.php
|
||||
inc/
|
||||
pm.inc
|
||||
submit.inc
|
||||
|
|
|
@ -112,7 +112,7 @@ To change email preferences, visit:
|
|||
".URL_BASE."edit_forum_preferences_form.php
|
||||
Do not reply to this message.
|
||||
" ;
|
||||
send_email($to_user, "[".PROJECT."] ".tra("- private message"), $message);
|
||||
send_email($to_user, "[".PROJECT."] - private message", $message);
|
||||
}
|
||||
|
||||
function pm_email_line($notify) {
|
||||
|
|
|
@ -16,7 +16,17 @@
|
|||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
// remote job submission API
|
||||
// Remote job submission API.
|
||||
// Functions:
|
||||
// boinc_estimate_batch(); esimate completion time of a batch of jobs
|
||||
// boinc_submit_batch(): submit a batch
|
||||
// boinc_query_batches(): get list of batches
|
||||
// boinc_query_batch(): get detaills of a batch
|
||||
// boinc_query_job(): get details of a job
|
||||
// boinc_abort_batch(): abort a batch
|
||||
// boinc_get_output_file(): get the URL for an output file
|
||||
// boinc_get_output_files(): get the URL for zipped batch output
|
||||
// boinc_retire_batch(): retire a batch; delete output files
|
||||
|
||||
//// Implementation stuff follows
|
||||
|
||||
|
@ -79,7 +89,35 @@ function do_batch_op($req, $op) {
|
|||
return do_http_op($req->project, $xml);
|
||||
}
|
||||
|
||||
//// Interface functions follow
|
||||
function batch_xml_to_object($batch) {
|
||||
$b = null;
|
||||
$b->id = (int)($batch->id);
|
||||
$b->create_time = (double)($batch->create_time);
|
||||
$b->est_completion_time = (double)($batch->est_completion_time);
|
||||
$b->njobs = (int)($batch->njobs);
|
||||
$b->fraction_done = (double) $batch->fraction_done;
|
||||
$b->nerror_jobs = (int)($batch->nerror_jobs);
|
||||
$b->state = (int)($batch->state);
|
||||
$b->completion_time = (double)($batch->completion_time);
|
||||
$b->credit_estimate = (double)($batch->credit_estimate);
|
||||
$b->credit_canonical = (double)($batch->credit_canonical);
|
||||
$b->name = (string)($batch->name);
|
||||
$b->app_name = (string)($batch->app_name);
|
||||
return $b;
|
||||
}
|
||||
|
||||
function batch_state_string($state) {
|
||||
switch ($state) {
|
||||
case BATCH_STATE_INIT: return "new";
|
||||
case BATCH_STATE_IN_PROGRESS: return "in progress";
|
||||
case BATCH_STATE_COMPLETE: return "completed";
|
||||
case BATCH_STATE_ABORTED: return "aborted";
|
||||
case BATCH_STATE_RETIRED: return "retired";
|
||||
}
|
||||
return "unknown state $state";
|
||||
}
|
||||
|
||||
//// API functions follow
|
||||
|
||||
function boinc_estimate_batch($req) {
|
||||
list($reply, $errmsg) = do_batch_op($req, "estimate_batch");
|
||||
|
@ -107,23 +145,6 @@ function boinc_submit_batch($req) {
|
|||
}
|
||||
}
|
||||
|
||||
function batch_xml_to_object($batch) {
|
||||
$b = null;
|
||||
$b->id = (int)($batch->id);
|
||||
$b->create_time = (double)($batch->create_time);
|
||||
$b->est_completion_time = (double)($batch->est_completion_time);
|
||||
$b->njobs = (int)($batch->njobs);
|
||||
$b->fraction_done = (double) $batch->fraction_done;
|
||||
$b->nerror_jobs = (int)($batch->nerror_jobs);
|
||||
$b->state = (int)($batch->state);
|
||||
$b->completion_time = (double)($batch->completion_time);
|
||||
$b->credit_estimate = (double)($batch->credit_estimate);
|
||||
$b->credit_canonical = (double)($batch->credit_canonical);
|
||||
$b->name = (string)($batch->name);
|
||||
$b->app_name = (string)($batch->app_name);
|
||||
return $b;
|
||||
}
|
||||
|
||||
function boinc_query_batches($req) {
|
||||
$req_xml = "<query_batches>
|
||||
<authenticator>$req->authenticator</authenticator>
|
||||
|
@ -229,17 +250,6 @@ function boinc_retire_batch($req) {
|
|||
return null;
|
||||
}
|
||||
|
||||
function batch_state_string($state) {
|
||||
switch ($state) {
|
||||
case BATCH_STATE_INIT: return "new";
|
||||
case BATCH_STATE_IN_PROGRESS: return "in progress";
|
||||
case BATCH_STATE_COMPLETE: return "completed";
|
||||
case BATCH_STATE_ABORTED: return "aborted";
|
||||
case BATCH_STATE_RETIRED: return "retired";
|
||||
}
|
||||
return "unknown state $state";
|
||||
}
|
||||
|
||||
//// example usage follows
|
||||
|
||||
$req->project = "http://isaac.ssl.berkeley.edu/test/";
|
||||
|
|
|
@ -151,6 +151,7 @@ echo "
|
|||
<ul>
|
||||
<li><a href=\"profile_screen_form.php\">Screen user profiles </a></li>
|
||||
<li><a href=\"manage_special_users.php\">User privileges</a></li>
|
||||
<li><a href=submit_permissions.php>User job submission privileges</a></li>
|
||||
<li><a href=\"mass_email.php\">Send mass email to a selected set of users</a></li>
|
||||
<li><a href=\"problem_host.php\">Email user with misconfigured host</a></li>
|
||||
<li><form action=\"manage_user.php\">
|
||||
|
|
Loading…
Reference in New Issue