@@ -646,13 +646,6 @@ if ($cfgRelation['pdfwork'] && $num_tables > 0) { ?>
|
|||||||
.' alt="" width="16" height="16" />';
|
.' alt="" width="16" height="16" />';
|
||||||
}
|
}
|
||||||
echo __('Edit PDF Pages') . '</a></fieldset>';
|
echo __('Edit PDF Pages') . '</a></fieldset>';
|
||||||
// Export Relational Schema View
|
|
||||||
echo '<fieldset><a href="export_relation_schema.php?' . $url_query . '">';
|
|
||||||
if ($cfg['PropertiesIconic']) {
|
|
||||||
echo '<img class="icon" src="' . $pmaThemeImage . 'b_edit.png"'
|
|
||||||
.' alt="" width="16" height="16" />';
|
|
||||||
}
|
|
||||||
echo __('Export Relational Schema View') . '</a></fieldset>';
|
|
||||||
} // end if
|
} // end if
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -1434,14 +1434,8 @@ function refreshDragOption(e) {
|
|||||||
function refreshLayout() {
|
function refreshLayout() {
|
||||||
var elm = $('#pdflayout')
|
var elm = $('#pdflayout')
|
||||||
var orientation = $('#orientation_opt').val();
|
var orientation = $('#orientation_opt').val();
|
||||||
if($('#paper_opt').length==1)
|
var paper = $('#paper_opt').val();
|
||||||
{
|
|
||||||
var paper = $('#paper_opt').val();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
var paper = 'A4';
|
|
||||||
}
|
|
||||||
if (orientation == 'P') {
|
if (orientation == 'P') {
|
||||||
posa = 'x';
|
posa = 'x';
|
||||||
posb = 'y';
|
posb = 'y';
|
||||||
@@ -1731,24 +1725,5 @@ $(document).ready(function(){
|
|||||||
insertQuery(evt.target.id);
|
insertQuery(evt.target.id);
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
$("#export_type").change(function(){
|
|
||||||
|
|
||||||
if($("#export_type").val()!='pdf')
|
|
||||||
{
|
|
||||||
$("#show_grid_opt").attr("disabled","disabled");
|
|
||||||
$("#orientation_opt").attr("disabled","disabled");
|
|
||||||
$("#with_doc").attr("disabled","disabled");
|
|
||||||
$(this).css("background-color","yellow");
|
|
||||||
|
|
||||||
}
|
|
||||||
if($("#export_type").val()=='pdf')
|
|
||||||
{
|
|
||||||
$("#show_grid_opt").removeAttr("disabled");
|
|
||||||
$("#orientation_opt").removeAttr("disabled");
|
|
||||||
$("#with_doc").removeAttr("disabled","disabled");
|
|
||||||
}
|
|
||||||
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@@ -589,7 +589,7 @@ $cfg['LoginCookieRecall'] = true;
|
|||||||
*
|
*
|
||||||
* @global integer $cfg['LoginCookieValidity']
|
* @global integer $cfg['LoginCookieValidity']
|
||||||
*/
|
*/
|
||||||
$cfg['LoginCookieValidity'] = 99440;
|
$cfg['LoginCookieValidity'] = 1440;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* how long login cookie should be stored (in seconds)
|
* how long login cookie should be stored (in seconds)
|
||||||
|
7
libraries/schema/diaSchema.class.php
Normal file
7
libraries/schema/diaSchema.class.php
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?php
|
||||||
|
include_once("relationSchema.abstract.class.php");
|
||||||
|
class diaSchema extends exportRelationSchema
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
7
libraries/schema/epsSchema.class.php
Normal file
7
libraries/schema/epsSchema.class.php
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?php
|
||||||
|
include_once("relationSchema.abstract.class.php");
|
||||||
|
class epsSchema extends exportRelationSchema
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
9
libraries/schema/pdfSchema.class.php
Normal file
9
libraries/schema/pdfSchema.class.php
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
<?php
|
||||||
|
include_once("relationSchema.abstract.class.php");
|
||||||
|
class pdfSchema extends exportRelationSchema
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
$pdf= new pdfSchema();
|
||||||
|
$pdf->createPageHTML();
|
||||||
|
?>
|
53
libraries/schema/relationSchema.abstract.class.php
Normal file
53
libraries/schema/relationSchema.abstract.class.php
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
<?php
|
||||||
|
// Using Abstract Factory Pattern for exporting relational Schema in different Formats !
|
||||||
|
abstract class exportRelationSchema
|
||||||
|
{
|
||||||
|
private $pageTitle; // Title of the page
|
||||||
|
private $autoLayoutType; // Internal or Foreign Key Relations;
|
||||||
|
|
||||||
|
public function setPageTitle($title)
|
||||||
|
{
|
||||||
|
$this->pageTitle=$title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function createPage()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
public function createPageHTML()
|
||||||
|
{
|
||||||
|
?>
|
||||||
|
<form method="post" action="pdf_pages.php" name="crpage">
|
||||||
|
<fieldset>
|
||||||
|
<legend>
|
||||||
|
<?php echo __('Create a page') . "\n"; ?>
|
||||||
|
</legend>
|
||||||
|
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||||
|
<input type="hidden" name="do" value="createpage" />
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<td><label for="id_newpage"><?php echo __('Page name'); ?></label></td>
|
||||||
|
<td><input type="text" name="newpage" id="id_newpage" size="20" maxlength="50" /></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td><?php echo __('Automatic layout based on'); ?></td>
|
||||||
|
<td>
|
||||||
|
<input type="checkbox" name="auto_layout_internal" id="id_auto_layout_internal" /><label for="id_auto_layout_internal"><?php echo __('Internal relations'); ?></label><br />
|
||||||
|
<?php
|
||||||
|
if (PMA_StorageEngine::isValid('InnoDB') || PMA_StorageEngine::isValid('PBXT')) {
|
||||||
|
?>
|
||||||
|
<input type="checkbox" name="auto_layout_foreign" id="id_auto_layout_foreign" /><label for="id_auto_layout_foreign">FOREIGN KEY</label><br />
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</td></tr>
|
||||||
|
</table>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset class="tblFooters">
|
||||||
|
<input type="submit" value="<?php echo __('Go'); ?>" />
|
||||||
|
</fieldset>
|
||||||
|
</form>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
7
libraries/schema/svgSchema.class.php
Normal file
7
libraries/schema/svgSchema.class.php
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?php
|
||||||
|
include_once("relationSchema.abstract.class.php");
|
||||||
|
class svgSchema extends exportRelationSchema
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
7
libraries/schema/visioSchema.class.php
Normal file
7
libraries/schema/visioSchema.class.php
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?php
|
||||||
|
include_once("relationSchema.abstract.class.php");
|
||||||
|
class visioSchema extends exportRelationSchema
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
Reference in New Issue
Block a user