. */ use HTMLBuilder\HTMLBuilder; use Models\Module; use Models\Plugin; include_once __DIR__.'/../core.php'; // Compatibilità per controller ed editor if (!empty($id_plugin)) { $structure = Plugin::find($id_plugin); } else { $structure = Module::find($id_module); } if (!empty($id_plugin)) { // Inclusione di eventuale plugin personalizzato if (!empty($structure['script'])) { $path = $structure->getEditFile(); if (!empty($path)) { include $path; } return; } echo '
'; foreach ($total['fields'] as $key => $field) { $attr_td = ''; $name = trim((string) $field); // Check per tipologie di campi particolari if (preg_match('/^color_/', (string) $field)) { $attr_td .= " width='140'"; $field = str_replace('color_', '', $field); } // Data (larghezza fissa) elseif (preg_match('/^Data/', (string) $field)) { $attr_td .= " width='100'"; } // Icona di stampa elseif (trim((string) $field) == '_print_') { $attr_td .= " width='30'"; $field = str_replace('_print_', '', $field); } elseif (preg_match('/^icon_/', (string) $field)) { $attr_td .= " width='30'"; $name = str_replace('icon_', 'icon_title_', $name); $field = str_replace('icon_', '', $field); } if (isMobile()) { $attr_td .= " style='min-width:100px;'"; } echo ' | '.$field.' | '; } echo '
---|---|
'; foreach ($total['fields'] as $key => $field) { echo ' | '; } echo ' |