some minor test page code fixes

This commit is contained in:
Clemens Schwaighofer
2024-11-07 12:05:23 +09:00
parent 8613e8977b
commit d9bcb577d7
2 changed files with 19 additions and 21 deletions

View File

@@ -10,7 +10,7 @@ parameters:
# lineAfter: 3 # lineAfter: 3
level: 8 # max is now 9 level: 8 # max is now 9
# strictRules: # strictRules:
# allRules: true # allRules: false
checkMissingCallableSignature: true checkMissingCallableSignature: true
treatPhpDocTypesAsCertain: false treatPhpDocTypesAsCertain: false
paths: paths:

View File

@@ -134,7 +134,7 @@ print "<div>READ _ENV ARRAY:</div>";
print Support::dumpVar(array_map('htmlentities', $_ENV)); print Support::dumpVar(array_map('htmlentities', $_ENV));
// set + check edit access id // set + check edit access id
$edit_access_id = 3; $edit_access_id = 3;
if (is_object($login) && isset($login->loginGetAcl()['unit'])) { if (isset($login->loginGetAcl()['unit'])) {
print "ACL UNIT: " . print_r(array_keys($login->loginGetAcl()['unit']), true) . "<br>"; print "ACL UNIT: " . print_r(array_keys($login->loginGetAcl()['unit']), true) . "<br>";
print "ACCESS CHECK: " . (string)$login->loginCheckEditAccess($edit_access_id) . "<br>"; print "ACCESS CHECK: " . (string)$login->loginCheckEditAccess($edit_access_id) . "<br>";
if ($login->loginCheckEditAccess($edit_access_id)) { if ($login->loginCheckEditAccess($edit_access_id)) {
@@ -177,25 +177,23 @@ $log->debug('SOME MARK', 'Some error output');
// INTERNAL SET // INTERNAL SET
print "EDIT ACCESS ID: " . $backend->edit_access_id . "<br>"; print "EDIT ACCESS ID: " . $backend->edit_access_id . "<br>";
if (is_object($login)) { // print "ACL: <br>".$backend->print_ar($login->loginGetAcl())."<br>";
// print "ACL: <br>".$backend->print_ar($login->loginGetAcl())."<br>"; // $log->debug('ACL', "ACL: " . \CoreLibs\Debug\Support::dumpVar($login->loginGetAcl()));
// $log->debug('ACL', "ACL: " . \CoreLibs\Debug\Support::dumpVar($login->loginGetAcl())); // print "DEFAULT ACL: <br>".$backend->print_ar($login->default_acl_list)."<br>";
// print "DEFAULT ACL: <br>".$backend->print_ar($login->default_acl_list)."<br>"; // print "DEFAULT ACL: <br>".$backend->print_ar($login->default_acl_list)."<br>";
// print "DEFAULT ACL: <br>".$backend->print_ar($login->default_acl_list)."<br>"; // $result = array_flip(
// $result = array_flip( // array_filter(
// array_filter( // array_flip($login->default_acl_list),
// array_flip($login->default_acl_list), // function ($key) {
// function ($key) { // if (is_numeric($key)) {
// if (is_numeric($key)) { // return $key;
// return $key; // }
// } // }
// } // )
// ) // );
// ); // print "DEFAULT ACL: <br>".$backend->print_ar($result)."<br>";
// print "DEFAULT ACL: <br>".$backend->print_ar($result)."<br>"; // DEPRICATED CALL
// DEPRICATED CALL // $backend->adbSetACL($login->loginGetAcl());
// $backend->adbSetACL($login->loginGetAcl());
}
print "THIS HOST: " . HOST_NAME . ", with PROTOCOL: " . HOST_PROTOCOL . " is running SSL: " . HOST_SSL . "<br>"; print "THIS HOST: " . HOST_NAME . ", with PROTOCOL: " . HOST_PROTOCOL . " is running SSL: " . HOST_SSL . "<br>";
print "DIR: " . DIR . "<br>"; print "DIR: " . DIR . "<br>";