html/inc/submit_util.inc 1 location
|
@@ 41-46 (lines=6) @@
|
| 38 |
|
if (!$user) xml_error(-1, "bad authenticator"); |
| 39 |
|
$user_submit = BoincUserSubmit::lookup_userid($user->id); |
| 40 |
|
if (!$user_submit) xml_error(-1, "no submit access"); |
| 41 |
|
if ($app && !$user_submit->submit_all) { |
| 42 |
|
$usa = BoincUserSubmitApp::lookup("user_id=$user->id and app_id=$app->id"); |
| 43 |
|
if (!$usa) { |
| 44 |
|
xml_error(-1, "no submit access"); |
| 45 |
|
} |
| 46 |
|
} |
| 47 |
|
return array($user, $user_submit); |
| 48 |
|
} |
| 49 |
|
|
html/user/lammps.php 1 location
|
@@ 476-481 (lines=6) @@
|
| 473 |
|
$app = BoincApp::lookup("name='lammps'"); |
| 474 |
|
if (!$app) error_page("no lammps app"); |
| 475 |
|
|
| 476 |
|
if (!$user_submit->submit_all) { |
| 477 |
|
$usa = BoincUserSubmitApp::lookup("user_id=$user->id and app_id=$app->id"); |
| 478 |
|
if (!$usa) { |
| 479 |
|
error_page("no submit access"); |
| 480 |
|
} |
| 481 |
|
} |
| 482 |
|
|
| 483 |
|
$action = get_str('action', true); |
| 484 |
|
switch ($action) { |
html/user/tree_threader.php 1 location
|
@@ 168-173 (lines=6) @@
|
| 165 |
|
$app = BoincApp::lookup("name='$app_name'"); |
| 166 |
|
if (!$app) error("no tree_threader app"); |
| 167 |
|
|
| 168 |
|
if (!$user_submit->submit_all) { |
| 169 |
|
$usa = BoincUserSubmitApp::lookup("user_id=$user->id and app_id=$app->id"); |
| 170 |
|
if (!$usa) { |
| 171 |
|
error("no submit access"); |
| 172 |
|
} |
| 173 |
|
} |
| 174 |
|
|
| 175 |
|
switch ((string)$r->action) { |
| 176 |
|
case 'submit': |