User_Schema class : removed tabs + commented code + organized structure, Delete listing of schema classes in process relation schema file

This commit is contained in:
Adnan
2010-07-02 16:31:32 +05:00
parent 1ef5f8564e
commit 188c7b8d38
5 changed files with 682 additions and 658 deletions

View File

@@ -20,20 +20,24 @@ $url_query .= '&goto=export_relation_schema.php';
require_once './libraries/db_info.inc.php';
/**
* Settings for relation stuff
* Includ settings for relation stuff
* get all variables needed for exporting relational schema
* in $cfgRelation
*/
require_once './libraries/relation.lib.php';
$cfgRelation = PMA_getRelationsParam();
// This is to avoid "Command out of sync" errors. Before switching this to
// a value of 0 (for MYSQLI_USE_RESULT), please check the logic
// to free results wherever needed.
/**
* This is to avoid "Command out of sync" errors. Before switching this to
* a value of 0 (for MYSQLI_USE_RESULT), please check the logic
* to free results wherever needed.
*/
$query_default_option = PMA_DBI_QUERY_STORE;
/**
* Now in ./libraries/relation.lib.php we check for all tables
* that we need, but if we don't find them we are quiet about it
* so people can work without.
* so people can't work without relational variables.
* This page is absolutely useless if you didn't set up your tables
* correctly, so it is a good place to see which tables we can and
* complain ;-)
@@ -63,46 +67,50 @@ if (!isset($cfgRelation['pdf_pages'])) {
if ($cfgRelation['pdfwork']) {
/**
* User Object Created for displaying the HTML options
* so, user can play with it and perform export of relations schema
*/
/**
* User object created for presenting the HTML options
* so, user can interact with it and perform export of relations schema
*/
require_once './libraries/schema/user_schema.php';
$user_schema = new PMA_User_Schema();
require_once './libraries/schema/User_Schema.class.php';
$user_schema = new PMA_User_Schema();
/**
* This function will process the user input
*
*/
$user_schema->userInputProcess($do);
/**
* Now first show some possibility to select a page for the export of relation schema
*/
$user_schema->selectPage();
/**
* Possibility to create a new page:
*/
$user_schema->createPage();
/**
* After selection of page or creating a page
* It will show you the list of tables
* A dashboard will also be shown where you can position the tables
*/
$user_schema->showTableDashBoard();
/**
* This function will process the user input
*/
$user_schema->processUserPreferences($do);
/**
* Now first show some possibility to select a page for the export of relation schema
*/
$user_schema->selectPage();
/**
* Possibility to create a new page:
*/
$user_schema->createPage();
/**
* After selection of page or creating a page
* It will show you the list of tables
* A dashboard will also be shown where you can position the tables
*/
$user_schema->showTableDashBoard();
if (isset($do)
&& ($do == 'edcoord'
|| ($do == 'selectpage' && isset($chpage))
|| ($do == 'createpage' && isset($chpage)))) {
/**
* show Export schema generation options
*/
|| ($do == 'selectpage' && isset($chpage) && $chpage != 0)
|| ($do == 'createpage' && isset($chpage) && $chpage != 0))) {
/**
* show Export schema generation options
*/
$user_schema->displaySchemaGenerationOptions();
if ((isset($showwysiwyg) && $showwysiwyg == '1')) {
?>
<script type="text/javascript">
@@ -110,8 +118,8 @@ if ($cfgRelation['pdfwork']) {
ToggleDragDrop('pdflayout');
//]]>
</script>
<?php
}
<?php
}
} // end if
} // end if ($cfgRelation['pdfwork'])