. */ include_once __DIR__.'/../../core.php'; use Models\PrintTemplate; use Models\Module; $id_files = $dbo->select('zz_files_print', 'id_file', [], ['id_print' => $id_record]); ?>

{[ "type": "text", "label": "", "name": "title", "required": 1, "value": "$title$" ]}
{[ "type": "text", "label": "", "name": "filename", "required": 1, "value": "$filename$" ]}
{[ "type": "select", "label": "", "name": "module", "required": 1, "values": "query=SELECT `zz_modules`.`id`, `name` AS descrizione FROM `zz_modules` LEFT JOIN `zz_modules_lang` ON (`zz_modules`.`id` = `zz_modules_lang`.`id_record` AND `zz_modules_lang`.`id_lang` = ) WHERE (`enabled` = 1 AND `options` != 'custom') OR `zz_modules`.`id` = ORDER BY `name` ASC", "value": "", "disabled": "1" ]}
{[ "type": "select", "multiple": "1", "label": "", "name": "id_files[]", "value": "", "ajax-source": "allegati", "select-options": $id_module, 'id_record' => $id_record]); ?>, "link": "allegato" ]}
{[ "type": "checkbox", "label": "", "name": "enabled", "value": "$enabled$", "disabled": "1" ]}
{[ "type": "number", "label": "", "name": "order", "required": 0, "value": "$order$", "decimals":0 ]}
where('id_module', $record['id_module']) ->orderBy('id') ->first(); if (!empty($stampa_predefinita)) { $nome_stampa_predefinita = $stampa_predefinita->name; } else { $nome_stampa_predefinita = 'Nessuna'; } ?>
{[ "type": "checkbox", "label": "", "help" : "", "name": "predefined", "value": "$predefined$", "disabled": "" ]}
'textarea', 'label' => tr('Opzioni'), 'name' => 'options', 'value' => $record['options'], 'help' => tr('Impostazioni personalizzabili della stampa, in formato JSON'), ]); ?>

'.tr('Opzioni').'

'; if (!empty($record['available_options'])) { $available_options = json_decode($record['available_options']); echo '

'.tr('Puoi utilizzare le seguenti opzioni per generare la stampa').':

'; } else { echo '

'.tr('Non sono state definite opzioni da utilizzare per la stampa').'.

'; } echo '
'; // Variabili utilizzabili $module = Module::find($record['id_module']); $variables = $module->getPlaceholders($id_record); echo '

'.tr('Variabili').'

'; if (!empty($variables)) { echo '

'.tr('Puoi utilizzare le seguenti variabili per generare il nome del file').':

'; } else { echo '

'.tr('Non sono state definite variabili da utilizzare nel template').'.

'; } echo '

{( "name": "filelist_and_upload", "id_module": "$id_module$", "id_record": "$id_record$" )}'; ?>