예제 #1
0
     $_POST['options']['overwrite'] = 0;
     $_POST['options']['create_dtos'] = !empty($_POST['options']['create_dtos']);
     $_POST['options']['create_paths'] = !empty($_POST['options']['create_paths']);
     $_POST['options']['generateAccessors'] = !empty($_POST['options']['generateAccessors']);
     $_POST['options']['create_entities_for_many_to_many'] = !empty($_POST['options']['create_entities_for_many_to_many']);
     // ajusta algumas configuracoes
     if ($_POST['options']['tipo_geracao'] == 1) {
         $_POST['options']['generate_files'] = 1;
         $_POST['options']['generate_zip'] = 0;
     } else {
         if ($_POST['options']['tipo_geracao'] == 2) {
             $_POST['options']['generate_files'] = 0;
             $_POST['options']['generate_zip'] = 1;
         }
     }
     Lumine_Log::setLevel(Lumine_Log::ERROR);
     $cfg = new Lumine_Reverse($_POST);
     $cfg->setTables($table_list);
     $cfg->start();
     if (!empty($_POST['addons'])) {
         Lumine_Log::debug('Executando add-ons');
         foreach ($_POST['addons'] as $classname) {
             foreach ($addons as $item) {
                 if (get_class($item) == $classname) {
                     $item->execute($_POST['class_path'] . '/lumine-conf.php', $_POST[strtolower($classname)]);
                 }
             }
         }
     }
     echo '<span style="color: #006600; font-weight: bold;">Engenharia reversa terminada!</span>';
 } catch (Exception $e) {