Non puoi selezionare più di 25 argomenti
Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
35 righe
1.2 KiB
35 righe
1.2 KiB
<? |
|
$configPath = substr(__DIR__,0,strpos(__DIR__,"/public_html"))."/config.php"; |
|
include_once($configPath); |
|
$error = true; |
|
if (!empty($_SESSION["utente"]) && $_SESSION["utente"]->permission($radice) && !empty($_GET["tipologia"])) { |
|
$procedure = getProcedure(false,$_GET["tipologia"],null,(int) $_GET["beneficiario"] ?? null); |
|
if (!empty($procedure)) { |
|
$limitiCollaborazione = $_SESSION["utente"]->getCollaborazioneAttiva()["limiti"] ?? ""; |
|
$limitiCollaborazione = json_decode($limitiCollaborazione,true); |
|
|
|
$error = false; |
|
echo "<option value=''>" . __("Seleziona") . "...</option>" . PHP_EOL; |
|
foreach($procedure AS $key => $data) { |
|
$insert = true; |
|
if (!empty($limitiCollaborazione)) { |
|
foreach($limitiCollaborazione AS $procedura => $max) { |
|
if ($procedura == $key) { |
|
$insert = true; |
|
break; |
|
} else { |
|
$insert = false; |
|
} |
|
} |
|
} |
|
if ($insert) { |
|
echo "<option value='{$key}'>" . __($data["titolo"]) . "</option>" . PHP_EOL; |
|
} |
|
} |
|
} |
|
} |
|
if ($error) { |
|
header('HTTP/1.0 403 Forbidden'); |
|
die(); |
|
} |
|
?>
|