Compare commits

...

3 Commits

Author SHA1 Message Date
Pek5892 4eeeed12d8 Aggiunto avviso in caso di permessi assenti sui segmenti 2024-05-10 09:28:12 +02:00
Pek5892 50e3d73400 Aggiornamento rector.php 2024-05-10 09:27:42 +02:00
Pek5892 527b0c82e5 Fix minore 2024-05-10 09:27:25 +02:00
3 changed files with 12 additions and 2 deletions

View File

@ -35,6 +35,16 @@ include_once base_dir().'/actions.php';
// Widget in alto
echo '{( "name": "widgets", "id_module": "'.$id_module.'", "position": "top", "place": "controller" )}';
$segmenti = $dbo->FetchArray('SELECT `id` FROM `zz_segments` WHERE `id_module` = '.prepare($id_module));
if ($segmenti) {
$segmenti = Modules::getSegments($id_module);
if (empty($segmenti)) {
echo '<div class="alert alert-warning">
<i class="fa fa-warning-circle"></i> '.tr("Questo gruppo di utenti non ha i permessi per visualizzare nessun segmento di questo modulo").'.
</div>';
}
}
// Lettura eventuali plugins modulo da inserire come tab
echo '
<div class="nav-tabs-custom">

View File

@ -105,7 +105,7 @@ switch (post('op')) {
break;
}
$segment = $dbo->selectOne('zz_segments_lang', 'name', ['id_record' => $_SESSION['module_'.$id_module]['id_segment']])['name'];
$segment = $dbo->selectOne('zz_segments_lang', 'title', ['id_record' => $_SESSION['module_'.$id_module]['id_segment']])['name'];
if ($segment != 'Tutti') {
$operations['copy_listino'] = [

View File

@ -24,6 +24,6 @@ return static function (RectorConfig $rectorConfig): void {
// define sets of rules
$rectorConfig->sets([
LevelSetList::UP_TO_PHP_81,
LevelSetList::UP_TO_PHP_83,
]);
};