Bug #4337
closedcannot submit job, diffs in login.inc
0%
Description
We've been recently getting job submission errors after updating Appion. I've been able to pin some things down to differences in login.inc, as per diff trace below (also more clearly in repository between 0e65c028 and 260f023d). Anchi, it seems that you worked on this, can you point me in the right direction to figure out what the users now need to have?
dlyumkis@bpho-bladerunner-1 inc] diff login.inc ../../../myami-trunk-working/myamiweb/inc/
121,122c121
< function checkExptAccessPrivilege($sessionId,$privilege_type='data',$min_privilege_level=1) {
< // return true or redirect
---
function checkExptAccessPrivilege($sessionId,$privilege_type='data') {
134,146c133
< $r = hasExptAccessPrivilege($sessionId,$privilege_type, $min_privilege_level);
< if ( !$r ) {
< // arrives here if no view privilege
< redirect(BASE_URL.'accessdeny.php');
< exit;
< }
< return true;
< }
<
< function hasExptAccessPrivilege($sessionId,$privilege_type='data',$min_privilege_level=1) {
< // return true or false but not redirect
< //Access privilege of data means data viewing/downloading and processing result viewing are allowed
< $userId = getLoginUserId();
---
148,149d134
<
< // administrators
151,152c136
<
< if ($userId && $privilege_level >= $min_privilege_level) {
---
if ($userId && $privilege_level > 0) {
155d138
< // experiment shared to the user
161a145
if ((array)$r) return true;
163,164d146
<
< // project owner
178,180d159
< // arrives here if no privilege
< return false;
< }
182,186c161
< function checkExptAdminPrivilege($sessionId,$privilege_type='data') {
< // Admin privilege of data means data processing and session.comment editing is allowed
< // return true or redirect
< echo "checkingExptAdminPrivilege";
< if ( hasExptAdminPrivilege($sessionId,$privilege_type) ) return true;
---
// arrives here if no view privilege
191,193c166
< function hasExptAdminPrivilege($sessionId,$privilege_type='data') {
< // Admin privilege of data means data processing and session.comment editing is allowed
< // return true or false but not redirect
---
function checkExptAdminPrivilege($sessionId,$privilege_type='data') {
198,199c171,172
< // for other users,data processing is allowed if access is allowed and allow to administrate privilege_type.
< return hasExptAccessPrivilege($sessionId,$privilege_type='data', $min_privilege_level=2);
---
// for other users,data processing is allowed if access is allowed.
return checkExptAccessPrivilege($sessionId,$privilege_type='data');
Files