diff options
author | terminaldweller <thabogre@gmail.com> | 2022-07-21 05:36:02 +0000 |
---|---|---|
committer | terminaldweller <thabogre@gmail.com> | 2022-07-21 05:36:02 +0000 |
commit | 85db7c5287ae58efc108263f7a40bdbd02de1a82 (patch) | |
tree | 8292d90db8999dabc2e3872ea75547cb7fcf0c2d /dbdocs/routines | |
parent | changed the max doc size to 40K characters.255 was not enough... (diff) | |
download | mdrtl-85db7c5287ae58efc108263f7a40bdbd02de1a82.tar.gz mdrtl-85db7c5287ae58efc108263f7a40bdbd02de1a82.zip |
added docs for the db using schemaspy
Diffstat (limited to '')
-rw-r--r-- | dbdocs/routines.html | 158 | ||||
-rw-r--r-- | dbdocs/routines.js | 70 | ||||
-rw-r--r-- | dbdocs/routines/routine.js | 34 |
3 files changed, 262 insertions, 0 deletions
diff --git a/dbdocs/routines.html b/dbdocs/routines.html new file mode 100644 index 0000000..0ded7ea --- /dev/null +++ b/dbdocs/routines.html @@ -0,0 +1,158 @@ +<!DOCTYPE html> +<html> + <head> + <meta charset="utf-8"> + <meta http-equiv="X-UA-Compatible" content="IE=edge"> + <title>spring Database</title> + <!-- Tell the browser to be responsive to screen width --> + <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport"> + <link rel="icon" type="image/png" sizes="16x16" href="favicon.png"> + <!-- Bootstrap 3.3.5 --> + <link rel="stylesheet" href="bower/admin-lte/bootstrap/css/bootstrap.min.css"> + <!-- Font Awesome --> + <link rel="stylesheet" href="bower/font-awesome/css/font-awesome.min.css"> + <!-- Ionicons --> + <link rel="stylesheet" href="bower/ionicons/css/ionicons.min.css"> + <!-- DataTables --> + <link rel="stylesheet" href="bower/datatables.net-bs/css/dataTables.bootstrap.min.css"> + <link rel="stylesheet" href="bower/datatables.net-buttons-bs/css/buttons.bootstrap.min.css"> + <!-- Code Mirror --> + <link rel="stylesheet" href="bower/codemirror/codemirror.css"> + <!-- Fonts --> + <link href='fonts/indieflower/indie-flower.css' rel='stylesheet' type='text/css'> + <link href='fonts/source-sans-pro/source-sans-pro.css' rel='stylesheet' type='text/css'> + + <!-- Theme style --> + <link rel="stylesheet" href="bower/admin-lte/dist/css/AdminLTE.min.css"> + <!-- Salvattore --> + <link rel="stylesheet" href="bower/salvattore/salvattore.css"> + <!-- AdminLTE Skins. Choose a skin from the css/skins + folder instead of downloading all of them to reduce the load. --> + <link rel="stylesheet" href="bower/admin-lte/dist/css/skins/_all-skins.min.css"> + <!-- SchemaSpy --> + <link rel="stylesheet" href="schemaSpy.css"> + + <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> + <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> + <!--[if lt IE 9]> + <script src="bower/html5shiv/html5shiv.min.js"></script> + <script src="bower/respond/respond.min.js"></script> + <![endif]--> + </head> + <!-- ADD THE CLASS layout-top-nav TO REMOVE THE SIDEBAR. --> + <body class="hold-transition skin-blue layout-top-nav"> + <div class="wrapper"> + <header class="main-header"> + <nav class="navbar navbar-static-top"> + <div class="container"> + <div class="navbar-header"> + <a href="index.html" class="navbar-brand"><b>spring</b> Database</a> + <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar-collapse"><i class="fa fa-bars"></i></button> + </div> + + <!-- Collect the nav links, forms, and other content for toggling --> + <div class="collapse navbar-collapse pull-left" id="navbar-collapse"> + <ul class="nav navbar-nav"> + <li><a href="index.html">Tables <span class="sr-only">(current)</span></a></li> + <li><a href="columns.html" title="All of the columns in the schema">Columns</a></li> + <li><a href="constraints.html" title="Useful for diagnosing error messages that just give constraint name or number">Constraints</a></li> + <li><a href="relationships.html" title="Diagram of table relationships">Relationships</a></li> + <li><a href="orphans.html" title="View of tables with neither parents nor children">Orphan Tables</a></li> + <li><a href="anomalies.html" title="Things that might not be quite right">Anomalies</a></li> + <li><a href="routines.html" title="Procedures and functions">Routines</a></li> + </ul> + </div> + <!-- /.navbar-collapse --> + <!-- Navbar Right Menu --> + </div> + <!-- /.container-fluid --> + </nav> + </header> + <!-- Main content --> + <!-- Full Width Column --> + <div class="content-wrapper"> + <!-- Content Header (Page header) --> + <section class="content-header"> + <h1>Routines</h1> + </section> + <!-- Main content --> + <section class="content"> + <div class="box box-primary"> + <div class="box-header with-border"> + <i class="fa fa-file-code-o" aria-hidden="true"></i> + <h3 class="box-title">Routines</h3> + </div> + <div class="box-body"> + <table id="routine_table" class="table table-bordered table-striped dataTable" role="grid"> + <thead align='left'> + <tr> + <th>Name</th> + <th>Type</th> + <th>Language</th> + <th>Deterministic</th> + <th>Return Type</th> + <th>Security Restriction</th> + <th title='Comments' class="toggle"><span>Comments</span></th> + </tr> + </thead> + <tbody> + </tbody> + </table> + </div> + </div> + </section> + <script> + var config = { + pagination: true + } + </script> + </div> + <!-- /.content-wrapper --> + <footer class="main-footer"> + <div> + <div class="pull-right hidden-xs"> + <a href="https://github.com/schemaspy/schemaspy" title="GitHub for SchemaSpy"><i class="fa fa-github-square fa-2x"></i></a> + <a href="http://stackoverflow.com/questions/tagged/schemaspy" title="StackOverflow for SchemaSpy"><i class="fa fa-stack-overflow fa-2x"></i></a> + </div> + <strong>Generated by <a href="http://schemaspy.org/" class="logo-text"><i class="fa fa-database"></i> SchemaSpy 6.1.0</a></strong> + </div> + <!-- /.container --> + </footer> + </div> + <!-- ./wrapper --> + + <!-- jQuery 2.2.3 --> + <script src="bower/admin-lte/plugins/jQuery/jquery-2.2.3.min.js"></script> + <script src="bower/admin-lte/plugins/jQueryUI/jquery-ui.min.js"></script> + <!-- Bootstrap 3.3.5 --> + <script src="bower/admin-lte/bootstrap/js/bootstrap.min.js"></script> + <!-- DataTables --> + <script src="bower/datatables.net/jquery.dataTables.min.js"></script> + <script src="bower/datatables.net-bs/js/dataTables.bootstrap.min.js"></script> + <script src="bower/datatables.net-buttons/dataTables.buttons.min.js"></script> + <script src="bower/datatables.net-buttons-bs/js/buttons.bootstrap.min.js"></script> + <script src="bower/datatables.net-buttons/buttons.html5.min.js"></script> + <script src="bower/datatables.net-buttons/buttons.print.min.js"></script> + <script src="bower/datatables.net-buttons/buttons.colVis.min.js"></script> + <!-- SheetJS --> + <script src="bower/js-xlsx/xlsx.full.min.js"></script> + <!-- pdfmake --> + <script src="bower/pdfmake/pdfmake.min.js"></script> + <script src="bower/pdfmake/vfs_fonts.js"></script> + <!-- SlimScroll --> + <script src="bower/admin-lte/plugins/slimScroll/jquery.slimscroll.min.js"></script> + <!-- FastClick --> + <script src="bower/admin-lte/plugins/fastclick/fastclick.js"></script> + <!-- Salvattore --> + <script src="bower/salvattore/salvattore.min.js"></script> + <!-- AnchorJS --> + <script src="bower/anchor-js/anchor.min.js"></script> + <!-- CodeMirror --> + <script src="bower/codemirror/codemirror.js"></script> + <script src="bower/codemirror/sql.js"></script> + <!-- AdminLTE App --> + <script src="bower/admin-lte/dist/js/app.min.js"></script> + <script src="routines.js"></script> + <script src="schemaSpy.js"></script> + </body> +</html>
\ No newline at end of file diff --git a/dbdocs/routines.js b/dbdocs/routines.js new file mode 100644 index 0000000..cdc2350 --- /dev/null +++ b/dbdocs/routines.js @@ -0,0 +1,70 @@ +var filterBy = function(functionType) { + $.fn.dataTableExt.afnFiltering.length = 0; + $.fn.dataTable.ext.search.push( + function( settings, data, dataIndex ) { + var type = data[1]; // use data for the Type column + + if ( type.toUpperCase() == functionType || functionType == 'All' ) + { + return true; + } + return false; + } + ); +} + +$(document).ready(function() { + var activeObject; + var table = $('#routine_table').DataTable( { + lengthChange: false, + ordering: true, + paging: config.pagination, + pageLength: 50, + autoWidth: true, + processing: true, + order: [[ 0, "asc" ]], + buttons: [ + { + text: 'All', + action: function ( e, dt, node, config ) { + filterBy('All'); + if (activeObject != null) { + activeObject.active(false); + } + table.draw(); + } + }, + { + text: 'Functions', + action: function ( e, dt, node, config ) { + filterBy('FUNCTION'); + if (activeObject != null) { + activeObject.active(false); + } + this.active( !this.active() ); + activeObject = this; + table.draw(); + } + }, + { + text: 'Procedures', + action: function ( e, dt, node, config ) { + filterBy('PROCEDURE'); + if (activeObject != null) { + activeObject.active(false); + } + this.active( !this.active() ); + activeObject = this; + table.draw(); + } + }, + { + extend: 'columnsToggle', + columns: '.toggle' + } + ] + } ); + + //schemaSpy.js + dataTableExportButtons(table); +} ); diff --git a/dbdocs/routines/routine.js b/dbdocs/routines/routine.js new file mode 100644 index 0000000..efd2b21 --- /dev/null +++ b/dbdocs/routines/routine.js @@ -0,0 +1,34 @@ +function enableAnchors() { + anchors.options.visible = 'always'; + anchors.add('h3'); +} + +$(document).ready(function() { + enableAnchors(); + + var table = $('#standard_table').DataTable( { + lengthChange: false, + bSort: false, + bPaginate: false, + autoWidth: true, + buttons: [ ] + } ); + + table.buttons().container() + .appendTo('#standard_table_wrapper .col-sm-6:eq(0)' ); +} ); + +var codeElement = document.getElementById("sql-script-codemirror"); +var editor = null; +if (null != codeElement) { + editor = CodeMirror.fromTextArea(codeElement, { + lineNumbers: true, + mode: 'text/x-sql', + indentWithTabs: true, + smartIndent: true, + lineNumbers: true, + matchBrackets: true, + autofocus: true, + readOnly: true + }); +} |