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.
67 righe
3.0 KiB
67 righe
3.0 KiB
<? |
|
$error = true; |
|
$configPath = substr(__DIR__,0,strpos(__DIR__,"/public_html"))."/config.php"; |
|
include_once($configPath); |
|
$id_modulo = "partecipanti"; |
|
$cmd_info = AlboFornitori::getInfoModulo($id_modulo); |
|
$operazioni = ["ammetti","respingi"]; |
|
if (!empty($_SESSION["utente"]) && $_SESSION["utente"]->permission($cmd_info["modulo_riferimento"]) && $_SESSION["utente"]->permission($radice,$_GET["codice"],$id_modulo) && !empty($_GET["operazione"]) && in_array($_GET["operazione"],$operazioni)) { |
|
$elenco = AlboFornitori::init($_GET["codice"]); |
|
$operazione = purify($_GET["operazione"]); |
|
$ammissione = false; |
|
$color = "danger"; |
|
$label = "Escludi"; |
|
if ($operazione == "ammetti") { |
|
$label = "Ammetti"; |
|
$color = "success"; |
|
$ammissione = true; |
|
} |
|
if (!empty($elenco)) { |
|
if (settingsManager::getValue("esitoCumulativoAlbi") == "S") { |
|
$istanze = $elenco->getIstanzeAffini($_GET["codice_operatore"]); |
|
$istanzaBase = $elenco->getPartecipante($_GET["codice_partecipante"]); |
|
if (!empty($istanze) && !empty($istanzaBase)) { |
|
$error = false; |
|
?> |
|
<form rel="validate" method="post" id="cumulativa-form" action="save-cumulativa.php"> |
|
<input type="hidden" name="codice" value="<?= $elenco->info["codice"] ?>"> |
|
<input type="hidden" name="codice_partecipante" value="<?= $istanzaBase["codice"] ?>"> |
|
<input type="hidden" name="codice_operatore" value="<?= $istanzaBase["codice_operatore"] ?>"> |
|
<input type="hidden" name="operazione" value="<?= $operazione ?>"> |
|
<table class="table table-striped table-hover"> |
|
<thead> |
|
<tr> |
|
<th><?= __("Elenco") ?></th> |
|
<th><?= __("Ultimo aggiornamento") ?> |
|
<th width="10"></th> |
|
</tr> |
|
</thead> |
|
<tbody> |
|
<? |
|
foreach($istanze AS $istanza) { |
|
?> |
|
<tr> |
|
<td><?= $istanza["oggetto"] ?></td> |
|
<td><?= mysql2datetime($istanza["timestamp"]) ?></td> |
|
<td><input type="checkbox" checked name="istanza[]" value="<?= $istanza["codice"] ?>"> |
|
</tr> |
|
<? |
|
} |
|
?> |
|
</tbody> |
|
</table> |
|
<? if (!$ammissione) { ?> |
|
<textarea id="motivazione" class="form-control" rows="10" name="motivazione" title="<?= __("motivazione") ?>" rel="S;2;0;A"><?= $msg ?? "" ?></textarea> |
|
<? } ?> |
|
<button type="button" onclick="confirmBeforeSubmitForm('<?= __("Il sistema genererà una comunicazione automatica per informare del risultato della valutazione") ?>','cumulativa-form')" class="btn btn-block btn-<?= $color ?>"><?= __($label) ?></button> |
|
</form> |
|
<? |
|
} |
|
} |
|
} |
|
} |
|
if ($error) { |
|
header('HTTP/1.0 403 Forbidden'); |
|
die(); |
|
} |
|
?>
|
|
|