* * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ /** * \file htdocs/exports/index.php * \ingroup export * \brief Home page of export wizard */ require_once '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/exports/class/export.class.php'; $langs->load("exports"); // Security check $result=restrictedArea($user,'export'); $export=new Export($db); $export->load_arrays($user); /* * View */ $form=new Form($db); llxHeader('',$langs->trans("ExportsArea"),'EN:Module_Exports_En|FR:Module_Exports|ES:Módulo_Exportaciones'); print_fiche_titre($langs->trans("ExportsArea")); print $langs->trans("FormatedExportDesc1").'
'; print $langs->trans("FormatedExportDesc2").' '; print $langs->trans("FormatedExportDesc3").'
'; print '
'; print '
'; // List export set print ''; print ''; print ''; print ''; //print ''; print ''; $var=true; if (count($export->array_export_code)) { foreach ($export->array_export_code as $key => $value) { $var=!$var; print ''; // print ''; print ''; } } else { print ''; } print '
'.$langs->trans("Module").''.$langs->trans("ExportableDatas").' 
'; //print img_object($export->array_export_module[$key]->getName(),$export->array_export_module[$key]->picto).' '; print $export->array_export_module[$key]->getName(); print ''; print img_object($export->array_export_module[$key]->getName(),$export->array_export_icon[$key]).' '; $string=$langs->trans($export->array_export_label[$key]); print ($string!=$export->array_export_label[$key]?$string:$export->array_export_label[$key]); print ''; // print ''.img_picto($langs->trans("NewExport"),'filenew').''; // print '
'.$langs->trans("NoExportableData").'
'; print '
'; print '
'; if (count($export->array_export_code)) { if ($user->rights->export->creer) { print ''.$langs->trans("NewExport").''; } else { print ''.$langs->trans("NewExport").''; } /* print '
rights->export->creer?'':' disabled'); print '>
'; */ } print '
'; print '
'; print '
'; // List of available export format $var=true; print ''; print ''; print ''; print ''; print ''; print ''; include_once DOL_DOCUMENT_ROOT.'/core/modules/export/modules_export.php'; $model=new ModeleExports(); $liste=$model->liste_modeles($db); // This is not a static method for exports because method load non static properties $var=true; foreach($liste as $key => $val) { if (preg_match('/__\(Disabled\)__/',$liste[$key])) { $liste[$key]=preg_replace('/__\(Disabled\)__/','('.$langs->transnoentitiesnoconv("Disabled").')',$liste[$key]); } $var=!$var; print ''; print ''; $text=$model->getDriverDescForKey($key); $label=$liste[$key]; print ''; print ''; print ''; print ''; } print '
'.$langs->trans("AvailableFormats").''.$langs->trans("LibraryShort").''.$langs->trans("LibraryVersion").'
'.img_picto_common($model->getDriverLabelForKey($key),$model->getPictoForKey($key)).''.$form->textwithpicto($label,$text).''.$model->getLibLabelForKey($key).''.$model->getLibVersionForKey($key).'
'; print '
'; llxFooter(); $db->close();