Started ezEditTable integration
|
@ -204,6 +204,11 @@ module.exports = function (grunt) {
|
|||
{ src: 'libs/sortabletable.js', dest: '<%= source_folder %>extensions/sortabletable/sortabletable.js' },
|
||||
// { src: 'libs/requirejs/require.js', dest: '<%= dist_folder %>require.js' },
|
||||
// { src: ['**'], cwd: '<%= source_folder %>TF_Modules/', dest: '<%= dist_folder %>TF_Modules/', expand: true },
|
||||
|
||||
// TODO: remove ezEditTable
|
||||
{ src: ['**'], cwd: 'libs/ezEditTable/', dest: '<%= source_folder %>extensions/ezEditTable/', expand: true },
|
||||
{ src: ['**'], cwd: 'libs/ezEditTable/', dest: '<%= dist_folder %>extensions/ezEditTable/', expand: true },
|
||||
//
|
||||
{ src: ['**'], cwd: '<%= source_folder %>TF_Themes/', dest: '<%= dist_folder %>TF_Themes/', expand: true }
|
||||
]
|
||||
}
|
||||
|
|
2049
dist/extensions/ezEditTable/docs/doc.html
vendored
Normal file
154
dist/extensions/ezEditTable/docs/doc_class.html
vendored
Normal file
|
@ -0,0 +1,154 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_constructor" id="ez_constructor"></a>
|
||||
<h3>Constructor</h3>
|
||||
<h3><code>EditTable(id, startRow, config);</code></h3>
|
||||
<table id="tblConstructor" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Parameter</th>
|
||||
|
||||
<th>Type</th>
|
||||
<th>Description</th>
|
||||
<th>Remarks</th>
|
||||
<th>Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>id</strong></td>
|
||||
<td>string</td>
|
||||
<td>id of the <code>table</code> element</td>
|
||||
<td> </td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId");</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>startRow</strong> </td>
|
||||
<td>number</td>
|
||||
<td>index of the first row from which row selection can start</td>
|
||||
<td>optional parameter</td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId", 2);</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>config</strong></td>
|
||||
<td>object</td>
|
||||
<td> configuration object</td>
|
||||
<td>optional parameter</td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId", 2, { editable: true });</code></td>
|
||||
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
<hr/>
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
599
dist/extensions/ezEditTable/docs/doc_methods.html
vendored
Normal file
|
@ -0,0 +1,599 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_methods" id="ez_methods"></a>
|
||||
<h3>General Public Methods</h3>
|
||||
<table id="tblMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
|
||||
<th width="200">Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
|
||||
<td>EditTable object initialisation</td>
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br>
|
||||
myET.editable = true;<br />
|
||||
... <br />
|
||||
myET.Init();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetCellsNb( rowIndex )</strong></td>
|
||||
<td>returns number of cells of a specified row</td>
|
||||
<td> </td>
|
||||
<td><code> myET.GetCellsNb(4);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr class="newBg">
|
||||
<td><strong>GetRowsNb()</strong></td>
|
||||
<td>returns total number of rows</td>
|
||||
<td> </td>
|
||||
<td><code>myET.GetRowsNb();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRow(e)</strong></td>
|
||||
|
||||
<td>returns the DOM row element for a given event</td>
|
||||
<td> </td>
|
||||
<td><code>function myFunction(e){ var clickedRow = myET.GetRow(e); }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRowByIndex( rowIndex )</strong></td>
|
||||
<td>returns the DOM row element for a given row index</td>
|
||||
|
||||
<td> </td>
|
||||
<td> <code>myET.GetRowByIndex(5);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetCell(e)</strong></td>
|
||||
<td>returns the DOM cell element for a given event</td>
|
||||
<td> </td>
|
||||
|
||||
<td> <code>function myFunction(e){ var clickedCell = myET.GetCell(e);
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsSelectable()</strong></td>
|
||||
<td>checks if table rows are selectable and returns a boolean </td>
|
||||
<td> </td>
|
||||
<td><code>myET.IsSelectable();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsEditable()</strong></td>
|
||||
<td>checks if table is editable and returns a boolean </td>
|
||||
<td> </td>
|
||||
<td><code>myET.IsEditable();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ClearSelections()</strong></td>
|
||||
|
||||
<td>clears current row(s) and/or cell selection</td>
|
||||
<td> </td>
|
||||
<td> <code>myET.ClearSelections();</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
<hr/>
|
||||
|
||||
<a name="ez_selection_methods" id="ez_selection_methods"></a>
|
||||
<h3>Selection Public Methods</h3>
|
||||
<table id="tblSelectionMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
<td>Selection object initialisation</td>
|
||||
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br />
|
||||
... <br />
|
||||
myET.Selection.Init();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Set()</strong></td>
|
||||
|
||||
<td>enables selection feature</td>
|
||||
<td> </td>
|
||||
<td><code> myET.Selection.Set();</code></td>
|
||||
</tr>
|
||||
<tr class="newBg">
|
||||
<td><strong>Remove()</strong></td>
|
||||
<td> disables selection feature</td>
|
||||
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.Remove();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SetEvents()</strong></td>
|
||||
<td>sets click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.SetEvents();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>RemoveEvents()</strong></td>
|
||||
<td>removes click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.RemoveEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveRow()</strong></td>
|
||||
|
||||
<td>returns the active row element, that is, the row currently selected</td>
|
||||
<td> </td>
|
||||
<td> <code>var activeRow = myET.Selection.GetActiveRow();<br>
|
||||
if(activeRow){ ... }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveCell()</strong></td>
|
||||
|
||||
<td>returns the active cell element, that is, the cell currently selected</td>
|
||||
<td> </td>
|
||||
<td><code>var activeCell = myET.Selection.GetActiveCell();<br>
|
||||
if(activeCell){ ... }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetSelectedRows()</strong></td>
|
||||
|
||||
<td>returns an array of the row elements currently selected, if selection
|
||||
model is multiple</td>
|
||||
<td>returns: <br>
|
||||
[rowobject, rowobject, rowobject, ... rowobject] </td>
|
||||
<td> <code>var selRows = myET.Selection.GetSelectedRows();<br>
|
||||
if(selRows.length > 0){ ... }</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetSelectedValues()</strong></td>
|
||||
<td>returns an array containing a collection of selected rows values
|
||||
</td>
|
||||
<td>returns: [<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
...<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3']<br>
|
||||
] </td>
|
||||
<td><code>var selValues = myET.Selection.GetSelectedValues();<br>
|
||||
if(selValues.length > 0){<br>
|
||||
|
||||
var firstValueOfFirstSelectedRow = selValues[0][0];<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveRowValues()</strong></td>
|
||||
<td>returns an array containing the cell values of active row</td>
|
||||
<td>returns ['value 0', 'value 1', 'value 2', ... 'value 3']</td>
|
||||
|
||||
<td><code>var activeValues = myET.Selection.GetActiveRowValues();<br>
|
||||
if(activeValues.length > 0){ ... } </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRowValues( row )</strong></td>
|
||||
<td>returns an array containing the cell values of a given row, it accepts
|
||||
only a row DOM element</td>
|
||||
|
||||
<td>returns ['value 0', 'value 1', 'value 2', ... 'value 3'] </td>
|
||||
<td> <p><code>var myRow = myET.GetRowByIndex(7);<br>
|
||||
if(myRow){ <br>
|
||||
myRowValues = myET.Selection.GetRowValues(myRow);<br>
|
||||
</code><code>}</code></p></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRowByIndex( rowIndex )</strong></td>
|
||||
<td>selects a row for a given row index</td>
|
||||
<td> </td>
|
||||
<td><code> myET.Selection.SelectRowByIndex(9);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRowsByIndexes( rowIndexes )</strong> <sup>new</sup></td>
|
||||
<td>selects rows for a given array of row indexes</td>
|
||||
<td>Multiple selection needs to be active (selection_model: 'multiple')</td>
|
||||
<td><code> myET.Selection.SelectRowsByIndexes([2, 7, 9, 12]);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRow( row )</strong></td>
|
||||
<td>selects given row element</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
if(myRow){<br>
|
||||
myET.Selection.SelectRow(myRow);<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>DeselectRow( row )</strong></td>
|
||||
<td>deselects given row element</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
if(myET.Selection.IsRowSelected(myRow)){<br>
|
||||
|
||||
myET.Selection.DeselectRow(myRow);<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SelectCell( cell )</strong></td>
|
||||
<td>selects given cell element</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
if(myCell) myET.Selection.SelectCell(myCell);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>DeselectCell( cell )</strong></td>
|
||||
<td>deselects given cell element</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
if(myCell) myET.Selection.DeselectCell(myCell);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ClearSelections()</strong></td>
|
||||
<td>clears current row(s) and/or cell selection</td>
|
||||
<td>The general <code>ClearSelections()</code> invokes this method (<code>
|
||||
myET</code><code>.ClearSelections</code>() )</td>
|
||||
|
||||
<td><code>myET.Selection.ClearSelections();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsRowSelected( row )</strong></td>
|
||||
<td>determines if given row is selected and returns a boolean</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
|
||||
if(myET.Selection.IsRowSelected(myRow)){ ... } </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsCellSelected( cell )</strong></td>
|
||||
<td>determines if given cell is selected and returns a boolean</td>
|
||||
<td> </td>
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
|
||||
if(myET.Selection.IsCellSelected( myCell )){ ... }</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
<hr/>
|
||||
|
||||
<a name="ez_editable_methods" id="ez_editable_methods"></a>
|
||||
<h3>Editable Public Methods</h3>
|
||||
|
||||
<table id="tblEditableMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
<td>Editable object initialisation</td>
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br />
|
||||
|
||||
... <br />
|
||||
myET.Editable.Init();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Set()</strong></td>
|
||||
<td>enables inline editing feature</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code> myET.Editable.Set();</code></td>
|
||||
</tr>
|
||||
<tr class="newBg">
|
||||
<td><strong>Remove()</strong></td>
|
||||
<td> disables inline editing feature</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.Remove();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SetEvents()</strong></td>
|
||||
<td>sets click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.SetEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>RemoveEvents()</strong></td>
|
||||
|
||||
<td>removes click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.RemoveEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetModifiedRows()</strong></td>
|
||||
<td>returns an array containing the modified rows objects</td>
|
||||
|
||||
<td>returns: <br>
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, false, ...]<br>
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, false, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td> <p><code>var modRowObjs = myET.Editable.GetModifiedRows();<br>
|
||||
for(var i=0; i<modRowObjs.length; i++){<br>
|
||||
var rowIndex = modRowObjs[i][0]; //int<br>
|
||||
var obj = modRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
} </code></p></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetAddedRows()</strong></td>
|
||||
<td>returns an array containing the added rows objects</td>
|
||||
|
||||
<td>returns: <br>
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, true, ...]<br>
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, true, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td><code>var addRowObjs = myET.Editable.GetAddedRows();<br>
|
||||
for(var i=0; i<addRowObjs.length; i++){<br>
|
||||
var rowIndex = addRowObjs[i][0]; //int<br>
|
||||
var obj = addRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetDeletedRows()</strong></td>
|
||||
<td>returns an array containing the deleted rows objects</td>
|
||||
<td>returns: <br>
|
||||
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
modified: [false, false, ...]<br>
|
||||
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [false, false, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td> <code>var delRowObjs = myET.Editable.GetDeletedRows();<br>
|
||||
for(var i=0; i<delRowObjs.length; i++){<br>
|
||||
var rowIndex = delRowObjs[i][0]; //int<br>
|
||||
var obj = delRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitEditedRows()</strong></td>
|
||||
<td>submits edited rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
|
||||
<td>modified rows objects are sent to server (uri property in 'update'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options)</td>
|
||||
<td><p><code>function SaveEditedRows(){<br>
|
||||
myET.Editable.SubmitEditedRows();<br>
|
||||
}</code></p>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitAddedRows()</strong></td>
|
||||
<td>submits added rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td>added rows objects are sent to server (uri property in 'insert'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options)</td>
|
||||
<td><code>function SaveAddedRows(){
|
||||
myET.Editable.SubmitAddeddRows();
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitDeletedRows()</strong></td>
|
||||
<td>submits deleted rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td>deleted rows objects are sent to server (uri property in 'delete'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options). A
|
||||
confirmation prompt appears before sending data to server</td>
|
||||
|
||||
<td> <p><code>function DeleteSelectedRows(){
|
||||
myET.Editable.SubmitDeletedRows();
|
||||
}</code></p></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitAll()</strong> <sup>new</sup></td>
|
||||
<td>submits added and edited rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td></td>
|
||||
<td><code>function SubmitAll(){ myET.Editable.SubmitAll(); }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>AddNewRow()</strong></td>
|
||||
<td>adds a row to the table</td>
|
||||
|
||||
<td></td>
|
||||
<td><code>myET.Editable.AddNewRow();</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
515
dist/extensions/ezEditTable/docs/doc_properties.html
vendored
Normal file
|
@ -0,0 +1,515 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_properties" id="ez_properties"></a>
|
||||
<h3>General Public Properties</h3>
|
||||
<table id="tblProps" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>id</strong></td>
|
||||
<td>string</td>
|
||||
<td>returns the HTML table's id used by the EditTable object</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.id );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>table</strong></td>
|
||||
<td>HTMLTableElement</td>
|
||||
<td>returns the HTML table element used by the EditTable object</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.table );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>config</strong></td>
|
||||
<td>object</td>
|
||||
<td>returns the EditTable configuration object (literal object)</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.config );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>startRow</strong></td>
|
||||
<td>number</td>
|
||||
<td>index of the first row from which row selection can start</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.startRow );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>nbCells</strong></td>
|
||||
<td>number</td>
|
||||
<td>returns the number of table columns</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.nbCells );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>selection</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables selection model</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.selection = false;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>keyNav</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables keyboard navigation</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.keyNav = false;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>editable</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables inline editing</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.editable = true;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>tableCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class of the table element</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.tableCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>unselectableCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class that makes the table text unselectable</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.unselectableCss );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>activityIndicatorCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class to be applied to the table in order to indicate
|
||||
server activity </td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.activityIndicatorCss );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>basePath</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the path to the script's directory</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.basePath );</code></td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
<a name="ez_selection_properties" id="ez_selection_properties"></a>
|
||||
<h3>Selection Public Properties</h3>
|
||||
<table id="tblSelectionProps" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>selectionModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the selection model: "single" or "multiple"</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'single' or 'multiple'</td>
|
||||
|
||||
<td><code>myET.selectionModel = 'multiple';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>defaultSelection</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the selection type</td>
|
||||
<td>use it as getter or setter - 3 possible values: 'row', 'cell' or
|
||||
'both'</td>
|
||||
|
||||
<td><code>myET.defaultSelection = 'both';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>keySelection</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disable multiple selection by using Ctrl and Shift keys
|
||||
</td>
|
||||
<td>use it as getter or setter - select multiple rows by holding Ctrl
|
||||
or Shift key down, only if selection model is 'multiple'</td>
|
||||
|
||||
<td><code>myET.keySelection = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectRowAtStart</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>first row is selected at start if set true</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.selectRowAtStart = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>rowIndexAtStart</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines which row has to be selected at start</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.rowIndexAtStart = 5;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>scrollIntoView</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>If set true selected row scrolls into view; useful when row is selected
|
||||
by using keyboard</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.scrollIntoView = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>activeRowCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for active row</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.activeRowCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectedRowCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for selected rows</td>
|
||||
<td>use it as getter or setter - only if 'multiple' selection model
|
||||
is enabled</td>
|
||||
|
||||
<td><code>myET.selectedRowCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>activeCellCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for active cell</td>
|
||||
<td>use it as getter or setter - only if 'cell' or 'both' selection
|
||||
type is enabled</td>
|
||||
|
||||
<td><code>myET.activeCellCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>nbRowsPerPage</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines number of rows to jump when PgDown or PgUp keys are pressed</td>
|
||||
<td>use it as getter or setter - specify a huge number to jump straight
|
||||
to 1st or last row (1000)</td>
|
||||
|
||||
<td><code>myET.nbRowsPerPage = 1000;</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
<a name="ez_editable_properties" id="ez_editable_properties"></a>
|
||||
<h3>Editable Public Properties</h3>
|
||||
<table id="tblEditableProps" cellspacing="0" class="ezEditableTable" >
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>editorModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the editor model</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'cell' or 'row'</td>
|
||||
|
||||
<td><code>myET.editorModel = 'row';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>openEditorAction</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines which mouse action opens the inline editing feature</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'dblclick', 'click'</td>
|
||||
|
||||
<td><code>myET.openEditorAction = 'click';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ajax</strong> <sup>new</sup></td>
|
||||
<td>boolean</td>
|
||||
<td>enables AJAX requests (default: true if jQuery is detected)</td>
|
||||
<td>it is enabled if jQuery is detected and the <code>ajax</code> property is
|
||||
not explicitly set <code>false</code></td>
|
||||
<td><code>myET.ajax = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>inputEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>defines the css class for 'input' type editors</td>
|
||||
<td>use it as getter or setter - select multiple rows by holding Ctrl
|
||||
or Shift key down, only if selection model is 'multiple'</td>
|
||||
|
||||
<td><code>myET.inputEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>textareaEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>defines the css class for 'textarea' type editors</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.textareaEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectEditorCss</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines the css class for 'input' type editors</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.selectEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>commandEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>css class applied to command editor buttons container</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.commandEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>modifiedCellCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>css class applied to modified cells</td>
|
||||
<td>use it as getter or setter - this css class shows the green small
|
||||
triangle in the left-upper corner of the cell</td>
|
||||
|
||||
<td><code>myET.modifiedCellCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>cellEditors</strong></td>
|
||||
<td>array</td>
|
||||
<td>array defining the editor configuration for each column</td>
|
||||
<td>use it as getter or setter - the number of editors must be equal
|
||||
to the number of columns. Refer to <a href="doc.html#ez_cell_editors">Cell
|
||||
editors properties</a> for details about editors' configuration</td>
|
||||
<td><code>myET.cellEditors = [<br>
|
||||
{ type: 'select' },<br>
|
||||
{ type: 'textarea' },<br>
|
||||
{ type: 'input' },<br>
|
||||
{ type: 'uploader' },<br>
|
||||
{ type: 'none' }, <br>
|
||||
{ type: 'command' }<br>
|
||||
];</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>actions</strong></td>
|
||||
<td>object</td>
|
||||
<td>server actions configuration object </td>
|
||||
<td>use it as getter or setter - Refer to <a href="doc.html#ez_actions">actions
|
||||
properties</a> for details about server actions configuration</td>
|
||||
|
||||
<td><code>myET.actions = {<br>
|
||||
'update': { <br>
|
||||
uri: 'updateRow.php', submit_method: 'form', form_method: 'POST',
|
||||
<br>
|
||||
param_names: ['iso', 'name', 'printablename', 'iso3', 'code'] },<br>
|
||||
'insert': { <br>
|
||||
uri: 'insertRow.php', submit_method: 'form', form_method: 'POST',
|
||||
<br>
|
||||
|
||||
param_names: ['iso', 'name', 'printablename', 'iso3', 'code'] },<br>
|
||||
'delete': { <br>
|
||||
uri: 'script.delete.php', submit_method: 'script', bulk_delete: true
|
||||
}<br>
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSave</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>saves automatically pending changes upon selection change</td>
|
||||
<td><code>editable</code> property needs to be activated (default: true if editable is on)</td>
|
||||
<td><code>myET.autoSave = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSaveModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>determines when modified and/or added data is saved, upon row or cell selection change (default: 'row')</td>
|
||||
<td>2 possible values 'row' or 'cell'</td>
|
||||
<td><code>myET.autoSaveModel = 'cell';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSaveType</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines if only insertions or updates, or both are saved automatically (default: 'both')</td>
|
||||
<td>3 possible values 'insert', 'update' or 'both'</td>
|
||||
<td><code>myET.autoSaveType = 'update';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>editableOnKeystroke</strong> <sup>new</sup></td>
|
||||
<td>boolean</td>
|
||||
<td>makes the inline cell editor appear upon keystroke (default: false)</td>
|
||||
<td>only if edition is enabled and <code>editorModel</code> is set to <code>'cell'</code> and
|
||||
<code>selectionModel</code> to <code>'single'</code></td>
|
||||
<td><code>myET.editableOnKeystroke = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>newRowPrefix</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the prefix for new added row ids (default: 'tr')</td>
|
||||
<td>prefix should match the prefix assigned to already existing rows</td>
|
||||
<td><code>myET.newRowPrefix = 'row';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>formSubmitInterval</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines the interval in ms separating rows data submissions (default: 50)</td>
|
||||
<td>by default the script submits a single form for each modified row. Depending on ISPs
|
||||
security policies, multiple submissions to same page are simply blocked by the server.
|
||||
This interval can be useful to fine tune the form submissions when those server restrictions apply.</td>
|
||||
<td><code>myET.formSubmitInterval = 750;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>newRowPos</strong> <sup>new</sup></td>
|
||||
<td>string or number</td>
|
||||
<td>defines the row position of a newly created row (default: 'top')</td>
|
||||
<td>2 possible values as a string: 'top' or 'bottom', and as an integer:
|
||||
any number >= 0 and <= total number of rows. If the supplied numeric
|
||||
value exceeds the total number of rows then the script fallback to default
|
||||
value 'top'</td>
|
||||
<td><code>myET.newRowPos = 'bottom';</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
207
dist/extensions/ezEditTable/docs/doc_utilities.html
vendored
Normal file
|
@ -0,0 +1,207 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>Utility Functions</h2>
|
||||
|
||||
|
||||
<table id="tblUtils" cellspacing="0" class="ezEditableTable" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> setEditTable( id, startRow, config )</strong></td>
|
||||
<td><p>Calls EditTable constructor and returns the EditTable object:</p>
|
||||
|
||||
<ul>
|
||||
<li>id: table id (string)</li>
|
||||
<li>startRow (optional): index of the first row from which row selection
|
||||
can start (number)</li>
|
||||
<li>config (optional): configuration object (literal object)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code> var et = setEditTable('myTableId', 2, { editable: true });</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong> Get(id)</strong></td>
|
||||
<td><p>this is a <code>document.getElementById()</code> shortcut:</p>
|
||||
<ul>
|
||||
<li>id: id of the element (string)</li>
|
||||
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code> var myElm = et.Get('myId');</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Tag(o, tagname)</strong></td>
|
||||
<td><p>this is just a <code>getElementsByTagName()</code> shortcut:</p>
|
||||
|
||||
<ul>
|
||||
<li>o: target element (DOM element)</li>
|
||||
<li>tagname: tag to search for (string)</li>
|
||||
</ul>
|
||||
<p>It returns an array</p></td>
|
||||
<td> </td>
|
||||
<td><code>var myTables = et.Tag(document, 'table');</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetText(n)</strong></td>
|
||||
<td><p>returns the text of given a node and its child nodes:</p>
|
||||
<ul>
|
||||
<li>n: node (DOM element)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var tableText = et.GetText( et.Tag(document,'table' )[0]);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>CreateElm(tag)</strong></td>
|
||||
<td><p>creates an html element with defined attributes:</p>
|
||||
<ul>
|
||||
<li>the html tag to create (string)</li>
|
||||
|
||||
<li>an unlimited # of arrays defining the attributes values ('attribute
|
||||
name','value' ['id','myId'])</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code>var myInput = et.CreateElm( 'input', ['id','myId'], ['value','Hello
|
||||
world'] );</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>CreateText(t)</strong></td>
|
||||
<td><p>this is just a <code>document.createTextNode</code> shortcut:</p>
|
||||
|
||||
<ul>
|
||||
<li>t: text to generate (string)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code>var myText = et.CreateText( 'Hello world' );</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsArray(obj)</strong></td>
|
||||
|
||||
<td><p>checks if passed param is an array. It returns a boolean</p></td>
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsArray([1,2,3]));</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsObj(obj)</strong></td>
|
||||
<td><p>checks if passed param is an object. It returns a boolean</p></td>
|
||||
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsObj({ text: 'hello'}));</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsFn(fn)</strong></td>
|
||||
<td><p>checks if passed param is a function. It returns a boolean</p></td>
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsFn(function(){ var a=0; }));</code></td>
|
||||
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<hr/>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
473
dist/extensions/ezEditTable/docs/index.html
vendored
Normal file
|
@ -0,0 +1,473 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk01{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
<h1>ezEditTable</h1>
|
||||
<h2>Description</h2>
|
||||
<p>
|
||||
ezEditTable is a javascript code aimed at enhancing regular
|
||||
HTML tables by adding features such as inline editing components, advanced
|
||||
selection and keyboard navigation. With just a line of code you can easily
|
||||
convert a regular HTML table in an advanced editable and selectable grid control.
|
||||
</p>
|
||||
<h3>Main features</h3>
|
||||
<ul>
|
||||
<li>Attach to an existing HTML table</li>
|
||||
<li>Advanced selection model</li>
|
||||
<li>Extended keyboard navigation</li>
|
||||
<li>Inline cell or row editing</li>
|
||||
<li>Insert and remove rows</li>
|
||||
<li>Send changes to server via GET or POST form submission, AJAX requests or
|
||||
by script injection in the head section of the document (only GETs)</li>
|
||||
<li>Integration with any server-side technology as this is a pure client-side solution</li>
|
||||
<li>Callbacks for all events, and delegates for most actions</li>
|
||||
<li>Based on plain javascript and dependent on jQuery only for performing AJAX requests</li>
|
||||
<li>Exhaustive documentation and API</li>
|
||||
<li>Easy setup and easy customisable themes</li>
|
||||
</ul>
|
||||
|
||||
<h2>Installation
|
||||
<span class="floatRight fontSize12px">
|
||||
<a href="starter.html">Starter</a>
|
||||
</span>
|
||||
</h2>
|
||||
<p>To install <strong>ezEditTable</strong> unzip the download package and then include the following
|
||||
scripts and stylesheet files in the <code>head</code> section of your page:</p>
|
||||
|
||||
<pre>
|
||||
<link href="ezEditTable/ezEditTable.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="ezEditTable/ezEditTable.js"></script>
|
||||
</pre>
|
||||
|
||||
<p>Make sure the table you'd like to make editable or selectable
|
||||
has an unique <code>id</code> and a <code>thead</code> and <code>tbody</code>
|
||||
sections.</p>
|
||||
<p>Here you have an example of a regular html table: </p>
|
||||
<table border="1" cellspacing="0" cellpadding="2" width="80%">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p>Below the same table enhanced by the script (<code>id="table1"</code>),
|
||||
click to select a row or use keys to move the selection:</p>
|
||||
<table id="table1" cellspacing="0" cellpadding="0" width="80%">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var et = new EditTable('table1');
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
<p>There are 2 different ways to call the script:</p>
|
||||
<ul>
|
||||
|
||||
|
||||
<li>invoke the <code>setEditTable</code> function, which returns a EditTable object: </li>
|
||||
</ul>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var et = setEditTable("table1");
|
||||
</script> </pre>
|
||||
|
||||
<ul>
|
||||
<li>instanciate the <strong><code>EditTable</code></strong> object: </li>
|
||||
</ul>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var et = new EditTable('table1');
|
||||
et.Init();
|
||||
</script> </pre>
|
||||
<p>If your document contains several tables (like this page), it is important
|
||||
to define unique ids, otherwise the script will not work properly. </p>
|
||||
|
||||
<p>The <code>setEditTable()</code> function or the <code>EditTable</code>
|
||||
class accepts 2 additional parameters that will be explained in the next
|
||||
tables. In the example below, by specifing a row number as a "start"
|
||||
row, we tell the script from which row can start the selection, this is
|
||||
helpful when the <code>tbody</code> and <code>thead</code> sections are not defined: </p>
|
||||
|
||||
|
||||
<table id="table2" cellspacing="0" cellpadding="0" >
|
||||
<tr>
|
||||
<td colspan="5"><strong>This is the table caption </strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var et02 = new EditTable("table2",2);
|
||||
et02.Init();
|
||||
</script>
|
||||
|
||||
<pre class="brush: js;">var et02 = setEditTable("table2", 2);</pre>
|
||||
|
||||
<p>or</p>
|
||||
|
||||
<pre class="brush: js;">var et02 = new EditTable("table2", 2);
|
||||
et02.Init();</pre>
|
||||
<p>By default, the script adds a single row selection feature to the table.
|
||||
You could decide to also add a cell selection feature and make the cells
|
||||
editable, double-click on a cell to see:</p>
|
||||
|
||||
<table id="table3" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td colspan="5"><strong>This is the table caption </strong></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th style="width:100px">From</th>
|
||||
<th style="width:100px">Destination</th>
|
||||
<th style="width:100px">Road Distance (km)</th>
|
||||
<th style="width:100px">By Air (hrs)</th>
|
||||
<th style="width:80px">By Rail (hrs)</th>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
};
|
||||
var et03 = new EditTable("table3", 2, table3Config);
|
||||
et03.Init();
|
||||
</script>
|
||||
<p>To do that you just need to declare a <em>literal object</em> (configuration
|
||||
object) in which you specify the features you would like to enable:</p>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
}
|
||||
var et03 = setTableEdit("table3", 2, table3Config);
|
||||
</script></pre>
|
||||
<p>or</p>
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
}
|
||||
var et03 = new EditTable("table3", 2 ,table3Config);
|
||||
et03.Init();
|
||||
</script></pre>
|
||||
|
||||
<p>You can name the <em>configuration object</em> as you want, but don't forget
|
||||
to add it to the parameters of the <code>setEditTable</code>() function
|
||||
or <code>EditTable</code> class. It is important to respect the syntax and
|
||||
naming convention as shown above. You will find an exhaustive list of properties
|
||||
in the <a href="doc.html">documentation</a> section. </p>
|
||||
<h2>Documentation</h2>
|
||||
|
||||
|
||||
<p>For more information about the script's configuration and API check out
|
||||
the <a href="doc.html">documentation</a> and the
|
||||
available online <a href="http://edittable.free.fr/demos.php">demos</a>.</p>
|
||||
|
||||
<hr class="clearBoth" />
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
1082
dist/extensions/ezEditTable/docs/samples.html
vendored
Normal file
195
dist/extensions/ezEditTable/docs/starter.html
vendored
Normal file
|
@ -0,0 +1,195 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily - Starter page - by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>Starter</h1>
|
||||
<p>
|
||||
<a href="index.html">← Documentation</a>
|
||||
</p>
|
||||
<div>
|
||||
<table id="demo" cellspacing="0" cellpadding="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<script language="javascript" type="text/javascript">
|
||||
var config = {
|
||||
selection: true,
|
||||
default_selection: 'both'
|
||||
};
|
||||
var et = new EditTable('demo', config);
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<h4>Source code of the page:</h4>
|
||||
<pre>
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily - Starter page - by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h1>ezEditTable Starter</h1>
|
||||
|
||||
<table id="demo" cellspacing="0" cellpadding="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<script language="javascript" type="text/javascript">
|
||||
var config = {
|
||||
selection: true,
|
||||
default_selection: 'both'
|
||||
};
|
||||
var et = new EditTable('demo', config);
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
86
dist/extensions/ezEditTable/ezEditTable-uncompressed.css
vendored
Normal file
|
@ -0,0 +1,86 @@
|
|||
/*====================================================
|
||||
- ezEditTable global stylesheet
|
||||
- Edit classes below for your projects' needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
padding:0; color:#000;
|
||||
border-collapse:collapse;
|
||||
font:12px/13px arial, tahoma, helvetica, sans-serif !important;
|
||||
}
|
||||
.ezEditableTable th, .ezEditableTable td{
|
||||
margin:0; padding:5px;
|
||||
color:inherit;
|
||||
border:1px solid #ccc !important;
|
||||
}
|
||||
.ezEditableTable th{
|
||||
background:#EBECEE !important;
|
||||
}
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow{ background-color:#2852A8 !important; color:#fff; }
|
||||
.ezSelectedRow{ background-color:#316AC5; color:#fff; }
|
||||
.ezActiveCell{
|
||||
background-color:#D9E8FB !important;
|
||||
color:#000 !important; font-weight:bold;
|
||||
}
|
||||
.ezUnselectable{
|
||||
-moz-user-select: -moz-none;
|
||||
-khtml-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
/* Cell editors */
|
||||
.ezInputEditor{ width:95%; height:auto; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezTextareaEditor{ width:95%; height:35px; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezSelectEditor{ width:100%; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezModifiedCell{ background:transparent url(themes/bg_mod_cell.png) 0 0 no-repeat; }
|
||||
select[multiple="multiple"].ezSelectEditor{ height:35px; }
|
||||
/* Command type editor */
|
||||
.ezCommandEditor{ margin:2px; }
|
||||
.ezCommandEditor button{
|
||||
font-size:10px;
|
||||
border:1px solid #ccc;
|
||||
background:#fff; margin:1px;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
/* Uploader editor */
|
||||
.ezUploaderEditor{
|
||||
position:absolute; display:inline;
|
||||
margin:15px 0 0 0px;
|
||||
border:1px solid #ccc; padding:5px;
|
||||
background:#fff; color:#000; z-index:10000;
|
||||
border-radius:4px;
|
||||
-moz-border-radius:4px;
|
||||
-webkit-border-radius:4px;
|
||||
box-shadow:3px 3px 2px #888;
|
||||
-moz-box-shadow:3px 3px 2px #888;
|
||||
-webkit-box-shadow:3px 3px 2px #888;
|
||||
}
|
||||
.ezUploaderEditor button{
|
||||
font-size:10px;
|
||||
border:1px solid #ccc;
|
||||
background:#fff; margin:1px;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
.ezUploaderEditorOutput{ }
|
||||
.ezUploaderEditorDisplay{
|
||||
display:none; position:relative;
|
||||
max-width:800px; max-height:600px;
|
||||
overflow:auto; border:0;
|
||||
background:#fff; padding:5px; margin:5px;
|
||||
}
|
||||
|
||||
/* Utils */
|
||||
.ezOpacity{
|
||||
filter:alpha(opacity=60); /* for IE */
|
||||
opacity:0.6; /* CSS3 standard */
|
||||
}
|
||||
.alignLeft{ text-align:left; }
|
||||
.alignCenter{ text-align:center; }
|
||||
.alignRight{ text-align:right; }
|
||||
.icnImg{ border:0; }
|
2081
dist/extensions/ezEditTable/ezEditTable-uncompressed.js
vendored
Normal file
7
dist/extensions/ezEditTable/ezEditTable.css
vendored
Normal file
|
@ -0,0 +1,7 @@
|
|||
/*------------------------------------------------------------------------
|
||||
- ezEditTable stylesheet by Max Guglielmi
|
||||
- (build date: Sun Mar 15 2015 15:46:31)
|
||||
- Edit below for your projects' needs
|
||||
------------------------------------------------------------------------*/
|
||||
|
||||
.ezEditableTable{padding:0;color:#000;border-collapse:collapse;font:12px/13px arial,tahoma,helvetica,sans-serif!important}.ezEditableTable th,.ezEditableTable td{margin:0;padding:5px;color:inherit;border:1px solid #ccc!important}.ezEditableTable th{background:#EBECEE!important}.ezActiveRow{background-color:#2852A8!important;color:#fff}.ezSelectedRow{background-color:#316AC5;color:#fff}.ezActiveCell{background-color:#D9E8FB!important;color:#000!important;font-weight:700}.ezUnselectable{-moz-user-select:-moz-none;-khtml-user-select:none;-webkit-user-select:none;-o-user-select:none;user-select:none}.ezInputEditor{width:95%;height:auto;font-size:inherit;border:1px solid #AACCF6}.ezTextareaEditor{width:95%;height:35px;font-size:inherit;border:1px solid #AACCF6}.ezSelectEditor{width:100%;font-size:inherit;border:1px solid #AACCF6}.ezModifiedCell{background:transparent url(themes/bg_mod_cell.png) 0 0 no-repeat}select[multiple=multiple].ezSelectEditor{height:35px}.ezCommandEditor{margin:2px}.ezCommandEditor button{font-size:10px;border:1px solid #ccc;background:#fff;margin:1px;border-radius:4px;-moz-border-radius:4px}.ezUploaderEditor{position:absolute;display:inline;margin:15px 0 0;border:1px solid #ccc;padding:5px;background:#fff;color:#000;z-index:10000;border-radius:4px;-moz-border-radius:4px;-webkit-border-radius:4px;box-shadow:3px 3px 2px #888;-moz-box-shadow:3px 3px 2px #888;-webkit-box-shadow:3px 3px 2px #888}.ezUploaderEditor button{font-size:10px;border:1px solid #ccc;background:#fff;margin:1px;border-radius:4px;-moz-border-radius:4px}.ezUploaderEditorOutput{}.ezUploaderEditorDisplay{display:none;position:relative;max-width:800px;max-height:600px;overflow:auto;border:0;background:#fff;padding:5px;margin:5px}.ezOpacity{filter:alpha(opacity=60);opacity:.6}.alignLeft{text-align:left}.alignCenter{text-align:center}.alignRight{text-align:right}.icnImg{border:0}
|
9
dist/extensions/ezEditTable/ezEditTable.js
vendored
Normal file
BIN
dist/extensions/ezEditTable/themes/bg_mod_cell.png
vendored
Normal file
After Width: | Height: | Size: 234 B |
23
dist/extensions/ezEditTable/themes/default/ezDefault.css
vendored
Normal file
|
@ -0,0 +1,23 @@
|
|||
/*====================================================
|
||||
- ezEditTable default theme stylesheet
|
||||
- Edit classes below for your project needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
border:0 !important;
|
||||
border-left:1px solid #99BBE8 !important;
|
||||
border-right:1px solid #99BBE8 !important;
|
||||
border-bottom:1px solid #99BBE8 !important;
|
||||
font:12px/13px arial, tahoma, helvetica, sans-serif !important;
|
||||
}
|
||||
.ezEditableTable th, td{ border:1px solid #C5D3EC !important; }
|
||||
.ezEditableTable th{
|
||||
background:transparent url(img/bg_col_header.gif) 0 -2px repeat-x !important;
|
||||
}
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow td{ background-color:#316AC5; color:#fff !important; }
|
||||
.ezSelectedRow{ background-color:#D9E8FB !important; border:1px dotted #909090 !important; color:#000; }
|
||||
|
||||
/* Command type editor */
|
||||
.ezCommandEditor button{ border:1px solid #C5D3EC !important; }
|
BIN
dist/extensions/ezEditTable/themes/default/img/bg_col_header.gif
vendored
Normal file
After Width: | Height: | Size: 875 B |
BIN
dist/extensions/ezEditTable/themes/icn_add.gif
vendored
Normal file
After Width: | Height: | Size: 398 B |
BIN
dist/extensions/ezEditTable/themes/icn_cross.png
vendored
Normal file
After Width: | Height: | Size: 655 B |
BIN
dist/extensions/ezEditTable/themes/icn_del.gif
vendored
Normal file
After Width: | Height: | Size: 330 B |
BIN
dist/extensions/ezEditTable/themes/icn_edit.gif
vendored
Normal file
After Width: | Height: | Size: 342 B |
BIN
dist/extensions/ezEditTable/themes/icn_save.gif
vendored
Normal file
After Width: | Height: | Size: 375 B |
BIN
dist/extensions/ezEditTable/themes/icn_tick.png
vendored
Normal file
After Width: | Height: | Size: 537 B |
68
dist/extensions/ezEditTable/themes/skyblue/ezSkyBlue.css
vendored
Normal file
|
@ -0,0 +1,68 @@
|
|||
/*====================================================
|
||||
- ezEditTable SkyBlue theme stylesheet
|
||||
- Edit classes below for your project needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
padding:0; color:#000;
|
||||
font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important;
|
||||
border-right:1px solid #A4BED4;
|
||||
border-top:1px solid #A4BED4;
|
||||
border-left:1px solid #A4BED4;
|
||||
border-bottom:0;
|
||||
}
|
||||
.ezEditableTable td{
|
||||
margin:0; padding:5px; color:inherit;
|
||||
border-bottom:1px solid #A4BED4;
|
||||
border-left:0; border-top:0; border-right:0;
|
||||
}
|
||||
.ezEditableTable th{
|
||||
margin:0; padding:5px; color:inherit;
|
||||
background:#D1E5FE url("img/sky_blue_grid.gif") 0 0 repeat-x !important;
|
||||
border-color:#FDFDFD #A4BED4 #A4BED4 #FDFDFD;
|
||||
border-width:1px; border-style:solid;
|
||||
}
|
||||
.ezModifiedCell{ background:transparent url(../bg_mod_cell.png) 0 0 no-repeat !important; }
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow td{ background:#D9E8FB; border-top:1px solid #FDFDFD; border-bottom:1px solid #A4BED4 !important; color:#000 !important; }
|
||||
.ezSelectedRow{ background:#D1E5FE url("img/sky_blue_grid.gif") 0 0 repeat-x !important; color:#000; }
|
||||
td.ezActiveCell{
|
||||
background-color:#fff !important; color:#000 !important;
|
||||
font-weight:bold; font-style:italic; border-bottom:0;
|
||||
border-top:1px solid #FDFDFD !important;
|
||||
border-left:1px solid #A4BED4 !important;
|
||||
border-right:1px solid #A4BED4 !important;
|
||||
}
|
||||
.ezUnselectable{
|
||||
-moz-user-select: -moz-none;
|
||||
-khtml-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
/* Editors */
|
||||
.ezInputEditor{ width:100%; height:auto; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:0; }
|
||||
.ezTextareaEditor{ width:100%; height:25px; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:0; overflow:auto; }
|
||||
.ezSelectEditor{ width:100%; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:1px solid #AACCF6; }
|
||||
select[multiple="multiple"].ezSelectEditor{ height:35px; }
|
||||
|
||||
/* Command type editor */
|
||||
.ezCommandEditor button{
|
||||
margin:2px !important; background:#D1E5FE;
|
||||
border:1px solid #A4BED4;
|
||||
font-size:12px !important;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
.ezCommandEditor button img{ vertical-align:middle; margin:2px; }
|
||||
|
||||
/* Utils */
|
||||
.ezOpacity{
|
||||
filter:alpha(opacity=60); /* for IE */
|
||||
opacity:0.6; /* CSS3 standard */
|
||||
}
|
||||
.alignLeft{ text-align:left; }
|
||||
.alignCenter{ text-align:center; }
|
||||
.alignRight{ text-align:right; }
|
BIN
dist/extensions/ezEditTable/themes/skyblue/img/sky_blue_grid.gif
vendored
Normal file
After Width: | Height: | Size: 554 B |
2
dist/filtergrid.css
vendored
|
@ -1,6 +1,6 @@
|
|||
/*------------------------------------------------------------------------
|
||||
- TableFilter stylesheet by Max Guglielmi
|
||||
- (build date: Sat Apr 04 2015 19:09:58)
|
||||
- (build date: Mon Apr 06 2015 18:41:27)
|
||||
- Edit below for your projects' needs
|
||||
------------------------------------------------------------------------*/
|
||||
|
||||
|
|
9509
dist/tablefilter.js
vendored
2049
libs/ezEditTable/docs/doc.html
Normal file
154
libs/ezEditTable/docs/doc_class.html
Normal file
|
@ -0,0 +1,154 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_constructor" id="ez_constructor"></a>
|
||||
<h3>Constructor</h3>
|
||||
<h3><code>EditTable(id, startRow, config);</code></h3>
|
||||
<table id="tblConstructor" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Parameter</th>
|
||||
|
||||
<th>Type</th>
|
||||
<th>Description</th>
|
||||
<th>Remarks</th>
|
||||
<th>Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>id</strong></td>
|
||||
<td>string</td>
|
||||
<td>id of the <code>table</code> element</td>
|
||||
<td> </td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId");</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>startRow</strong> </td>
|
||||
<td>number</td>
|
||||
<td>index of the first row from which row selection can start</td>
|
||||
<td>optional parameter</td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId", 2);</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>config</strong></td>
|
||||
<td>object</td>
|
||||
<td> configuration object</td>
|
||||
<td>optional parameter</td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId", 2, { editable: true });</code></td>
|
||||
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
<hr/>
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
599
libs/ezEditTable/docs/doc_methods.html
Normal file
|
@ -0,0 +1,599 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_methods" id="ez_methods"></a>
|
||||
<h3>General Public Methods</h3>
|
||||
<table id="tblMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
|
||||
<th width="200">Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
|
||||
<td>EditTable object initialisation</td>
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br>
|
||||
myET.editable = true;<br />
|
||||
... <br />
|
||||
myET.Init();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetCellsNb( rowIndex )</strong></td>
|
||||
<td>returns number of cells of a specified row</td>
|
||||
<td> </td>
|
||||
<td><code> myET.GetCellsNb(4);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr class="newBg">
|
||||
<td><strong>GetRowsNb()</strong></td>
|
||||
<td>returns total number of rows</td>
|
||||
<td> </td>
|
||||
<td><code>myET.GetRowsNb();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRow(e)</strong></td>
|
||||
|
||||
<td>returns the DOM row element for a given event</td>
|
||||
<td> </td>
|
||||
<td><code>function myFunction(e){ var clickedRow = myET.GetRow(e); }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRowByIndex( rowIndex )</strong></td>
|
||||
<td>returns the DOM row element for a given row index</td>
|
||||
|
||||
<td> </td>
|
||||
<td> <code>myET.GetRowByIndex(5);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetCell(e)</strong></td>
|
||||
<td>returns the DOM cell element for a given event</td>
|
||||
<td> </td>
|
||||
|
||||
<td> <code>function myFunction(e){ var clickedCell = myET.GetCell(e);
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsSelectable()</strong></td>
|
||||
<td>checks if table rows are selectable and returns a boolean </td>
|
||||
<td> </td>
|
||||
<td><code>myET.IsSelectable();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsEditable()</strong></td>
|
||||
<td>checks if table is editable and returns a boolean </td>
|
||||
<td> </td>
|
||||
<td><code>myET.IsEditable();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ClearSelections()</strong></td>
|
||||
|
||||
<td>clears current row(s) and/or cell selection</td>
|
||||
<td> </td>
|
||||
<td> <code>myET.ClearSelections();</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
<hr/>
|
||||
|
||||
<a name="ez_selection_methods" id="ez_selection_methods"></a>
|
||||
<h3>Selection Public Methods</h3>
|
||||
<table id="tblSelectionMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
<td>Selection object initialisation</td>
|
||||
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br />
|
||||
... <br />
|
||||
myET.Selection.Init();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Set()</strong></td>
|
||||
|
||||
<td>enables selection feature</td>
|
||||
<td> </td>
|
||||
<td><code> myET.Selection.Set();</code></td>
|
||||
</tr>
|
||||
<tr class="newBg">
|
||||
<td><strong>Remove()</strong></td>
|
||||
<td> disables selection feature</td>
|
||||
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.Remove();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SetEvents()</strong></td>
|
||||
<td>sets click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.SetEvents();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>RemoveEvents()</strong></td>
|
||||
<td>removes click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.RemoveEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveRow()</strong></td>
|
||||
|
||||
<td>returns the active row element, that is, the row currently selected</td>
|
||||
<td> </td>
|
||||
<td> <code>var activeRow = myET.Selection.GetActiveRow();<br>
|
||||
if(activeRow){ ... }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveCell()</strong></td>
|
||||
|
||||
<td>returns the active cell element, that is, the cell currently selected</td>
|
||||
<td> </td>
|
||||
<td><code>var activeCell = myET.Selection.GetActiveCell();<br>
|
||||
if(activeCell){ ... }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetSelectedRows()</strong></td>
|
||||
|
||||
<td>returns an array of the row elements currently selected, if selection
|
||||
model is multiple</td>
|
||||
<td>returns: <br>
|
||||
[rowobject, rowobject, rowobject, ... rowobject] </td>
|
||||
<td> <code>var selRows = myET.Selection.GetSelectedRows();<br>
|
||||
if(selRows.length > 0){ ... }</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetSelectedValues()</strong></td>
|
||||
<td>returns an array containing a collection of selected rows values
|
||||
</td>
|
||||
<td>returns: [<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
...<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3']<br>
|
||||
] </td>
|
||||
<td><code>var selValues = myET.Selection.GetSelectedValues();<br>
|
||||
if(selValues.length > 0){<br>
|
||||
|
||||
var firstValueOfFirstSelectedRow = selValues[0][0];<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveRowValues()</strong></td>
|
||||
<td>returns an array containing the cell values of active row</td>
|
||||
<td>returns ['value 0', 'value 1', 'value 2', ... 'value 3']</td>
|
||||
|
||||
<td><code>var activeValues = myET.Selection.GetActiveRowValues();<br>
|
||||
if(activeValues.length > 0){ ... } </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRowValues( row )</strong></td>
|
||||
<td>returns an array containing the cell values of a given row, it accepts
|
||||
only a row DOM element</td>
|
||||
|
||||
<td>returns ['value 0', 'value 1', 'value 2', ... 'value 3'] </td>
|
||||
<td> <p><code>var myRow = myET.GetRowByIndex(7);<br>
|
||||
if(myRow){ <br>
|
||||
myRowValues = myET.Selection.GetRowValues(myRow);<br>
|
||||
</code><code>}</code></p></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRowByIndex( rowIndex )</strong></td>
|
||||
<td>selects a row for a given row index</td>
|
||||
<td> </td>
|
||||
<td><code> myET.Selection.SelectRowByIndex(9);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRowsByIndexes( rowIndexes )</strong> <sup>new</sup></td>
|
||||
<td>selects rows for a given array of row indexes</td>
|
||||
<td>Multiple selection needs to be active (selection_model: 'multiple')</td>
|
||||
<td><code> myET.Selection.SelectRowsByIndexes([2, 7, 9, 12]);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRow( row )</strong></td>
|
||||
<td>selects given row element</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
if(myRow){<br>
|
||||
myET.Selection.SelectRow(myRow);<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>DeselectRow( row )</strong></td>
|
||||
<td>deselects given row element</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
if(myET.Selection.IsRowSelected(myRow)){<br>
|
||||
|
||||
myET.Selection.DeselectRow(myRow);<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SelectCell( cell )</strong></td>
|
||||
<td>selects given cell element</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
if(myCell) myET.Selection.SelectCell(myCell);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>DeselectCell( cell )</strong></td>
|
||||
<td>deselects given cell element</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
if(myCell) myET.Selection.DeselectCell(myCell);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ClearSelections()</strong></td>
|
||||
<td>clears current row(s) and/or cell selection</td>
|
||||
<td>The general <code>ClearSelections()</code> invokes this method (<code>
|
||||
myET</code><code>.ClearSelections</code>() )</td>
|
||||
|
||||
<td><code>myET.Selection.ClearSelections();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsRowSelected( row )</strong></td>
|
||||
<td>determines if given row is selected and returns a boolean</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
|
||||
if(myET.Selection.IsRowSelected(myRow)){ ... } </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsCellSelected( cell )</strong></td>
|
||||
<td>determines if given cell is selected and returns a boolean</td>
|
||||
<td> </td>
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
|
||||
if(myET.Selection.IsCellSelected( myCell )){ ... }</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
<hr/>
|
||||
|
||||
<a name="ez_editable_methods" id="ez_editable_methods"></a>
|
||||
<h3>Editable Public Methods</h3>
|
||||
|
||||
<table id="tblEditableMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
<td>Editable object initialisation</td>
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br />
|
||||
|
||||
... <br />
|
||||
myET.Editable.Init();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Set()</strong></td>
|
||||
<td>enables inline editing feature</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code> myET.Editable.Set();</code></td>
|
||||
</tr>
|
||||
<tr class="newBg">
|
||||
<td><strong>Remove()</strong></td>
|
||||
<td> disables inline editing feature</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.Remove();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SetEvents()</strong></td>
|
||||
<td>sets click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.SetEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>RemoveEvents()</strong></td>
|
||||
|
||||
<td>removes click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.RemoveEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetModifiedRows()</strong></td>
|
||||
<td>returns an array containing the modified rows objects</td>
|
||||
|
||||
<td>returns: <br>
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, false, ...]<br>
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, false, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td> <p><code>var modRowObjs = myET.Editable.GetModifiedRows();<br>
|
||||
for(var i=0; i<modRowObjs.length; i++){<br>
|
||||
var rowIndex = modRowObjs[i][0]; //int<br>
|
||||
var obj = modRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
} </code></p></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetAddedRows()</strong></td>
|
||||
<td>returns an array containing the added rows objects</td>
|
||||
|
||||
<td>returns: <br>
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, true, ...]<br>
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, true, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td><code>var addRowObjs = myET.Editable.GetAddedRows();<br>
|
||||
for(var i=0; i<addRowObjs.length; i++){<br>
|
||||
var rowIndex = addRowObjs[i][0]; //int<br>
|
||||
var obj = addRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetDeletedRows()</strong></td>
|
||||
<td>returns an array containing the deleted rows objects</td>
|
||||
<td>returns: <br>
|
||||
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
modified: [false, false, ...]<br>
|
||||
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [false, false, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td> <code>var delRowObjs = myET.Editable.GetDeletedRows();<br>
|
||||
for(var i=0; i<delRowObjs.length; i++){<br>
|
||||
var rowIndex = delRowObjs[i][0]; //int<br>
|
||||
var obj = delRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitEditedRows()</strong></td>
|
||||
<td>submits edited rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
|
||||
<td>modified rows objects are sent to server (uri property in 'update'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options)</td>
|
||||
<td><p><code>function SaveEditedRows(){<br>
|
||||
myET.Editable.SubmitEditedRows();<br>
|
||||
}</code></p>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitAddedRows()</strong></td>
|
||||
<td>submits added rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td>added rows objects are sent to server (uri property in 'insert'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options)</td>
|
||||
<td><code>function SaveAddedRows(){
|
||||
myET.Editable.SubmitAddeddRows();
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitDeletedRows()</strong></td>
|
||||
<td>submits deleted rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td>deleted rows objects are sent to server (uri property in 'delete'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options). A
|
||||
confirmation prompt appears before sending data to server</td>
|
||||
|
||||
<td> <p><code>function DeleteSelectedRows(){
|
||||
myET.Editable.SubmitDeletedRows();
|
||||
}</code></p></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitAll()</strong> <sup>new</sup></td>
|
||||
<td>submits added and edited rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td></td>
|
||||
<td><code>function SubmitAll(){ myET.Editable.SubmitAll(); }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>AddNewRow()</strong></td>
|
||||
<td>adds a row to the table</td>
|
||||
|
||||
<td></td>
|
||||
<td><code>myET.Editable.AddNewRow();</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
515
libs/ezEditTable/docs/doc_properties.html
Normal file
|
@ -0,0 +1,515 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_properties" id="ez_properties"></a>
|
||||
<h3>General Public Properties</h3>
|
||||
<table id="tblProps" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>id</strong></td>
|
||||
<td>string</td>
|
||||
<td>returns the HTML table's id used by the EditTable object</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.id );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>table</strong></td>
|
||||
<td>HTMLTableElement</td>
|
||||
<td>returns the HTML table element used by the EditTable object</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.table );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>config</strong></td>
|
||||
<td>object</td>
|
||||
<td>returns the EditTable configuration object (literal object)</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.config );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>startRow</strong></td>
|
||||
<td>number</td>
|
||||
<td>index of the first row from which row selection can start</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.startRow );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>nbCells</strong></td>
|
||||
<td>number</td>
|
||||
<td>returns the number of table columns</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.nbCells );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>selection</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables selection model</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.selection = false;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>keyNav</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables keyboard navigation</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.keyNav = false;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>editable</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables inline editing</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.editable = true;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>tableCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class of the table element</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.tableCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>unselectableCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class that makes the table text unselectable</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.unselectableCss );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>activityIndicatorCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class to be applied to the table in order to indicate
|
||||
server activity </td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.activityIndicatorCss );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>basePath</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the path to the script's directory</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.basePath );</code></td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
<a name="ez_selection_properties" id="ez_selection_properties"></a>
|
||||
<h3>Selection Public Properties</h3>
|
||||
<table id="tblSelectionProps" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>selectionModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the selection model: "single" or "multiple"</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'single' or 'multiple'</td>
|
||||
|
||||
<td><code>myET.selectionModel = 'multiple';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>defaultSelection</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the selection type</td>
|
||||
<td>use it as getter or setter - 3 possible values: 'row', 'cell' or
|
||||
'both'</td>
|
||||
|
||||
<td><code>myET.defaultSelection = 'both';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>keySelection</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disable multiple selection by using Ctrl and Shift keys
|
||||
</td>
|
||||
<td>use it as getter or setter - select multiple rows by holding Ctrl
|
||||
or Shift key down, only if selection model is 'multiple'</td>
|
||||
|
||||
<td><code>myET.keySelection = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectRowAtStart</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>first row is selected at start if set true</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.selectRowAtStart = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>rowIndexAtStart</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines which row has to be selected at start</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.rowIndexAtStart = 5;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>scrollIntoView</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>If set true selected row scrolls into view; useful when row is selected
|
||||
by using keyboard</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.scrollIntoView = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>activeRowCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for active row</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.activeRowCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectedRowCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for selected rows</td>
|
||||
<td>use it as getter or setter - only if 'multiple' selection model
|
||||
is enabled</td>
|
||||
|
||||
<td><code>myET.selectedRowCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>activeCellCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for active cell</td>
|
||||
<td>use it as getter or setter - only if 'cell' or 'both' selection
|
||||
type is enabled</td>
|
||||
|
||||
<td><code>myET.activeCellCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>nbRowsPerPage</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines number of rows to jump when PgDown or PgUp keys are pressed</td>
|
||||
<td>use it as getter or setter - specify a huge number to jump straight
|
||||
to 1st or last row (1000)</td>
|
||||
|
||||
<td><code>myET.nbRowsPerPage = 1000;</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
<a name="ez_editable_properties" id="ez_editable_properties"></a>
|
||||
<h3>Editable Public Properties</h3>
|
||||
<table id="tblEditableProps" cellspacing="0" class="ezEditableTable" >
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>editorModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the editor model</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'cell' or 'row'</td>
|
||||
|
||||
<td><code>myET.editorModel = 'row';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>openEditorAction</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines which mouse action opens the inline editing feature</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'dblclick', 'click'</td>
|
||||
|
||||
<td><code>myET.openEditorAction = 'click';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ajax</strong> <sup>new</sup></td>
|
||||
<td>boolean</td>
|
||||
<td>enables AJAX requests (default: true if jQuery is detected)</td>
|
||||
<td>it is enabled if jQuery is detected and the <code>ajax</code> property is
|
||||
not explicitly set <code>false</code></td>
|
||||
<td><code>myET.ajax = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>inputEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>defines the css class for 'input' type editors</td>
|
||||
<td>use it as getter or setter - select multiple rows by holding Ctrl
|
||||
or Shift key down, only if selection model is 'multiple'</td>
|
||||
|
||||
<td><code>myET.inputEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>textareaEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>defines the css class for 'textarea' type editors</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.textareaEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectEditorCss</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines the css class for 'input' type editors</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.selectEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>commandEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>css class applied to command editor buttons container</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.commandEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>modifiedCellCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>css class applied to modified cells</td>
|
||||
<td>use it as getter or setter - this css class shows the green small
|
||||
triangle in the left-upper corner of the cell</td>
|
||||
|
||||
<td><code>myET.modifiedCellCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>cellEditors</strong></td>
|
||||
<td>array</td>
|
||||
<td>array defining the editor configuration for each column</td>
|
||||
<td>use it as getter or setter - the number of editors must be equal
|
||||
to the number of columns. Refer to <a href="doc.html#ez_cell_editors">Cell
|
||||
editors properties</a> for details about editors' configuration</td>
|
||||
<td><code>myET.cellEditors = [<br>
|
||||
{ type: 'select' },<br>
|
||||
{ type: 'textarea' },<br>
|
||||
{ type: 'input' },<br>
|
||||
{ type: 'uploader' },<br>
|
||||
{ type: 'none' }, <br>
|
||||
{ type: 'command' }<br>
|
||||
];</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>actions</strong></td>
|
||||
<td>object</td>
|
||||
<td>server actions configuration object </td>
|
||||
<td>use it as getter or setter - Refer to <a href="doc.html#ez_actions">actions
|
||||
properties</a> for details about server actions configuration</td>
|
||||
|
||||
<td><code>myET.actions = {<br>
|
||||
'update': { <br>
|
||||
uri: 'updateRow.php', submit_method: 'form', form_method: 'POST',
|
||||
<br>
|
||||
param_names: ['iso', 'name', 'printablename', 'iso3', 'code'] },<br>
|
||||
'insert': { <br>
|
||||
uri: 'insertRow.php', submit_method: 'form', form_method: 'POST',
|
||||
<br>
|
||||
|
||||
param_names: ['iso', 'name', 'printablename', 'iso3', 'code'] },<br>
|
||||
'delete': { <br>
|
||||
uri: 'script.delete.php', submit_method: 'script', bulk_delete: true
|
||||
}<br>
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSave</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>saves automatically pending changes upon selection change</td>
|
||||
<td><code>editable</code> property needs to be activated (default: true if editable is on)</td>
|
||||
<td><code>myET.autoSave = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSaveModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>determines when modified and/or added data is saved, upon row or cell selection change (default: 'row')</td>
|
||||
<td>2 possible values 'row' or 'cell'</td>
|
||||
<td><code>myET.autoSaveModel = 'cell';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSaveType</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines if only insertions or updates, or both are saved automatically (default: 'both')</td>
|
||||
<td>3 possible values 'insert', 'update' or 'both'</td>
|
||||
<td><code>myET.autoSaveType = 'update';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>editableOnKeystroke</strong> <sup>new</sup></td>
|
||||
<td>boolean</td>
|
||||
<td>makes the inline cell editor appear upon keystroke (default: false)</td>
|
||||
<td>only if edition is enabled and <code>editorModel</code> is set to <code>'cell'</code> and
|
||||
<code>selectionModel</code> to <code>'single'</code></td>
|
||||
<td><code>myET.editableOnKeystroke = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>newRowPrefix</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the prefix for new added row ids (default: 'tr')</td>
|
||||
<td>prefix should match the prefix assigned to already existing rows</td>
|
||||
<td><code>myET.newRowPrefix = 'row';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>formSubmitInterval</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines the interval in ms separating rows data submissions (default: 50)</td>
|
||||
<td>by default the script submits a single form for each modified row. Depending on ISPs
|
||||
security policies, multiple submissions to same page are simply blocked by the server.
|
||||
This interval can be useful to fine tune the form submissions when those server restrictions apply.</td>
|
||||
<td><code>myET.formSubmitInterval = 750;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>newRowPos</strong> <sup>new</sup></td>
|
||||
<td>string or number</td>
|
||||
<td>defines the row position of a newly created row (default: 'top')</td>
|
||||
<td>2 possible values as a string: 'top' or 'bottom', and as an integer:
|
||||
any number >= 0 and <= total number of rows. If the supplied numeric
|
||||
value exceeds the total number of rows then the script fallback to default
|
||||
value 'top'</td>
|
||||
<td><code>myET.newRowPos = 'bottom';</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
207
libs/ezEditTable/docs/doc_utilities.html
Normal file
|
@ -0,0 +1,207 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>Utility Functions</h2>
|
||||
|
||||
|
||||
<table id="tblUtils" cellspacing="0" class="ezEditableTable" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> setEditTable( id, startRow, config )</strong></td>
|
||||
<td><p>Calls EditTable constructor and returns the EditTable object:</p>
|
||||
|
||||
<ul>
|
||||
<li>id: table id (string)</li>
|
||||
<li>startRow (optional): index of the first row from which row selection
|
||||
can start (number)</li>
|
||||
<li>config (optional): configuration object (literal object)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code> var et = setEditTable('myTableId', 2, { editable: true });</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong> Get(id)</strong></td>
|
||||
<td><p>this is a <code>document.getElementById()</code> shortcut:</p>
|
||||
<ul>
|
||||
<li>id: id of the element (string)</li>
|
||||
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code> var myElm = et.Get('myId');</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Tag(o, tagname)</strong></td>
|
||||
<td><p>this is just a <code>getElementsByTagName()</code> shortcut:</p>
|
||||
|
||||
<ul>
|
||||
<li>o: target element (DOM element)</li>
|
||||
<li>tagname: tag to search for (string)</li>
|
||||
</ul>
|
||||
<p>It returns an array</p></td>
|
||||
<td> </td>
|
||||
<td><code>var myTables = et.Tag(document, 'table');</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetText(n)</strong></td>
|
||||
<td><p>returns the text of given a node and its child nodes:</p>
|
||||
<ul>
|
||||
<li>n: node (DOM element)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var tableText = et.GetText( et.Tag(document,'table' )[0]);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>CreateElm(tag)</strong></td>
|
||||
<td><p>creates an html element with defined attributes:</p>
|
||||
<ul>
|
||||
<li>the html tag to create (string)</li>
|
||||
|
||||
<li>an unlimited # of arrays defining the attributes values ('attribute
|
||||
name','value' ['id','myId'])</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code>var myInput = et.CreateElm( 'input', ['id','myId'], ['value','Hello
|
||||
world'] );</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>CreateText(t)</strong></td>
|
||||
<td><p>this is just a <code>document.createTextNode</code> shortcut:</p>
|
||||
|
||||
<ul>
|
||||
<li>t: text to generate (string)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code>var myText = et.CreateText( 'Hello world' );</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsArray(obj)</strong></td>
|
||||
|
||||
<td><p>checks if passed param is an array. It returns a boolean</p></td>
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsArray([1,2,3]));</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsObj(obj)</strong></td>
|
||||
<td><p>checks if passed param is an object. It returns a boolean</p></td>
|
||||
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsObj({ text: 'hello'}));</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsFn(fn)</strong></td>
|
||||
<td><p>checks if passed param is a function. It returns a boolean</p></td>
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsFn(function(){ var a=0; }));</code></td>
|
||||
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<hr/>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
473
libs/ezEditTable/docs/index.html
Normal file
|
@ -0,0 +1,473 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk01{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
<h1>ezEditTable</h1>
|
||||
<h2>Description</h2>
|
||||
<p>
|
||||
ezEditTable is a javascript code aimed at enhancing regular
|
||||
HTML tables by adding features such as inline editing components, advanced
|
||||
selection and keyboard navigation. With just a line of code you can easily
|
||||
convert a regular HTML table in an advanced editable and selectable grid control.
|
||||
</p>
|
||||
<h3>Main features</h3>
|
||||
<ul>
|
||||
<li>Attach to an existing HTML table</li>
|
||||
<li>Advanced selection model</li>
|
||||
<li>Extended keyboard navigation</li>
|
||||
<li>Inline cell or row editing</li>
|
||||
<li>Insert and remove rows</li>
|
||||
<li>Send changes to server via GET or POST form submission, AJAX requests or
|
||||
by script injection in the head section of the document (only GETs)</li>
|
||||
<li>Integration with any server-side technology as this is a pure client-side solution</li>
|
||||
<li>Callbacks for all events, and delegates for most actions</li>
|
||||
<li>Based on plain javascript and dependent on jQuery only for performing AJAX requests</li>
|
||||
<li>Exhaustive documentation and API</li>
|
||||
<li>Easy setup and easy customisable themes</li>
|
||||
</ul>
|
||||
|
||||
<h2>Installation
|
||||
<span class="floatRight fontSize12px">
|
||||
<a href="starter.html">Starter</a>
|
||||
</span>
|
||||
</h2>
|
||||
<p>To install <strong>ezEditTable</strong> unzip the download package and then include the following
|
||||
scripts and stylesheet files in the <code>head</code> section of your page:</p>
|
||||
|
||||
<pre>
|
||||
<link href="ezEditTable/ezEditTable.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="ezEditTable/ezEditTable.js"></script>
|
||||
</pre>
|
||||
|
||||
<p>Make sure the table you'd like to make editable or selectable
|
||||
has an unique <code>id</code> and a <code>thead</code> and <code>tbody</code>
|
||||
sections.</p>
|
||||
<p>Here you have an example of a regular html table: </p>
|
||||
<table border="1" cellspacing="0" cellpadding="2" width="80%">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p>Below the same table enhanced by the script (<code>id="table1"</code>),
|
||||
click to select a row or use keys to move the selection:</p>
|
||||
<table id="table1" cellspacing="0" cellpadding="0" width="80%">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var et = new EditTable('table1');
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
<p>There are 2 different ways to call the script:</p>
|
||||
<ul>
|
||||
|
||||
|
||||
<li>invoke the <code>setEditTable</code> function, which returns a EditTable object: </li>
|
||||
</ul>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var et = setEditTable("table1");
|
||||
</script> </pre>
|
||||
|
||||
<ul>
|
||||
<li>instanciate the <strong><code>EditTable</code></strong> object: </li>
|
||||
</ul>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var et = new EditTable('table1');
|
||||
et.Init();
|
||||
</script> </pre>
|
||||
<p>If your document contains several tables (like this page), it is important
|
||||
to define unique ids, otherwise the script will not work properly. </p>
|
||||
|
||||
<p>The <code>setEditTable()</code> function or the <code>EditTable</code>
|
||||
class accepts 2 additional parameters that will be explained in the next
|
||||
tables. In the example below, by specifing a row number as a "start"
|
||||
row, we tell the script from which row can start the selection, this is
|
||||
helpful when the <code>tbody</code> and <code>thead</code> sections are not defined: </p>
|
||||
|
||||
|
||||
<table id="table2" cellspacing="0" cellpadding="0" >
|
||||
<tr>
|
||||
<td colspan="5"><strong>This is the table caption </strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var et02 = new EditTable("table2",2);
|
||||
et02.Init();
|
||||
</script>
|
||||
|
||||
<pre class="brush: js;">var et02 = setEditTable("table2", 2);</pre>
|
||||
|
||||
<p>or</p>
|
||||
|
||||
<pre class="brush: js;">var et02 = new EditTable("table2", 2);
|
||||
et02.Init();</pre>
|
||||
<p>By default, the script adds a single row selection feature to the table.
|
||||
You could decide to also add a cell selection feature and make the cells
|
||||
editable, double-click on a cell to see:</p>
|
||||
|
||||
<table id="table3" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td colspan="5"><strong>This is the table caption </strong></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th style="width:100px">From</th>
|
||||
<th style="width:100px">Destination</th>
|
||||
<th style="width:100px">Road Distance (km)</th>
|
||||
<th style="width:100px">By Air (hrs)</th>
|
||||
<th style="width:80px">By Rail (hrs)</th>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
};
|
||||
var et03 = new EditTable("table3", 2, table3Config);
|
||||
et03.Init();
|
||||
</script>
|
||||
<p>To do that you just need to declare a <em>literal object</em> (configuration
|
||||
object) in which you specify the features you would like to enable:</p>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
}
|
||||
var et03 = setTableEdit("table3", 2, table3Config);
|
||||
</script></pre>
|
||||
<p>or</p>
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
}
|
||||
var et03 = new EditTable("table3", 2 ,table3Config);
|
||||
et03.Init();
|
||||
</script></pre>
|
||||
|
||||
<p>You can name the <em>configuration object</em> as you want, but don't forget
|
||||
to add it to the parameters of the <code>setEditTable</code>() function
|
||||
or <code>EditTable</code> class. It is important to respect the syntax and
|
||||
naming convention as shown above. You will find an exhaustive list of properties
|
||||
in the <a href="doc.html">documentation</a> section. </p>
|
||||
<h2>Documentation</h2>
|
||||
|
||||
|
||||
<p>For more information about the script's configuration and API check out
|
||||
the <a href="doc.html">documentation</a> and the
|
||||
available online <a href="http://edittable.free.fr/demos.php">demos</a>.</p>
|
||||
|
||||
<hr class="clearBoth" />
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
1082
libs/ezEditTable/docs/samples.html
Normal file
195
libs/ezEditTable/docs/starter.html
Normal file
|
@ -0,0 +1,195 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily - Starter page - by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>Starter</h1>
|
||||
<p>
|
||||
<a href="index.html">← Documentation</a>
|
||||
</p>
|
||||
<div>
|
||||
<table id="demo" cellspacing="0" cellpadding="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<script language="javascript" type="text/javascript">
|
||||
var config = {
|
||||
selection: true,
|
||||
default_selection: 'both'
|
||||
};
|
||||
var et = new EditTable('demo', config);
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<h4>Source code of the page:</h4>
|
||||
<pre>
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily - Starter page - by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h1>ezEditTable Starter</h1>
|
||||
|
||||
<table id="demo" cellspacing="0" cellpadding="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<script language="javascript" type="text/javascript">
|
||||
var config = {
|
||||
selection: true,
|
||||
default_selection: 'both'
|
||||
};
|
||||
var et = new EditTable('demo', config);
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
86
libs/ezEditTable/ezEditTable-uncompressed.css
Normal file
|
@ -0,0 +1,86 @@
|
|||
/*====================================================
|
||||
- ezEditTable global stylesheet
|
||||
- Edit classes below for your projects' needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
padding:0; color:#000;
|
||||
border-collapse:collapse;
|
||||
font:12px/13px arial, tahoma, helvetica, sans-serif !important;
|
||||
}
|
||||
.ezEditableTable th, .ezEditableTable td{
|
||||
margin:0; padding:5px;
|
||||
color:inherit;
|
||||
border:1px solid #ccc !important;
|
||||
}
|
||||
.ezEditableTable th{
|
||||
background:#EBECEE !important;
|
||||
}
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow{ background-color:#2852A8 !important; color:#fff; }
|
||||
.ezSelectedRow{ background-color:#316AC5; color:#fff; }
|
||||
.ezActiveCell{
|
||||
background-color:#D9E8FB !important;
|
||||
color:#000 !important; font-weight:bold;
|
||||
}
|
||||
.ezUnselectable{
|
||||
-moz-user-select: -moz-none;
|
||||
-khtml-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
/* Cell editors */
|
||||
.ezInputEditor{ width:95%; height:auto; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezTextareaEditor{ width:95%; height:35px; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezSelectEditor{ width:100%; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezModifiedCell{ background:transparent url(themes/bg_mod_cell.png) 0 0 no-repeat; }
|
||||
select[multiple="multiple"].ezSelectEditor{ height:35px; }
|
||||
/* Command type editor */
|
||||
.ezCommandEditor{ margin:2px; }
|
||||
.ezCommandEditor button{
|
||||
font-size:10px;
|
||||
border:1px solid #ccc;
|
||||
background:#fff; margin:1px;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
/* Uploader editor */
|
||||
.ezUploaderEditor{
|
||||
position:absolute; display:inline;
|
||||
margin:15px 0 0 0px;
|
||||
border:1px solid #ccc; padding:5px;
|
||||
background:#fff; color:#000; z-index:10000;
|
||||
border-radius:4px;
|
||||
-moz-border-radius:4px;
|
||||
-webkit-border-radius:4px;
|
||||
box-shadow:3px 3px 2px #888;
|
||||
-moz-box-shadow:3px 3px 2px #888;
|
||||
-webkit-box-shadow:3px 3px 2px #888;
|
||||
}
|
||||
.ezUploaderEditor button{
|
||||
font-size:10px;
|
||||
border:1px solid #ccc;
|
||||
background:#fff; margin:1px;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
.ezUploaderEditorOutput{ }
|
||||
.ezUploaderEditorDisplay{
|
||||
display:none; position:relative;
|
||||
max-width:800px; max-height:600px;
|
||||
overflow:auto; border:0;
|
||||
background:#fff; padding:5px; margin:5px;
|
||||
}
|
||||
|
||||
/* Utils */
|
||||
.ezOpacity{
|
||||
filter:alpha(opacity=60); /* for IE */
|
||||
opacity:0.6; /* CSS3 standard */
|
||||
}
|
||||
.alignLeft{ text-align:left; }
|
||||
.alignCenter{ text-align:center; }
|
||||
.alignRight{ text-align:right; }
|
||||
.icnImg{ border:0; }
|
2081
libs/ezEditTable/ezEditTable-uncompressed.js
Normal file
7
libs/ezEditTable/ezEditTable.css
Normal file
|
@ -0,0 +1,7 @@
|
|||
/*------------------------------------------------------------------------
|
||||
- ezEditTable stylesheet by Max Guglielmi
|
||||
- (build date: Sun Mar 15 2015 15:46:31)
|
||||
- Edit below for your projects' needs
|
||||
------------------------------------------------------------------------*/
|
||||
|
||||
.ezEditableTable{padding:0;color:#000;border-collapse:collapse;font:12px/13px arial,tahoma,helvetica,sans-serif!important}.ezEditableTable th,.ezEditableTable td{margin:0;padding:5px;color:inherit;border:1px solid #ccc!important}.ezEditableTable th{background:#EBECEE!important}.ezActiveRow{background-color:#2852A8!important;color:#fff}.ezSelectedRow{background-color:#316AC5;color:#fff}.ezActiveCell{background-color:#D9E8FB!important;color:#000!important;font-weight:700}.ezUnselectable{-moz-user-select:-moz-none;-khtml-user-select:none;-webkit-user-select:none;-o-user-select:none;user-select:none}.ezInputEditor{width:95%;height:auto;font-size:inherit;border:1px solid #AACCF6}.ezTextareaEditor{width:95%;height:35px;font-size:inherit;border:1px solid #AACCF6}.ezSelectEditor{width:100%;font-size:inherit;border:1px solid #AACCF6}.ezModifiedCell{background:transparent url(themes/bg_mod_cell.png) 0 0 no-repeat}select[multiple=multiple].ezSelectEditor{height:35px}.ezCommandEditor{margin:2px}.ezCommandEditor button{font-size:10px;border:1px solid #ccc;background:#fff;margin:1px;border-radius:4px;-moz-border-radius:4px}.ezUploaderEditor{position:absolute;display:inline;margin:15px 0 0;border:1px solid #ccc;padding:5px;background:#fff;color:#000;z-index:10000;border-radius:4px;-moz-border-radius:4px;-webkit-border-radius:4px;box-shadow:3px 3px 2px #888;-moz-box-shadow:3px 3px 2px #888;-webkit-box-shadow:3px 3px 2px #888}.ezUploaderEditor button{font-size:10px;border:1px solid #ccc;background:#fff;margin:1px;border-radius:4px;-moz-border-radius:4px}.ezUploaderEditorOutput{}.ezUploaderEditorDisplay{display:none;position:relative;max-width:800px;max-height:600px;overflow:auto;border:0;background:#fff;padding:5px;margin:5px}.ezOpacity{filter:alpha(opacity=60);opacity:.6}.alignLeft{text-align:left}.alignCenter{text-align:center}.alignRight{text-align:right}.icnImg{border:0}
|
9
libs/ezEditTable/ezEditTable.js
Normal file
BIN
libs/ezEditTable/themes/bg_mod_cell.png
Normal file
After Width: | Height: | Size: 234 B |
23
libs/ezEditTable/themes/default/ezDefault.css
Normal file
|
@ -0,0 +1,23 @@
|
|||
/*====================================================
|
||||
- ezEditTable default theme stylesheet
|
||||
- Edit classes below for your project needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
border:0 !important;
|
||||
border-left:1px solid #99BBE8 !important;
|
||||
border-right:1px solid #99BBE8 !important;
|
||||
border-bottom:1px solid #99BBE8 !important;
|
||||
font:12px/13px arial, tahoma, helvetica, sans-serif !important;
|
||||
}
|
||||
.ezEditableTable th, td{ border:1px solid #C5D3EC !important; }
|
||||
.ezEditableTable th{
|
||||
background:transparent url(img/bg_col_header.gif) 0 -2px repeat-x !important;
|
||||
}
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow td{ background-color:#316AC5; color:#fff !important; }
|
||||
.ezSelectedRow{ background-color:#D9E8FB !important; border:1px dotted #909090 !important; color:#000; }
|
||||
|
||||
/* Command type editor */
|
||||
.ezCommandEditor button{ border:1px solid #C5D3EC !important; }
|
BIN
libs/ezEditTable/themes/default/img/bg_col_header.gif
Normal file
After Width: | Height: | Size: 875 B |
BIN
libs/ezEditTable/themes/icn_add.gif
Normal file
After Width: | Height: | Size: 398 B |
BIN
libs/ezEditTable/themes/icn_cross.png
Normal file
After Width: | Height: | Size: 655 B |
BIN
libs/ezEditTable/themes/icn_del.gif
Normal file
After Width: | Height: | Size: 330 B |
BIN
libs/ezEditTable/themes/icn_edit.gif
Normal file
After Width: | Height: | Size: 342 B |
BIN
libs/ezEditTable/themes/icn_save.gif
Normal file
After Width: | Height: | Size: 375 B |
BIN
libs/ezEditTable/themes/icn_tick.png
Normal file
After Width: | Height: | Size: 537 B |
68
libs/ezEditTable/themes/skyblue/ezSkyBlue.css
Normal file
|
@ -0,0 +1,68 @@
|
|||
/*====================================================
|
||||
- ezEditTable SkyBlue theme stylesheet
|
||||
- Edit classes below for your project needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
padding:0; color:#000;
|
||||
font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important;
|
||||
border-right:1px solid #A4BED4;
|
||||
border-top:1px solid #A4BED4;
|
||||
border-left:1px solid #A4BED4;
|
||||
border-bottom:0;
|
||||
}
|
||||
.ezEditableTable td{
|
||||
margin:0; padding:5px; color:inherit;
|
||||
border-bottom:1px solid #A4BED4;
|
||||
border-left:0; border-top:0; border-right:0;
|
||||
}
|
||||
.ezEditableTable th{
|
||||
margin:0; padding:5px; color:inherit;
|
||||
background:#D1E5FE url("img/sky_blue_grid.gif") 0 0 repeat-x !important;
|
||||
border-color:#FDFDFD #A4BED4 #A4BED4 #FDFDFD;
|
||||
border-width:1px; border-style:solid;
|
||||
}
|
||||
.ezModifiedCell{ background:transparent url(../bg_mod_cell.png) 0 0 no-repeat !important; }
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow td{ background:#D9E8FB; border-top:1px solid #FDFDFD; border-bottom:1px solid #A4BED4 !important; color:#000 !important; }
|
||||
.ezSelectedRow{ background:#D1E5FE url("img/sky_blue_grid.gif") 0 0 repeat-x !important; color:#000; }
|
||||
td.ezActiveCell{
|
||||
background-color:#fff !important; color:#000 !important;
|
||||
font-weight:bold; font-style:italic; border-bottom:0;
|
||||
border-top:1px solid #FDFDFD !important;
|
||||
border-left:1px solid #A4BED4 !important;
|
||||
border-right:1px solid #A4BED4 !important;
|
||||
}
|
||||
.ezUnselectable{
|
||||
-moz-user-select: -moz-none;
|
||||
-khtml-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
/* Editors */
|
||||
.ezInputEditor{ width:100%; height:auto; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:0; }
|
||||
.ezTextareaEditor{ width:100%; height:25px; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:0; overflow:auto; }
|
||||
.ezSelectEditor{ width:100%; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:1px solid #AACCF6; }
|
||||
select[multiple="multiple"].ezSelectEditor{ height:35px; }
|
||||
|
||||
/* Command type editor */
|
||||
.ezCommandEditor button{
|
||||
margin:2px !important; background:#D1E5FE;
|
||||
border:1px solid #A4BED4;
|
||||
font-size:12px !important;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
.ezCommandEditor button img{ vertical-align:middle; margin:2px; }
|
||||
|
||||
/* Utils */
|
||||
.ezOpacity{
|
||||
filter:alpha(opacity=60); /* for IE */
|
||||
opacity:0.6; /* CSS3 standard */
|
||||
}
|
||||
.alignLeft{ text-align:left; }
|
||||
.alignCenter{ text-align:center; }
|
||||
.alignRight{ text-align:right; }
|
BIN
libs/ezEditTable/themes/skyblue/img/sky_blue_grid.gif
Normal file
After Width: | Height: | Size: 554 B |
|
@ -439,7 +439,7 @@ export class Paging{
|
|||
*/
|
||||
setPage(cmd){
|
||||
var tf = this.tf;
|
||||
if(!tf.hasGrid() || !this.paging){
|
||||
if(!tf.hasGrid() || !tf.paging){
|
||||
return;
|
||||
}
|
||||
var btnEvt = this.evt,
|
||||
|
|
|
@ -424,14 +424,14 @@ export default class TableFilter{
|
|||
f.ezEditTable_config.name : 'ezedittable';
|
||||
this.ezEditTableConfig.src = this.ezEditTableConfig['src']!==undefined ?
|
||||
f.ezEditTable_config.src :
|
||||
this.basePath+'ezEditTable/ezEditTable.js';
|
||||
this.basePath+'extensions/ezEditTable/ezEditTable.js';
|
||||
//ezEditTable stylesheet not imported by default as filtergrid.css
|
||||
//applies
|
||||
this.ezEditTableConfig.loadStylesheet =
|
||||
this.ezEditTableConfig['loadStylesheet']===true ? true : false;
|
||||
this.ezEditTableConfig.stylesheet =
|
||||
this.ezEditTableConfig['stylesheet'] ||
|
||||
this.basePath+'ezEditTable/ezEditTable.css';
|
||||
this.basePath+'extensions/ezEditTable/ezEditTable.css';
|
||||
this.ezEditTableConfig.stylesheetName =
|
||||
this.ezEditTableConfig['stylesheetName']!==undefined ?
|
||||
f.ezEditTable_config.stylesheetName : 'ezEditTableCss';
|
||||
|
@ -646,7 +646,8 @@ export default class TableFilter{
|
|||
|
||||
// Extensions registry
|
||||
this.Extensions = {
|
||||
sort: null
|
||||
sort: null,
|
||||
ezEditTable: null
|
||||
};
|
||||
|
||||
/*** TF events ***/
|
||||
|
@ -1193,7 +1194,7 @@ export default class TableFilter{
|
|||
this.setSort();
|
||||
}
|
||||
if(this.selectable || this.editable){
|
||||
this.SetEditable();
|
||||
this.setEditable();
|
||||
}
|
||||
|
||||
this.isFirstLoad = false;
|
||||
|
@ -1499,7 +1500,7 @@ export default class TableFilter{
|
|||
this.clearActiveColumns();
|
||||
}
|
||||
if(this.editable || this.selectable){
|
||||
this.RemoveEditable();
|
||||
this.removeEditable();
|
||||
}
|
||||
//this loop shows all rows and removes validRow attribute
|
||||
for(var j=this.refRow; j<this.nbRows; j++){
|
||||
|
@ -1754,15 +1755,15 @@ export default class TableFilter{
|
|||
- Sets selection or edition features by loading
|
||||
ezEditTable script by Max Guglielmi
|
||||
=====================================================*/
|
||||
SetEditable(){
|
||||
setEditable(){
|
||||
var ezEditConfig = this.ezEditTableConfig;
|
||||
if(this.isImported(ezEditConfig.src)){
|
||||
this._EnableEditable();
|
||||
this._enableEditable();
|
||||
} else {
|
||||
this.includeFile(
|
||||
ezEditConfig.name,
|
||||
ezEditConfig.src,
|
||||
this._EnableEditable
|
||||
this._enableEditable
|
||||
);
|
||||
}
|
||||
if(ezEditConfig.loadStylesheet &&
|
||||
|
@ -1777,7 +1778,7 @@ export default class TableFilter{
|
|||
/*====================================================
|
||||
- Removes selection or edition features
|
||||
=====================================================*/
|
||||
RemoveEditable(){
|
||||
removeEditable(){
|
||||
var ezEditTable = this.ezEditTable;
|
||||
if(ezEditTable){
|
||||
if(this.selectable){
|
||||
|
@ -1794,7 +1795,7 @@ export default class TableFilter{
|
|||
- Resets selection or edition features after
|
||||
removal
|
||||
=====================================================*/
|
||||
ResetEditable(){
|
||||
resetEditable(){
|
||||
var ezEditTable = this.ezEditTable;
|
||||
if(ezEditTable){
|
||||
if(this.selectable){
|
||||
|
@ -1806,10 +1807,8 @@ export default class TableFilter{
|
|||
}
|
||||
}
|
||||
|
||||
_EnableEditable(o){
|
||||
if(!o){
|
||||
o = this;
|
||||
}
|
||||
_enableEditable(o){
|
||||
if(!o){ o = this; }
|
||||
|
||||
//start row for EditTable constructor needs to be calculated
|
||||
var startRow,
|
||||
|
@ -1848,6 +1847,42 @@ export default class TableFilter{
|
|||
//Row navigation needs to be calculated according to TableFilter's
|
||||
//validRowsIndex array
|
||||
var onAfterSelection = function(et, selectedElm, e){
|
||||
var slc = et.Selection;
|
||||
//Next valid filtered row needs to be selected
|
||||
var doSelect = function(nextRowIndex){
|
||||
if(et.defaultSelection === 'row'){
|
||||
slc.SelectRowByIndex(nextRowIndex);
|
||||
} else {
|
||||
et.ClearSelections();
|
||||
var cellIndex = selectedElm.cellIndex,
|
||||
row = o.tbl.rows[nextRowIndex];
|
||||
if(et.defaultSelection === 'both'){
|
||||
slc.SelectRowByIndex(nextRowIndex);
|
||||
}
|
||||
if(row){
|
||||
slc.SelectCell(row.cells[cellIndex]);
|
||||
}
|
||||
}
|
||||
//Table is filtered
|
||||
if(o.validRowsIndex.length !== o.getRowsNb()){
|
||||
var r = o.tbl.rows[nextRowIndex];
|
||||
if(r){
|
||||
r.scrollIntoView(false);
|
||||
}
|
||||
if(cell){
|
||||
if(cell.cellIndex===(o.getCellsNb()-1) &&
|
||||
o.gridLayout){
|
||||
o.tblCont.scrollLeft = 100000000;
|
||||
}
|
||||
else if(cell.cellIndex===0 && o.gridLayout){
|
||||
o.tblCont.scrollLeft = 0;
|
||||
} else {
|
||||
cell.scrollIntoView(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
//table is not filtered
|
||||
if(!o.validRowsIndex){
|
||||
return;
|
||||
|
@ -1891,7 +1926,7 @@ export default class TableFilter{
|
|||
}
|
||||
}
|
||||
o._lastRowIndex = row.rowIndex;
|
||||
DoSelection(nextRowIndex);
|
||||
doSelect(nextRowIndex);
|
||||
} else {
|
||||
//If filtered row is valid, special calculation for
|
||||
//pgup/pgdown keys
|
||||
|
@ -1920,44 +1955,9 @@ export default class TableFilter{
|
|||
o._lastRowIndex = nextRowIndex;
|
||||
o._lastValidRowIndex = array.indexByValue(validIndexes,
|
||||
nextRowIndex);
|
||||
DoSelection(nextRowIndex);
|
||||
doSelect(nextRowIndex);
|
||||
}
|
||||
}
|
||||
|
||||
//Next valid filtered row needs to be selected
|
||||
var DoSelection = function(nextRowIndex){
|
||||
if(et.defaultSelection === 'row'){
|
||||
et.Selection.SelectRowByIndex(nextRowIndex);
|
||||
} else {
|
||||
et.ClearSelections();
|
||||
var cellIndex = selectedElm.cellIndex,
|
||||
row = o.tbl.rows[nextRowIndex];
|
||||
if(et.defaultSelection === 'both'){
|
||||
et.Selection.SelectRowByIndex(nextRowIndex);
|
||||
}
|
||||
if(row){
|
||||
et.Selection.SelectCell(row.cells[cellIndex]);
|
||||
}
|
||||
}
|
||||
//Table is filtered
|
||||
if(o.validRowsIndex.length !== o.getRowsNb()){
|
||||
var r = o.tbl.rows[nextRowIndex];
|
||||
if(r){
|
||||
r.scrollIntoView(false);
|
||||
}
|
||||
if(cell){
|
||||
if(cell.cellIndex===(o.getCellsNb()-1) &&
|
||||
o.gridLayout){
|
||||
o.tblCont.scrollLeft = 100000000;
|
||||
}
|
||||
else if(cell.cellIndex===0 && o.gridLayout){
|
||||
o.tblCont.scrollLeft = 0;
|
||||
} else {
|
||||
cell.scrollIntoView(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
//Page navigation has to be enforced whenever selected row is out of
|
||||
|
@ -1966,33 +1966,36 @@ export default class TableFilter{
|
|||
var row = et.defaultSelection !== 'row' ?
|
||||
selectedElm.parentNode : selectedElm;
|
||||
if(o.paging){
|
||||
if(o.nbPages>1){
|
||||
if(o.Cpt.paging.nbPages>1){
|
||||
var paging = o.Cpt.paging;
|
||||
//page length is re-assigned in case it has changed
|
||||
et.nbRowsPerPage = o.pagingLength;
|
||||
et.nbRowsPerPage = paging.pagingLength;
|
||||
var validIndexes = o.validRowsIndex,
|
||||
validIdxLen = validIndexes.length,
|
||||
pagingEndRow = parseInt(o.startPagingRow, 10) +
|
||||
parseInt(o.pagingLength, 10);
|
||||
pagingEndRow = parseInt(paging.startPagingRow, 10) +
|
||||
parseInt(paging.pagingLength, 10);
|
||||
var rowIndex = row.rowIndex;
|
||||
|
||||
if((rowIndex === validIndexes[validIdxLen-1]) &&
|
||||
o.currentPageNb!=o.nbPages){
|
||||
// o.SetPage('last');
|
||||
o.Cpt.paging.setPage('last');
|
||||
paging.currentPageNb!==paging.nbPages){
|
||||
console.log('last');
|
||||
paging.setPage('last');
|
||||
}
|
||||
else if((rowIndex == validIndexes[0]) &&
|
||||
o.currentPageNb!==1){
|
||||
// o.SetPage('first');
|
||||
o.Cpt.paging.setPage('first');
|
||||
paging.currentPageNb!==1){
|
||||
console.log('first');
|
||||
paging.setPage('first');
|
||||
}
|
||||
else if(rowIndex > validIndexes[pagingEndRow-1] &&
|
||||
rowIndex < validIndexes[validIdxLen-1]){
|
||||
// o.SetPage('next');
|
||||
o.Cpt.paging.setPage('next');
|
||||
console.log('next');
|
||||
paging.setPage('next');
|
||||
}
|
||||
else if(rowIndex < validIndexes[o.startPagingRow] &&
|
||||
else if(
|
||||
rowIndex < validIndexes[paging.startPagingRow] &&
|
||||
rowIndex > validIndexes[0]){
|
||||
// o.SetPage('previous');
|
||||
o.Cpt.paging.setPage('previous');
|
||||
console.log('previous');
|
||||
paging.setPage('previous');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -2001,12 +2004,13 @@ export default class TableFilter{
|
|||
//Selected row needs to be visible when paging is activated
|
||||
if(o.paging){
|
||||
o.onAfterChangePage = function(tf, i){
|
||||
var et = tf.ezEditTable;
|
||||
var row = et.Selection.GetActiveRow();
|
||||
var et = tf.Extensions.ezEditTable;
|
||||
var slc = et.Selection;
|
||||
var row = slc.GetActiveRow();
|
||||
if(row){
|
||||
row.scrollIntoView(false);
|
||||
}
|
||||
var cell = et.Selection.GetActiveCell();
|
||||
var cell = slc.GetActiveCell();
|
||||
if(cell){
|
||||
cell.scrollIntoView(false);
|
||||
}
|
||||
|
@ -2098,8 +2102,9 @@ export default class TableFilter{
|
|||
}
|
||||
|
||||
try{
|
||||
o.ezEditTable = new EditTable(o.id, ezEditConfig, startRow);
|
||||
o.ezEditTable.Init();
|
||||
o.Extensions.ezEditTable = new EditTable(
|
||||
o.id, ezEditConfig, startRow);
|
||||
o.Extensions.ezEditTable.Init();
|
||||
} catch(e) { console.log(ezEditConfig.err); }
|
||||
}
|
||||
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports", "string"], function (exports, _string) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* Array utilities
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Str = _string.Str;
|
||||
|
||||
var Arr = {
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports"], function (exports) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* Cookie utilities
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Cookie = {};
|
||||
|
||||
Cookie.write = function (name, value, hours) {
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports"], function (exports) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* Date utilities
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var DateHelper = {
|
||||
isValid: function isValid(dateStr, format) {
|
||||
if (!format) {
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports"], function (exports) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* DOM utilities
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Dom = {};
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports"], function (exports) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* DOM event utilities
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Event = {
|
||||
add: function add(obj, type, func, capture) {
|
||||
if (obj.addEventListener) {
|
||||
|
|
2049
src/extensions/ezEditTable/docs/doc.html
Normal file
154
src/extensions/ezEditTable/docs/doc_class.html
Normal file
|
@ -0,0 +1,154 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_constructor" id="ez_constructor"></a>
|
||||
<h3>Constructor</h3>
|
||||
<h3><code>EditTable(id, startRow, config);</code></h3>
|
||||
<table id="tblConstructor" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Parameter</th>
|
||||
|
||||
<th>Type</th>
|
||||
<th>Description</th>
|
||||
<th>Remarks</th>
|
||||
<th>Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>id</strong></td>
|
||||
<td>string</td>
|
||||
<td>id of the <code>table</code> element</td>
|
||||
<td> </td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId");</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>startRow</strong> </td>
|
||||
<td>number</td>
|
||||
<td>index of the first row from which row selection can start</td>
|
||||
<td>optional parameter</td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId", 2);</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>config</strong></td>
|
||||
<td>object</td>
|
||||
<td> configuration object</td>
|
||||
<td>optional parameter</td>
|
||||
<td><code>var myEditTable = new EditTable("myTableId", 2, { editable: true });</code></td>
|
||||
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
<hr/>
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
599
src/extensions/ezEditTable/docs/doc_methods.html
Normal file
|
@ -0,0 +1,599 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_methods" id="ez_methods"></a>
|
||||
<h3>General Public Methods</h3>
|
||||
<table id="tblMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
|
||||
<th width="200">Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
|
||||
<td>EditTable object initialisation</td>
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br>
|
||||
myET.editable = true;<br />
|
||||
... <br />
|
||||
myET.Init();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetCellsNb( rowIndex )</strong></td>
|
||||
<td>returns number of cells of a specified row</td>
|
||||
<td> </td>
|
||||
<td><code> myET.GetCellsNb(4);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr class="newBg">
|
||||
<td><strong>GetRowsNb()</strong></td>
|
||||
<td>returns total number of rows</td>
|
||||
<td> </td>
|
||||
<td><code>myET.GetRowsNb();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRow(e)</strong></td>
|
||||
|
||||
<td>returns the DOM row element for a given event</td>
|
||||
<td> </td>
|
||||
<td><code>function myFunction(e){ var clickedRow = myET.GetRow(e); }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRowByIndex( rowIndex )</strong></td>
|
||||
<td>returns the DOM row element for a given row index</td>
|
||||
|
||||
<td> </td>
|
||||
<td> <code>myET.GetRowByIndex(5);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetCell(e)</strong></td>
|
||||
<td>returns the DOM cell element for a given event</td>
|
||||
<td> </td>
|
||||
|
||||
<td> <code>function myFunction(e){ var clickedCell = myET.GetCell(e);
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsSelectable()</strong></td>
|
||||
<td>checks if table rows are selectable and returns a boolean </td>
|
||||
<td> </td>
|
||||
<td><code>myET.IsSelectable();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsEditable()</strong></td>
|
||||
<td>checks if table is editable and returns a boolean </td>
|
||||
<td> </td>
|
||||
<td><code>myET.IsEditable();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ClearSelections()</strong></td>
|
||||
|
||||
<td>clears current row(s) and/or cell selection</td>
|
||||
<td> </td>
|
||||
<td> <code>myET.ClearSelections();</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
<hr/>
|
||||
|
||||
<a name="ez_selection_methods" id="ez_selection_methods"></a>
|
||||
<h3>Selection Public Methods</h3>
|
||||
<table id="tblSelectionMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
<td>Selection object initialisation</td>
|
||||
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br />
|
||||
... <br />
|
||||
myET.Selection.Init();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Set()</strong></td>
|
||||
|
||||
<td>enables selection feature</td>
|
||||
<td> </td>
|
||||
<td><code> myET.Selection.Set();</code></td>
|
||||
</tr>
|
||||
<tr class="newBg">
|
||||
<td><strong>Remove()</strong></td>
|
||||
<td> disables selection feature</td>
|
||||
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.Remove();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SetEvents()</strong></td>
|
||||
<td>sets click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.SetEvents();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>RemoveEvents()</strong></td>
|
||||
<td>removes click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Selection.RemoveEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveRow()</strong></td>
|
||||
|
||||
<td>returns the active row element, that is, the row currently selected</td>
|
||||
<td> </td>
|
||||
<td> <code>var activeRow = myET.Selection.GetActiveRow();<br>
|
||||
if(activeRow){ ... }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveCell()</strong></td>
|
||||
|
||||
<td>returns the active cell element, that is, the cell currently selected</td>
|
||||
<td> </td>
|
||||
<td><code>var activeCell = myET.Selection.GetActiveCell();<br>
|
||||
if(activeCell){ ... }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetSelectedRows()</strong></td>
|
||||
|
||||
<td>returns an array of the row elements currently selected, if selection
|
||||
model is multiple</td>
|
||||
<td>returns: <br>
|
||||
[rowobject, rowobject, rowobject, ... rowobject] </td>
|
||||
<td> <code>var selRows = myET.Selection.GetSelectedRows();<br>
|
||||
if(selRows.length > 0){ ... }</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetSelectedValues()</strong></td>
|
||||
<td>returns an array containing a collection of selected rows values
|
||||
</td>
|
||||
<td>returns: [<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3'],<br>
|
||||
...<br>
|
||||
['value 0', 'value 1', 'value 2', ... 'value 3']<br>
|
||||
] </td>
|
||||
<td><code>var selValues = myET.Selection.GetSelectedValues();<br>
|
||||
if(selValues.length > 0){<br>
|
||||
|
||||
var firstValueOfFirstSelectedRow = selValues[0][0];<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetActiveRowValues()</strong></td>
|
||||
<td>returns an array containing the cell values of active row</td>
|
||||
<td>returns ['value 0', 'value 1', 'value 2', ... 'value 3']</td>
|
||||
|
||||
<td><code>var activeValues = myET.Selection.GetActiveRowValues();<br>
|
||||
if(activeValues.length > 0){ ... } </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetRowValues( row )</strong></td>
|
||||
<td>returns an array containing the cell values of a given row, it accepts
|
||||
only a row DOM element</td>
|
||||
|
||||
<td>returns ['value 0', 'value 1', 'value 2', ... 'value 3'] </td>
|
||||
<td> <p><code>var myRow = myET.GetRowByIndex(7);<br>
|
||||
if(myRow){ <br>
|
||||
myRowValues = myET.Selection.GetRowValues(myRow);<br>
|
||||
</code><code>}</code></p></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRowByIndex( rowIndex )</strong></td>
|
||||
<td>selects a row for a given row index</td>
|
||||
<td> </td>
|
||||
<td><code> myET.Selection.SelectRowByIndex(9);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRowsByIndexes( rowIndexes )</strong> <sup>new</sup></td>
|
||||
<td>selects rows for a given array of row indexes</td>
|
||||
<td>Multiple selection needs to be active (selection_model: 'multiple')</td>
|
||||
<td><code> myET.Selection.SelectRowsByIndexes([2, 7, 9, 12]);</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>SelectRow( row )</strong></td>
|
||||
<td>selects given row element</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
if(myRow){<br>
|
||||
myET.Selection.SelectRow(myRow);<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>DeselectRow( row )</strong></td>
|
||||
<td>deselects given row element</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
if(myET.Selection.IsRowSelected(myRow)){<br>
|
||||
|
||||
myET.Selection.DeselectRow(myRow);<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SelectCell( cell )</strong></td>
|
||||
<td>selects given cell element</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
if(myCell) myET.Selection.SelectCell(myCell);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>DeselectCell( cell )</strong></td>
|
||||
<td>deselects given cell element</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
if(myCell) myET.Selection.DeselectCell(myCell);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ClearSelections()</strong></td>
|
||||
<td>clears current row(s) and/or cell selection</td>
|
||||
<td>The general <code>ClearSelections()</code> invokes this method (<code>
|
||||
myET</code><code>.ClearSelections</code>() )</td>
|
||||
|
||||
<td><code>myET.Selection.ClearSelections();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsRowSelected( row )</strong></td>
|
||||
<td>determines if given row is selected and returns a boolean</td>
|
||||
<td> </td>
|
||||
<td><code>var myRow = myET.GetRowByIndex(6);<br>
|
||||
|
||||
if(myET.Selection.IsRowSelected(myRow)){ ... } </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsCellSelected( cell )</strong></td>
|
||||
<td>determines if given cell is selected and returns a boolean</td>
|
||||
<td> </td>
|
||||
<td><code>var myCell = myET.GetRowByIndex(3).cells[2];<br>
|
||||
|
||||
if(myET.Selection.IsCellSelected( myCell )){ ... }</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
<hr/>
|
||||
|
||||
<a name="ez_editable_methods" id="ez_editable_methods"></a>
|
||||
<h3>Editable Public Methods</h3>
|
||||
|
||||
<table id="tblEditableMethods" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> Init()</strong></td>
|
||||
<td>Editable object initialisation</td>
|
||||
<td> </td>
|
||||
<td><code> var myET = new EditTable('myTableId');<br />
|
||||
|
||||
... <br />
|
||||
myET.Editable.Init();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Set()</strong></td>
|
||||
<td>enables inline editing feature</td>
|
||||
<td> </td>
|
||||
|
||||
<td><code> myET.Editable.Set();</code></td>
|
||||
</tr>
|
||||
<tr class="newBg">
|
||||
<td><strong>Remove()</strong></td>
|
||||
<td> disables inline editing feature</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.Remove();</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SetEvents()</strong></td>
|
||||
<td>sets click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.SetEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>RemoveEvents()</strong></td>
|
||||
|
||||
<td>removes click and keyboard events to table element</td>
|
||||
<td> </td>
|
||||
<td><code>myET.Editable.RemoveEvents();</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetModifiedRows()</strong></td>
|
||||
<td>returns an array containing the modified rows objects</td>
|
||||
|
||||
<td>returns: <br>
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, false, ...]<br>
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, false, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td> <p><code>var modRowObjs = myET.Editable.GetModifiedRows();<br>
|
||||
for(var i=0; i<modRowObjs.length; i++){<br>
|
||||
var rowIndex = modRowObjs[i][0]; //int<br>
|
||||
var obj = modRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
} </code></p></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetAddedRows()</strong></td>
|
||||
<td>returns an array containing the added rows objects</td>
|
||||
|
||||
<td>returns: <br>
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, true, ...]<br>
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [true, true, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td><code>var addRowObjs = myET.Editable.GetAddedRows();<br>
|
||||
for(var i=0; i<addRowObjs.length; i++){<br>
|
||||
var rowIndex = addRowObjs[i][0]; //int<br>
|
||||
var obj = addRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
} </code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetDeletedRows()</strong></td>
|
||||
<td>returns an array containing the deleted rows objects</td>
|
||||
<td>returns: <br>
|
||||
|
||||
[<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
modified: [false, false, ...]<br>
|
||||
|
||||
}],<br>
|
||||
...<br>
|
||||
[rowIndex, <br>
|
||||
{ values: [val0, val1, ...valn], <br>
|
||||
urlParams: '&ColName0=cellvalue0&ColName1=cellvalue1',<br>
|
||||
|
||||
modified: [false, false, ...]<br>
|
||||
}] <br>
|
||||
] <br>
|
||||
urlParams are the paramaters names that are expected server-side.
|
||||
If the parameters' names are not defined by the property <code>param_names</code>
|
||||
in the actions object (configuration object <a href="doc.html#ez_actions">actions</a>),
|
||||
the param name by default equals to 'col_<strong>n</strong>' where
|
||||
n is the column index (col_0, col_1, ... col_n)</td>
|
||||
|
||||
<td> <code>var delRowObjs = myET.Editable.GetDeletedRows();<br>
|
||||
for(var i=0; i<delRowObjs.length; i++){<br>
|
||||
var rowIndex = delRowObjs[i][0]; //int<br>
|
||||
var obj = delRowObjs[i][1]; //object<br>
|
||||
var objValues = obj.values; //array<br>
|
||||
|
||||
var objModValues = obj.modified; //array of booleans<br>
|
||||
var objUrlParams = obj.urlParams //string<br>
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitEditedRows()</strong></td>
|
||||
<td>submits edited rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
|
||||
<td>modified rows objects are sent to server (uri property in 'update'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options)</td>
|
||||
<td><p><code>function SaveEditedRows(){<br>
|
||||
myET.Editable.SubmitEditedRows();<br>
|
||||
}</code></p>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitAddedRows()</strong></td>
|
||||
<td>submits added rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td>added rows objects are sent to server (uri property in 'insert'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options)</td>
|
||||
<td><code>function SaveAddedRows(){
|
||||
myET.Editable.SubmitAddeddRows();
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitDeletedRows()</strong></td>
|
||||
<td>submits deleted rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td>deleted rows objects are sent to server (uri property in 'delete'
|
||||
<a href="doc.html#ez_actions">actions</a> configuration options). A
|
||||
confirmation prompt appears before sending data to server</td>
|
||||
|
||||
<td> <p><code>function DeleteSelectedRows(){
|
||||
myET.Editable.SubmitDeletedRows();
|
||||
}</code></p></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>SubmitAll()</strong> <sup>new</sup></td>
|
||||
<td>submits added and edited rows to server according to <a href="doc.html#ez_actions">actions</a> configuration
|
||||
options </td>
|
||||
<td></td>
|
||||
<td><code>function SubmitAll(){ myET.Editable.SubmitAll(); }</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>AddNewRow()</strong></td>
|
||||
<td>adds a row to the table</td>
|
||||
|
||||
<td></td>
|
||||
<td><code>myET.Editable.AddNewRow();</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
515
src/extensions/ezEditTable/docs/doc_properties.html
Normal file
|
@ -0,0 +1,515 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>EditTable Class</h2>
|
||||
|
||||
<!--[if lt IE 8]>
|
||||
|
||||
<p>
|
||||
<a href="./doc_class.html#ez_constructor">Constructor</a></li> |
|
||||
<a href="./doc_methods.html#ez_methods">General public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li> |
|
||||
<a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li> |
|
||||
<a href="./doc_properties.html#ez_properties">General public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li> |
|
||||
<a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</p>
|
||||
<![endif]-->
|
||||
|
||||
<a name="ez_properties" id="ez_properties"></a>
|
||||
<h3>General Public Properties</h3>
|
||||
<table id="tblProps" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>id</strong></td>
|
||||
<td>string</td>
|
||||
<td>returns the HTML table's id used by the EditTable object</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.id );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>table</strong></td>
|
||||
<td>HTMLTableElement</td>
|
||||
<td>returns the HTML table element used by the EditTable object</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.table );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>config</strong></td>
|
||||
<td>object</td>
|
||||
<td>returns the EditTable configuration object (literal object)</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.config );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>startRow</strong></td>
|
||||
<td>number</td>
|
||||
<td>index of the first row from which row selection can start</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.startRow );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>nbCells</strong></td>
|
||||
<td>number</td>
|
||||
<td>returns the number of table columns</td>
|
||||
<td>use it as getter only</td>
|
||||
<td><code>alert( myET.nbCells );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>selection</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables selection model</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.selection = false;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>keyNav</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables keyboard navigation</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.keyNav = false;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>editable</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disables inline editing</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.editable = true;</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>tableCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class of the table element</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>myET.tableCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>unselectableCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class that makes the table text unselectable</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.unselectableCss );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>activityIndicatorCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the css class to be applied to the table in order to indicate
|
||||
server activity </td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.activityIndicatorCss );</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>basePath</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the path to the script's directory</td>
|
||||
<td>use it as getter or setter</td>
|
||||
<td><code>alert( myET.basePath );</code></td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
<a name="ez_selection_properties" id="ez_selection_properties"></a>
|
||||
<h3>Selection Public Properties</h3>
|
||||
<table id="tblSelectionProps" cellspacing="0" class="ezEditableTable" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td><strong>selectionModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the selection model: "single" or "multiple"</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'single' or 'multiple'</td>
|
||||
|
||||
<td><code>myET.selectionModel = 'multiple';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>defaultSelection</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the selection type</td>
|
||||
<td>use it as getter or setter - 3 possible values: 'row', 'cell' or
|
||||
'both'</td>
|
||||
|
||||
<td><code>myET.defaultSelection = 'both';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>keySelection</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>enables / disable multiple selection by using Ctrl and Shift keys
|
||||
</td>
|
||||
<td>use it as getter or setter - select multiple rows by holding Ctrl
|
||||
or Shift key down, only if selection model is 'multiple'</td>
|
||||
|
||||
<td><code>myET.keySelection = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectRowAtStart</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>first row is selected at start if set true</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.selectRowAtStart = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>rowIndexAtStart</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines which row has to be selected at start</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.rowIndexAtStart = 5;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>scrollIntoView</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>If set true selected row scrolls into view; useful when row is selected
|
||||
by using keyboard</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.scrollIntoView = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>activeRowCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for active row</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.activeRowCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectedRowCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for selected rows</td>
|
||||
<td>use it as getter or setter - only if 'multiple' selection model
|
||||
is enabled</td>
|
||||
|
||||
<td><code>myET.selectedRowCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>activeCellCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines css class for active cell</td>
|
||||
<td>use it as getter or setter - only if 'cell' or 'both' selection
|
||||
type is enabled</td>
|
||||
|
||||
<td><code>myET.activeCellCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>nbRowsPerPage</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines number of rows to jump when PgDown or PgUp keys are pressed</td>
|
||||
<td>use it as getter or setter - specify a huge number to jump straight
|
||||
to 1st or last row (1000)</td>
|
||||
|
||||
<td><code>myET.nbRowsPerPage = 1000;</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
<a name="ez_editable_properties" id="ez_editable_properties"></a>
|
||||
<h3>Editable Public Properties</h3>
|
||||
<table id="tblEditableProps" cellspacing="0" class="ezEditableTable" >
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Property</th>
|
||||
<th >Type</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
<th >Example</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>editorModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the editor model</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'cell' or 'row'</td>
|
||||
|
||||
<td><code>myET.editorModel = 'row';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>openEditorAction</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines which mouse action opens the inline editing feature</td>
|
||||
<td>use it as getter or setter - 2 possible values: 'dblclick', 'click'</td>
|
||||
|
||||
<td><code>myET.openEditorAction = 'click';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>ajax</strong> <sup>new</sup></td>
|
||||
<td>boolean</td>
|
||||
<td>enables AJAX requests (default: true if jQuery is detected)</td>
|
||||
<td>it is enabled if jQuery is detected and the <code>ajax</code> property is
|
||||
not explicitly set <code>false</code></td>
|
||||
<td><code>myET.ajax = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>inputEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>defines the css class for 'input' type editors</td>
|
||||
<td>use it as getter or setter - select multiple rows by holding Ctrl
|
||||
or Shift key down, only if selection model is 'multiple'</td>
|
||||
|
||||
<td><code>myET.inputEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>textareaEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>defines the css class for 'textarea' type editors</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.textareaEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>selectEditorCss</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines the css class for 'input' type editors</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.selectEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>commandEditorCss</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>css class applied to command editor buttons container</td>
|
||||
<td>use it as getter or setter</td>
|
||||
|
||||
<td><code>myET.commandEditorCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>modifiedCellCss</strong></td>
|
||||
<td>string</td>
|
||||
<td>css class applied to modified cells</td>
|
||||
<td>use it as getter or setter - this css class shows the green small
|
||||
triangle in the left-upper corner of the cell</td>
|
||||
|
||||
<td><code>myET.modifiedCellCss = 'myClass';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>cellEditors</strong></td>
|
||||
<td>array</td>
|
||||
<td>array defining the editor configuration for each column</td>
|
||||
<td>use it as getter or setter - the number of editors must be equal
|
||||
to the number of columns. Refer to <a href="doc.html#ez_cell_editors">Cell
|
||||
editors properties</a> for details about editors' configuration</td>
|
||||
<td><code>myET.cellEditors = [<br>
|
||||
{ type: 'select' },<br>
|
||||
{ type: 'textarea' },<br>
|
||||
{ type: 'input' },<br>
|
||||
{ type: 'uploader' },<br>
|
||||
{ type: 'none' }, <br>
|
||||
{ type: 'command' }<br>
|
||||
];</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>actions</strong></td>
|
||||
<td>object</td>
|
||||
<td>server actions configuration object </td>
|
||||
<td>use it as getter or setter - Refer to <a href="doc.html#ez_actions">actions
|
||||
properties</a> for details about server actions configuration</td>
|
||||
|
||||
<td><code>myET.actions = {<br>
|
||||
'update': { <br>
|
||||
uri: 'updateRow.php', submit_method: 'form', form_method: 'POST',
|
||||
<br>
|
||||
param_names: ['iso', 'name', 'printablename', 'iso3', 'code'] },<br>
|
||||
'insert': { <br>
|
||||
uri: 'insertRow.php', submit_method: 'form', form_method: 'POST',
|
||||
<br>
|
||||
|
||||
param_names: ['iso', 'name', 'printablename', 'iso3', 'code'] },<br>
|
||||
'delete': { <br>
|
||||
uri: 'script.delete.php', submit_method: 'script', bulk_delete: true
|
||||
}<br>
|
||||
}</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSave</strong></td>
|
||||
<td>boolean</td>
|
||||
<td>saves automatically pending changes upon selection change</td>
|
||||
<td><code>editable</code> property needs to be activated (default: true if editable is on)</td>
|
||||
<td><code>myET.autoSave = false;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSaveModel</strong></td>
|
||||
<td>string</td>
|
||||
<td>determines when modified and/or added data is saved, upon row or cell selection change (default: 'row')</td>
|
||||
<td>2 possible values 'row' or 'cell'</td>
|
||||
<td><code>myET.autoSaveModel = 'cell';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>autoSaveType</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines if only insertions or updates, or both are saved automatically (default: 'both')</td>
|
||||
<td>3 possible values 'insert', 'update' or 'both'</td>
|
||||
<td><code>myET.autoSaveType = 'update';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>editableOnKeystroke</strong> <sup>new</sup></td>
|
||||
<td>boolean</td>
|
||||
<td>makes the inline cell editor appear upon keystroke (default: false)</td>
|
||||
<td>only if edition is enabled and <code>editorModel</code> is set to <code>'cell'</code> and
|
||||
<code>selectionModel</code> to <code>'single'</code></td>
|
||||
<td><code>myET.editableOnKeystroke = true;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>newRowPrefix</strong></td>
|
||||
<td>string</td>
|
||||
<td>defines the prefix for new added row ids (default: 'tr')</td>
|
||||
<td>prefix should match the prefix assigned to already existing rows</td>
|
||||
<td><code>myET.newRowPrefix = 'row';</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>formSubmitInterval</strong></td>
|
||||
<td>number</td>
|
||||
<td>defines the interval in ms separating rows data submissions (default: 50)</td>
|
||||
<td>by default the script submits a single form for each modified row. Depending on ISPs
|
||||
security policies, multiple submissions to same page are simply blocked by the server.
|
||||
This interval can be useful to fine tune the form submissions when those server restrictions apply.</td>
|
||||
<td><code>myET.formSubmitInterval = 750;</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>newRowPos</strong> <sup>new</sup></td>
|
||||
<td>string or number</td>
|
||||
<td>defines the row position of a newly created row (default: 'top')</td>
|
||||
<td>2 possible values as a string: 'top' or 'bottom', and as an integer:
|
||||
any number >= 0 and <= total number of rows. If the supplied numeric
|
||||
value exceeds the total number of rows then the script fallback to default
|
||||
value 'top'</td>
|
||||
<td><code>myET.newRowPos = 'bottom';</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
|
||||
<a href="javascript:window.scroll(0,0);">Top of page</a>
|
||||
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
207
src/extensions/ezEditTable/docs/doc_utilities.html
Normal file
|
@ -0,0 +1,207 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<script language="javascript" type="text/javascript" src="../ezEditTable.js"></script>
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk03{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
|
||||
<div id="divsubmenu">
|
||||
<ul class="submenu">
|
||||
<li class="dir">
|
||||
<a id="co" href="./doc.html">Configuration Object <small>▼</small></a>
|
||||
<ul>
|
||||
<li><a href="./doc.html#ez_common">General</a></li>
|
||||
<li><a href="./doc.html#ez_selection">Selection</a></li>
|
||||
<li><a href="./doc.html#ez_sel_events">Selection callback events</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Editable</a></li>
|
||||
<li><a href="./doc.html#ez_cell_editors">Cell editors</a></li>
|
||||
<li><a href="./doc.html#ez_editable">Command buttons</a></li>
|
||||
<li><a href="./doc.html#ez_uploader">Uploader editor <sup>new</sup></a></li>
|
||||
<li><a href="./doc.html#ez_editable_events">Editable callback events</a></li>
|
||||
<li><a href="./doc.html#ez_actions">Actions</a></li>
|
||||
<li><a href="./doc.html#ez_actions_events">Actions callback events</a></li>
|
||||
<li><a href="./doc.html#ez_msg">Messages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="dir">
|
||||
<a id="cl" href="./doc_class.html">TF Class<small>▼</small></a>
|
||||
<ul>
|
||||
|
||||
<li><a href="./doc_class.html#ez_constructor">Constructor</a></li>
|
||||
<li><a href="./doc_methods.html#ez_methods">General public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_selection_methods">Selection public methods</a></li>
|
||||
<li><a href="./doc_methods.html#ez_editable_methods">Editable public methods</a></li>
|
||||
<li><a href="./doc_properties.html#ez_properties">General public properties</a></li>
|
||||
<li><a href="./doc_properties.html#ez_selection_properties">Selection public properties</a></li>
|
||||
|
||||
<li><a href="./doc_properties.html#ez_editable_properties">Editable public properties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a id="uf" href="./doc_utilities.html">Utility Functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h1 class="marginTop30">Documentation</h1>
|
||||
|
||||
<a name="class" id="class"></a>
|
||||
|
||||
<h2>Utility Functions</h2>
|
||||
|
||||
|
||||
<table id="tblUtils" cellspacing="0" class="ezEditableTable" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th >Method</th>
|
||||
<th >Description</th>
|
||||
<th >Remarks</th>
|
||||
|
||||
<th >Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong> setEditTable( id, startRow, config )</strong></td>
|
||||
<td><p>Calls EditTable constructor and returns the EditTable object:</p>
|
||||
|
||||
<ul>
|
||||
<li>id: table id (string)</li>
|
||||
<li>startRow (optional): index of the first row from which row selection
|
||||
can start (number)</li>
|
||||
<li>config (optional): configuration object (literal object)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code> var et = setEditTable('myTableId', 2, { editable: true });</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong> Get(id)</strong></td>
|
||||
<td><p>this is a <code>document.getElementById()</code> shortcut:</p>
|
||||
<ul>
|
||||
<li>id: id of the element (string)</li>
|
||||
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code> var myElm = et.Get('myId');</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Tag(o, tagname)</strong></td>
|
||||
<td><p>this is just a <code>getElementsByTagName()</code> shortcut:</p>
|
||||
|
||||
<ul>
|
||||
<li>o: target element (DOM element)</li>
|
||||
<li>tagname: tag to search for (string)</li>
|
||||
</ul>
|
||||
<p>It returns an array</p></td>
|
||||
<td> </td>
|
||||
<td><code>var myTables = et.Tag(document, 'table');</code></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>GetText(n)</strong></td>
|
||||
<td><p>returns the text of given a node and its child nodes:</p>
|
||||
<ul>
|
||||
<li>n: node (DOM element)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
|
||||
<td><code>var tableText = et.GetText( et.Tag(document,'table' )[0]);</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>CreateElm(tag)</strong></td>
|
||||
<td><p>creates an html element with defined attributes:</p>
|
||||
<ul>
|
||||
<li>the html tag to create (string)</li>
|
||||
|
||||
<li>an unlimited # of arrays defining the attributes values ('attribute
|
||||
name','value' ['id','myId'])</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code>var myInput = et.CreateElm( 'input', ['id','myId'], ['value','Hello
|
||||
world'] );</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>CreateText(t)</strong></td>
|
||||
<td><p>this is just a <code>document.createTextNode</code> shortcut:</p>
|
||||
|
||||
<ul>
|
||||
<li>t: text to generate (string)</li>
|
||||
</ul></td>
|
||||
<td> </td>
|
||||
<td><code>var myText = et.CreateText( 'Hello world' );</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsArray(obj)</strong></td>
|
||||
|
||||
<td><p>checks if passed param is an array. It returns a boolean</p></td>
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsArray([1,2,3]));</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsObj(obj)</strong></td>
|
||||
<td><p>checks if passed param is an object. It returns a boolean</p></td>
|
||||
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsObj({ text: 'hello'}));</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>IsFn(fn)</strong></td>
|
||||
<td><p>checks if passed param is a function. It returns a boolean</p></td>
|
||||
<td> </td>
|
||||
<td><code>alert(et.IsFn(function(){ var a=0; }));</code></td>
|
||||
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<hr/>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
473
src/extensions/ezEditTable/docs/index.html
Normal file
|
@ -0,0 +1,473 @@
|
|||
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily, advanced inline editing, selection and keyboard navigation - script by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript, max guglielmi" />
|
||||
<meta name="robots" content="index,follow" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
<style type="text/css" media="screen, projection">
|
||||
@import "http://edittable.free.fr/includes/common.css";
|
||||
</style>
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
div#navmenu li a#lnk01{
|
||||
color:#333; font-weight:bold;
|
||||
border-top:2px solid #ff9900;
|
||||
background:#fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
|
||||
<div id="banner">
|
||||
|
||||
<div id="navmenu">
|
||||
<ul>
|
||||
<li><a id="lnk01" href="index.html">Home</a></li>
|
||||
<li><a id="lnk02" href="samples.html">Samples</a></li>
|
||||
<li><a id="lnk03" href="doc.html">Documentation</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN CONTENT -->
|
||||
|
||||
<div id="content">
|
||||
<h1>ezEditTable</h1>
|
||||
<h2>Description</h2>
|
||||
<p>
|
||||
ezEditTable is a javascript code aimed at enhancing regular
|
||||
HTML tables by adding features such as inline editing components, advanced
|
||||
selection and keyboard navigation. With just a line of code you can easily
|
||||
convert a regular HTML table in an advanced editable and selectable grid control.
|
||||
</p>
|
||||
<h3>Main features</h3>
|
||||
<ul>
|
||||
<li>Attach to an existing HTML table</li>
|
||||
<li>Advanced selection model</li>
|
||||
<li>Extended keyboard navigation</li>
|
||||
<li>Inline cell or row editing</li>
|
||||
<li>Insert and remove rows</li>
|
||||
<li>Send changes to server via GET or POST form submission, AJAX requests or
|
||||
by script injection in the head section of the document (only GETs)</li>
|
||||
<li>Integration with any server-side technology as this is a pure client-side solution</li>
|
||||
<li>Callbacks for all events, and delegates for most actions</li>
|
||||
<li>Based on plain javascript and dependent on jQuery only for performing AJAX requests</li>
|
||||
<li>Exhaustive documentation and API</li>
|
||||
<li>Easy setup and easy customisable themes</li>
|
||||
</ul>
|
||||
|
||||
<h2>Installation
|
||||
<span class="floatRight fontSize12px">
|
||||
<a href="starter.html">Starter</a>
|
||||
</span>
|
||||
</h2>
|
||||
<p>To install <strong>ezEditTable</strong> unzip the download package and then include the following
|
||||
scripts and stylesheet files in the <code>head</code> section of your page:</p>
|
||||
|
||||
<pre>
|
||||
<link href="ezEditTable/ezEditTable.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="ezEditTable/ezEditTable.js"></script>
|
||||
</pre>
|
||||
|
||||
<p>Make sure the table you'd like to make editable or selectable
|
||||
has an unique <code>id</code> and a <code>thead</code> and <code>tbody</code>
|
||||
sections.</p>
|
||||
<p>Here you have an example of a regular html table: </p>
|
||||
<table border="1" cellspacing="0" cellpadding="2" width="80%">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p>Below the same table enhanced by the script (<code>id="table1"</code>),
|
||||
click to select a row or use keys to move the selection:</p>
|
||||
<table id="table1" cellspacing="0" cellpadding="0" width="80%">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var et = new EditTable('table1');
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
<p>There are 2 different ways to call the script:</p>
|
||||
<ul>
|
||||
|
||||
|
||||
<li>invoke the <code>setEditTable</code> function, which returns a EditTable object: </li>
|
||||
</ul>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var et = setEditTable("table1");
|
||||
</script> </pre>
|
||||
|
||||
<ul>
|
||||
<li>instanciate the <strong><code>EditTable</code></strong> object: </li>
|
||||
</ul>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var et = new EditTable('table1');
|
||||
et.Init();
|
||||
</script> </pre>
|
||||
<p>If your document contains several tables (like this page), it is important
|
||||
to define unique ids, otherwise the script will not work properly. </p>
|
||||
|
||||
<p>The <code>setEditTable()</code> function or the <code>EditTable</code>
|
||||
class accepts 2 additional parameters that will be explained in the next
|
||||
tables. In the example below, by specifing a row number as a "start"
|
||||
row, we tell the script from which row can start the selection, this is
|
||||
helpful when the <code>tbody</code> and <code>thead</code> sections are not defined: </p>
|
||||
|
||||
|
||||
<table id="table2" cellspacing="0" cellpadding="0" >
|
||||
<tr>
|
||||
<td colspan="5"><strong>This is the table caption </strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var et02 = new EditTable("table2",2);
|
||||
et02.Init();
|
||||
</script>
|
||||
|
||||
<pre class="brush: js;">var et02 = setEditTable("table2", 2);</pre>
|
||||
|
||||
<p>or</p>
|
||||
|
||||
<pre class="brush: js;">var et02 = new EditTable("table2", 2);
|
||||
et02.Init();</pre>
|
||||
<p>By default, the script adds a single row selection feature to the table.
|
||||
You could decide to also add a cell selection feature and make the cells
|
||||
editable, double-click on a cell to see:</p>
|
||||
|
||||
<table id="table3" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td colspan="5"><strong>This is the table caption </strong></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th style="width:100px">From</th>
|
||||
<th style="width:100px">Destination</th>
|
||||
<th style="width:100px">Road Distance (km)</th>
|
||||
<th style="width:100px">By Air (hrs)</th>
|
||||
<th style="width:80px">By Rail (hrs)</th>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sydney</td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Adelaide</td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
};
|
||||
var et03 = new EditTable("table3", 2, table3Config);
|
||||
et03.Init();
|
||||
</script>
|
||||
<p>To do that you just need to declare a <em>literal object</em> (configuration
|
||||
object) in which you specify the features you would like to enable:</p>
|
||||
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
}
|
||||
var et03 = setTableEdit("table3", 2, table3Config);
|
||||
</script></pre>
|
||||
<p>or</p>
|
||||
<pre class="brush: js;"><script language="javascript" type="text/javascript">
|
||||
var table3Config = {
|
||||
default_selection: 'both',
|
||||
editable: true,
|
||||
auto_save: false
|
||||
}
|
||||
var et03 = new EditTable("table3", 2 ,table3Config);
|
||||
et03.Init();
|
||||
</script></pre>
|
||||
|
||||
<p>You can name the <em>configuration object</em> as you want, but don't forget
|
||||
to add it to the parameters of the <code>setEditTable</code>() function
|
||||
or <code>EditTable</code> class. It is important to respect the syntax and
|
||||
naming convention as shown above. You will find an exhaustive list of properties
|
||||
in the <a href="doc.html">documentation</a> section. </p>
|
||||
<h2>Documentation</h2>
|
||||
|
||||
|
||||
<p>For more information about the script's configuration and API check out
|
||||
the <a href="doc.html">documentation</a> and the
|
||||
available online <a href="http://edittable.free.fr/demos.php">demos</a>.</p>
|
||||
|
||||
<hr class="clearBoth" />
|
||||
|
||||
</div>
|
||||
<!-- END CONTENT -->
|
||||
|
||||
<div id="footer"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
1082
src/extensions/ezEditTable/docs/samples.html
Normal file
195
src/extensions/ezEditTable/docs/starter.html
Normal file
|
@ -0,0 +1,195 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily - Starter page - by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta name="description" content="ezEditTable is an open source javascript code aimed at enhancing regular HTML tables by adding features such as inline editing components, advanced selection and keyboard navigation" />
|
||||
<meta name="keywords" content="html table editing, html table inline cell editing, inline cell editor, row selection, script, javascript" />
|
||||
<meta name="author" content="Max Guglielmi" />
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>Starter</h1>
|
||||
<p>
|
||||
<a href="index.html">← Documentation</a>
|
||||
</p>
|
||||
<div>
|
||||
<table id="demo" cellspacing="0" cellpadding="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<script language="javascript" type="text/javascript">
|
||||
var config = {
|
||||
selection: true,
|
||||
default_selection: 'both'
|
||||
};
|
||||
var et = new EditTable('demo', config);
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<h4>Source code of the page:</h4>
|
||||
<pre>
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<title>ezEditTable, enhance HTML tables easily - Starter page - by Max Guglielmi</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
|
||||
<link href="../ezEditTable.css" rel="stylesheet" type="text/css">
|
||||
<script src="../ezEditTable.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h1>ezEditTable Starter</h1>
|
||||
|
||||
<table id="demo" cellspacing="0" cellpadding="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>From</th>
|
||||
<th>Destination</th>
|
||||
<th>Road Distance (km)</th>
|
||||
<th>By Air (hrs)</th>
|
||||
<th width="15%">By Rail (hrs)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Adelaide</td>
|
||||
<td>1412</td>
|
||||
<td>1.4</td>
|
||||
<td>25.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>982</td>
|
||||
<td>1.5</td>
|
||||
<td>16</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Canberra</td>
|
||||
<td>286</td>
|
||||
<td>.6</td>
|
||||
<td>4.3</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Sydney</strong></td>
|
||||
<td>Melbourne</td>
|
||||
<td>872</td>
|
||||
<td>1.1</td>
|
||||
<td>10.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Perth</td>
|
||||
<td>2781</td>
|
||||
<td>3.1</td>
|
||||
<td>38</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Alice Springs</td>
|
||||
<td>1533</td>
|
||||
<td>2</td>
|
||||
<td>20.25</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Adelaide</strong></td>
|
||||
<td>Brisbane</td>
|
||||
<td>2045</td>
|
||||
<td>2.15</td>
|
||||
<td>40</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<script language="javascript" type="text/javascript">
|
||||
var config = {
|
||||
selection: true,
|
||||
default_selection: 'both'
|
||||
};
|
||||
var et = new EditTable('demo', config);
|
||||
et.Init();
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
86
src/extensions/ezEditTable/ezEditTable-uncompressed.css
Normal file
|
@ -0,0 +1,86 @@
|
|||
/*====================================================
|
||||
- ezEditTable global stylesheet
|
||||
- Edit classes below for your projects' needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
padding:0; color:#000;
|
||||
border-collapse:collapse;
|
||||
font:12px/13px arial, tahoma, helvetica, sans-serif !important;
|
||||
}
|
||||
.ezEditableTable th, .ezEditableTable td{
|
||||
margin:0; padding:5px;
|
||||
color:inherit;
|
||||
border:1px solid #ccc !important;
|
||||
}
|
||||
.ezEditableTable th{
|
||||
background:#EBECEE !important;
|
||||
}
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow{ background-color:#2852A8 !important; color:#fff; }
|
||||
.ezSelectedRow{ background-color:#316AC5; color:#fff; }
|
||||
.ezActiveCell{
|
||||
background-color:#D9E8FB !important;
|
||||
color:#000 !important; font-weight:bold;
|
||||
}
|
||||
.ezUnselectable{
|
||||
-moz-user-select: -moz-none;
|
||||
-khtml-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
/* Cell editors */
|
||||
.ezInputEditor{ width:95%; height:auto; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezTextareaEditor{ width:95%; height:35px; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezSelectEditor{ width:100%; font-size:inherit; border:1px solid #AACCF6; }
|
||||
.ezModifiedCell{ background:transparent url(themes/bg_mod_cell.png) 0 0 no-repeat; }
|
||||
select[multiple="multiple"].ezSelectEditor{ height:35px; }
|
||||
/* Command type editor */
|
||||
.ezCommandEditor{ margin:2px; }
|
||||
.ezCommandEditor button{
|
||||
font-size:10px;
|
||||
border:1px solid #ccc;
|
||||
background:#fff; margin:1px;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
/* Uploader editor */
|
||||
.ezUploaderEditor{
|
||||
position:absolute; display:inline;
|
||||
margin:15px 0 0 0px;
|
||||
border:1px solid #ccc; padding:5px;
|
||||
background:#fff; color:#000; z-index:10000;
|
||||
border-radius:4px;
|
||||
-moz-border-radius:4px;
|
||||
-webkit-border-radius:4px;
|
||||
box-shadow:3px 3px 2px #888;
|
||||
-moz-box-shadow:3px 3px 2px #888;
|
||||
-webkit-box-shadow:3px 3px 2px #888;
|
||||
}
|
||||
.ezUploaderEditor button{
|
||||
font-size:10px;
|
||||
border:1px solid #ccc;
|
||||
background:#fff; margin:1px;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
.ezUploaderEditorOutput{ }
|
||||
.ezUploaderEditorDisplay{
|
||||
display:none; position:relative;
|
||||
max-width:800px; max-height:600px;
|
||||
overflow:auto; border:0;
|
||||
background:#fff; padding:5px; margin:5px;
|
||||
}
|
||||
|
||||
/* Utils */
|
||||
.ezOpacity{
|
||||
filter:alpha(opacity=60); /* for IE */
|
||||
opacity:0.6; /* CSS3 standard */
|
||||
}
|
||||
.alignLeft{ text-align:left; }
|
||||
.alignCenter{ text-align:center; }
|
||||
.alignRight{ text-align:right; }
|
||||
.icnImg{ border:0; }
|
2081
src/extensions/ezEditTable/ezEditTable-uncompressed.js
Normal file
7
src/extensions/ezEditTable/ezEditTable.css
Normal file
|
@ -0,0 +1,7 @@
|
|||
/*------------------------------------------------------------------------
|
||||
- ezEditTable stylesheet by Max Guglielmi
|
||||
- (build date: Sun Mar 15 2015 15:46:31)
|
||||
- Edit below for your projects' needs
|
||||
------------------------------------------------------------------------*/
|
||||
|
||||
.ezEditableTable{padding:0;color:#000;border-collapse:collapse;font:12px/13px arial,tahoma,helvetica,sans-serif!important}.ezEditableTable th,.ezEditableTable td{margin:0;padding:5px;color:inherit;border:1px solid #ccc!important}.ezEditableTable th{background:#EBECEE!important}.ezActiveRow{background-color:#2852A8!important;color:#fff}.ezSelectedRow{background-color:#316AC5;color:#fff}.ezActiveCell{background-color:#D9E8FB!important;color:#000!important;font-weight:700}.ezUnselectable{-moz-user-select:-moz-none;-khtml-user-select:none;-webkit-user-select:none;-o-user-select:none;user-select:none}.ezInputEditor{width:95%;height:auto;font-size:inherit;border:1px solid #AACCF6}.ezTextareaEditor{width:95%;height:35px;font-size:inherit;border:1px solid #AACCF6}.ezSelectEditor{width:100%;font-size:inherit;border:1px solid #AACCF6}.ezModifiedCell{background:transparent url(themes/bg_mod_cell.png) 0 0 no-repeat}select[multiple=multiple].ezSelectEditor{height:35px}.ezCommandEditor{margin:2px}.ezCommandEditor button{font-size:10px;border:1px solid #ccc;background:#fff;margin:1px;border-radius:4px;-moz-border-radius:4px}.ezUploaderEditor{position:absolute;display:inline;margin:15px 0 0;border:1px solid #ccc;padding:5px;background:#fff;color:#000;z-index:10000;border-radius:4px;-moz-border-radius:4px;-webkit-border-radius:4px;box-shadow:3px 3px 2px #888;-moz-box-shadow:3px 3px 2px #888;-webkit-box-shadow:3px 3px 2px #888}.ezUploaderEditor button{font-size:10px;border:1px solid #ccc;background:#fff;margin:1px;border-radius:4px;-moz-border-radius:4px}.ezUploaderEditorOutput{}.ezUploaderEditorDisplay{display:none;position:relative;max-width:800px;max-height:600px;overflow:auto;border:0;background:#fff;padding:5px;margin:5px}.ezOpacity{filter:alpha(opacity=60);opacity:.6}.alignLeft{text-align:left}.alignCenter{text-align:center}.alignRight{text-align:right}.icnImg{border:0}
|
9
src/extensions/ezEditTable/ezEditTable.js
Normal file
BIN
src/extensions/ezEditTable/themes/bg_mod_cell.png
Normal file
After Width: | Height: | Size: 234 B |
23
src/extensions/ezEditTable/themes/default/ezDefault.css
Normal file
|
@ -0,0 +1,23 @@
|
|||
/*====================================================
|
||||
- ezEditTable default theme stylesheet
|
||||
- Edit classes below for your project needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
border:0 !important;
|
||||
border-left:1px solid #99BBE8 !important;
|
||||
border-right:1px solid #99BBE8 !important;
|
||||
border-bottom:1px solid #99BBE8 !important;
|
||||
font:12px/13px arial, tahoma, helvetica, sans-serif !important;
|
||||
}
|
||||
.ezEditableTable th, td{ border:1px solid #C5D3EC !important; }
|
||||
.ezEditableTable th{
|
||||
background:transparent url(img/bg_col_header.gif) 0 -2px repeat-x !important;
|
||||
}
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow td{ background-color:#316AC5; color:#fff !important; }
|
||||
.ezSelectedRow{ background-color:#D9E8FB !important; border:1px dotted #909090 !important; color:#000; }
|
||||
|
||||
/* Command type editor */
|
||||
.ezCommandEditor button{ border:1px solid #C5D3EC !important; }
|
BIN
src/extensions/ezEditTable/themes/default/img/bg_col_header.gif
Normal file
After Width: | Height: | Size: 875 B |
BIN
src/extensions/ezEditTable/themes/icn_add.gif
Normal file
After Width: | Height: | Size: 398 B |
BIN
src/extensions/ezEditTable/themes/icn_cross.png
Normal file
After Width: | Height: | Size: 655 B |
BIN
src/extensions/ezEditTable/themes/icn_del.gif
Normal file
After Width: | Height: | Size: 330 B |
BIN
src/extensions/ezEditTable/themes/icn_edit.gif
Normal file
After Width: | Height: | Size: 342 B |
BIN
src/extensions/ezEditTable/themes/icn_save.gif
Normal file
After Width: | Height: | Size: 375 B |
BIN
src/extensions/ezEditTable/themes/icn_tick.png
Normal file
After Width: | Height: | Size: 537 B |
68
src/extensions/ezEditTable/themes/skyblue/ezSkyBlue.css
Normal file
|
@ -0,0 +1,68 @@
|
|||
/*====================================================
|
||||
- ezEditTable SkyBlue theme stylesheet
|
||||
- Edit classes below for your project needs
|
||||
=====================================================*/
|
||||
|
||||
.ezEditableTable{
|
||||
padding:0; color:#000;
|
||||
font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important;
|
||||
border-right:1px solid #A4BED4;
|
||||
border-top:1px solid #A4BED4;
|
||||
border-left:1px solid #A4BED4;
|
||||
border-bottom:0;
|
||||
}
|
||||
.ezEditableTable td{
|
||||
margin:0; padding:5px; color:inherit;
|
||||
border-bottom:1px solid #A4BED4;
|
||||
border-left:0; border-top:0; border-right:0;
|
||||
}
|
||||
.ezEditableTable th{
|
||||
margin:0; padding:5px; color:inherit;
|
||||
background:#D1E5FE url("img/sky_blue_grid.gif") 0 0 repeat-x !important;
|
||||
border-color:#FDFDFD #A4BED4 #A4BED4 #FDFDFD;
|
||||
border-width:1px; border-style:solid;
|
||||
}
|
||||
.ezModifiedCell{ background:transparent url(../bg_mod_cell.png) 0 0 no-repeat !important; }
|
||||
|
||||
/* Selection */
|
||||
.ezActiveRow td{ background:#D9E8FB; border-top:1px solid #FDFDFD; border-bottom:1px solid #A4BED4 !important; color:#000 !important; }
|
||||
.ezSelectedRow{ background:#D1E5FE url("img/sky_blue_grid.gif") 0 0 repeat-x !important; color:#000; }
|
||||
td.ezActiveCell{
|
||||
background-color:#fff !important; color:#000 !important;
|
||||
font-weight:bold; font-style:italic; border-bottom:0;
|
||||
border-top:1px solid #FDFDFD !important;
|
||||
border-left:1px solid #A4BED4 !important;
|
||||
border-right:1px solid #A4BED4 !important;
|
||||
}
|
||||
.ezUnselectable{
|
||||
-moz-user-select: -moz-none;
|
||||
-khtml-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-o-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
/* Editors */
|
||||
.ezInputEditor{ width:100%; height:auto; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:0; }
|
||||
.ezTextareaEditor{ width:100%; height:25px; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:0; overflow:auto; }
|
||||
.ezSelectEditor{ width:100%; font:12px/13px "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif !important; border:1px solid #AACCF6; }
|
||||
select[multiple="multiple"].ezSelectEditor{ height:35px; }
|
||||
|
||||
/* Command type editor */
|
||||
.ezCommandEditor button{
|
||||
margin:2px !important; background:#D1E5FE;
|
||||
border:1px solid #A4BED4;
|
||||
font-size:12px !important;
|
||||
border-radius:4px 4px 4px 4px;
|
||||
-moz-border-radius:4px 4px 4px 4px;
|
||||
}
|
||||
.ezCommandEditor button img{ vertical-align:middle; margin:2px; }
|
||||
|
||||
/* Utils */
|
||||
.ezOpacity{
|
||||
filter:alpha(opacity=60); /* for IE */
|
||||
opacity:0.6; /* CSS3 standard */
|
||||
}
|
||||
.alignLeft{ text-align:left; }
|
||||
.alignCenter{ text-align:center; }
|
||||
.alignRight{ text-align:right; }
|
BIN
src/extensions/ezEditTable/themes/skyblue/img/sky_blue_grid.gif
Normal file
After Width: | Height: | Size: 554 B |
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../../types", "../../dom", "../../array", "../../event", "../../date", "../../helpers"], function (exports, _types, _dom, _array, _event, _date, _helpers) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Types = _types.Types;
|
||||
var Dom = _dom.Dom;
|
||||
var array = _array.Arr;
|
||||
|
@ -58,7 +61,7 @@ define(["exports", "../../types", "../../dom", "../../array", "../../event", "..
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(AdapterSortableTable, null, {
|
||||
_createClass(AdapterSortableTable, {
|
||||
init: {
|
||||
value: function init() {
|
||||
var tf = this.tf;
|
||||
|
@ -155,9 +158,7 @@ define(["exports", "../../types", "../../dom", "../../array", "../../event", "..
|
|||
adpt.onAfterSort.call(null, tf, tf.stt.sortColumn);
|
||||
}
|
||||
};
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
sortByColumnIndex: {
|
||||
|
||||
|
@ -168,9 +169,7 @@ define(["exports", "../../types", "../../dom", "../../array", "../../event", "..
|
|||
|
||||
value: function sortByColumnIndex(colIdx) {
|
||||
this.stt.sort(colIdx);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
overrideSortableTable: {
|
||||
value: function overrideSortableTable() {
|
||||
|
@ -312,16 +311,12 @@ define(["exports", "../../types", "../../dom", "../../array", "../../event", "..
|
|||
return Dom.getText(oNode);
|
||||
}
|
||||
};
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
addSortType: {
|
||||
value: function addSortType() {
|
||||
SortableTable.prototype.addSortType(arguments[0], arguments[1], arguments[2], arguments[3]);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setSortTypes: {
|
||||
value: function setSortTypes() {
|
||||
|
@ -395,9 +390,7 @@ define(["exports", "../../types", "../../dom", "../../array", "../../event", "..
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
|
||||
|
@ -420,9 +413,7 @@ define(["exports", "../../types", "../../dom", "../../array", "../../event", "..
|
|||
header.removeChild(img[0]);
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -475,8 +466,5 @@ define(["exports", "../../types", "../../dom", "../../array", "../../event", "..
|
|||
return 1;
|
||||
}
|
||||
}
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=adapterSortabletable.js.map
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports", "string"], function (exports, _string) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* Misc helpers
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Str = _string.Str;
|
||||
|
||||
var Helpers = {
|
||||
|
|
|
@ -120,6 +120,12 @@
|
|||
btn_reset: true,
|
||||
status_bar: true,
|
||||
watermark: [null, 'Filter column...', null, null, 'Helo'],
|
||||
selectable: true,
|
||||
editable: true,
|
||||
ezEditTable_config:{
|
||||
default_selection: 'both',
|
||||
base_path: 'extensions/ezEditTable/'
|
||||
},
|
||||
grid_layout: false,
|
||||
// grid_width: '500px',
|
||||
// grid_height: '200px',
|
||||
|
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom"], function (exports, _dom) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
|
||||
var AlternateRows = exports.AlternateRows = (function () {
|
||||
|
@ -26,7 +29,7 @@ define(["exports", "../dom"], function (exports, _dom) {
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(AlternateRows, null, {
|
||||
_createClass(AlternateRows, {
|
||||
init: {
|
||||
|
||||
/**
|
||||
|
@ -51,9 +54,7 @@ define(["exports", "../dom"], function (exports, _dom) {
|
|||
this.setRowBg(rowIdx, idx);
|
||||
idx++;
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setRowBg: {
|
||||
|
||||
|
@ -72,9 +73,7 @@ define(["exports", "../dom"], function (exports, _dom) {
|
|||
var i = !idx ? rowIdx : idx;
|
||||
this.removeRowBg(rowIdx);
|
||||
Dom.addClass(rows[rowIdx], i % 2 ? this.evenCss : this.oddCss);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
removeRowBg: {
|
||||
|
||||
|
@ -90,9 +89,7 @@ define(["exports", "../dom"], function (exports, _dom) {
|
|||
var rows = this.tf.tbl.rows;
|
||||
Dom.removeClass(rows[idx], this.oddCss);
|
||||
Dom.removeClass(rows[idx], this.evenCss);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
remove: {
|
||||
|
||||
|
@ -109,31 +106,21 @@ define(["exports", "../dom"], function (exports, _dom) {
|
|||
this.removeRowBg(i);
|
||||
}
|
||||
this.tf.isStartBgAlternate = true;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
enable: {
|
||||
value: function enable() {
|
||||
this.tf.alternateBgs = true;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
disable: {
|
||||
value: function disable() {
|
||||
this.tf.alternateBgs = false;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return AlternateRows;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=alternateRows.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../array", "../string", "../sort", "../event"], function (exports, _dom, _array, _string, _sort, _event) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var array = _array.Arr;
|
||||
var Str = _string.Str;
|
||||
|
@ -46,24 +49,20 @@ define(["exports", "../dom", "../array", "../string", "../sort", "../event"], fu
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(CheckList, null, {
|
||||
_createClass(CheckList, {
|
||||
onChange: {
|
||||
|
||||
// TODO: add _OnSlcChange event here
|
||||
|
||||
value: function onChange(evt) {
|
||||
this.tf.Evt._OnSlcChange(evt);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
optionClick: {
|
||||
value: function optionClick(evt) {
|
||||
this.setCheckListValues(evt.target);
|
||||
this.onChange(evt);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
build: {
|
||||
|
||||
|
@ -77,9 +76,7 @@ define(["exports", "../dom", "../array", "../string", "../sort", "../event"], fu
|
|||
value: function build(colIndex, isExternal, extFltId) {
|
||||
var tf = this.tf;
|
||||
tf.EvtManager(tf.Evt.name.checklist, { slcIndex: colIndex, slcExternal: isExternal, slcId: extFltId });
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_build: {
|
||||
|
||||
|
@ -235,9 +232,7 @@ define(["exports", "../dom", "../array", "../string", "../sort", "../event"], fu
|
|||
}
|
||||
flt.appendChild(ul);
|
||||
flt.setAttribute("filled", "1");
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
addChecks: {
|
||||
|
||||
|
@ -294,9 +289,7 @@ define(["exports", "../dom", "../array", "../string", "../sort", "../event"], fu
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
addTChecks: {
|
||||
|
||||
|
@ -343,9 +336,7 @@ define(["exports", "../dom", "../array", "../string", "../sort", "../event"], fu
|
|||
chkCt++;
|
||||
}
|
||||
return chkCt;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setCheckListValues: {
|
||||
|
||||
|
@ -424,17 +415,11 @@ define(["exports", "../dom", "../array", "../string", "../sort", "../event"], fu
|
|||
Dom.removeClass(li, this.checkListSlcItemCssClass);
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return CheckList;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=checkList.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Event = _event.Event;
|
||||
|
||||
|
@ -35,13 +38,11 @@ define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(ClearButton, null, {
|
||||
_createClass(ClearButton, {
|
||||
onClick: {
|
||||
value: function onClick() {
|
||||
this.tf.clearFilters();
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
init: {
|
||||
|
||||
|
@ -85,9 +86,7 @@ define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
|||
});
|
||||
}
|
||||
this.btnResetEl = resetspan.firstChild;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
|
||||
|
@ -107,17 +106,11 @@ define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
|||
resetspan.parentNode.removeChild(resetspan);
|
||||
}
|
||||
this.btnResetEl = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return ClearButton;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=clearButton.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../string", "../types"], function (exports, _dom, _string, _types) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Str = _string.Str;
|
||||
var Types = _types.Types;
|
||||
|
@ -30,7 +33,7 @@ define(["exports", "../dom", "../string", "../types"], function (exports, _dom,
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(ColOps, null, {
|
||||
_createClass(ColOps, {
|
||||
calc: {
|
||||
|
||||
/**
|
||||
|
@ -300,17 +303,11 @@ define(["exports", "../dom", "../string", "../types"], function (exports, _dom,
|
|||
if (this.onAfterOperation) {
|
||||
this.onAfterOperation.call(null, this.tf);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return ColOps;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=colOps.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../array", "../string", "../sort"], function (exports, _dom, _array, _string, _sort) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var array = _array.Arr;
|
||||
var Str = _string.Str;
|
||||
|
@ -41,7 +44,7 @@ define(["exports", "../dom", "../array", "../string", "../sort"], function (expo
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(Dropdown, null, {
|
||||
_createClass(Dropdown, {
|
||||
build: {
|
||||
|
||||
/**
|
||||
|
@ -60,9 +63,7 @@ define(["exports", "../dom", "../array", "../string", "../sort"], function (expo
|
|||
slcExternal: isExternal,
|
||||
slcId: extSlcId
|
||||
});
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_build: {
|
||||
|
||||
|
@ -231,9 +232,7 @@ define(["exports", "../dom", "../array", "../string", "../sort"], function (expo
|
|||
|
||||
//populates drop-down
|
||||
this.addOptions(colIndex, slc, isRefreshed, excludedOpts, fltsValues, fltArr);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
addOptions: {
|
||||
|
||||
|
@ -295,9 +294,7 @@ define(["exports", "../dom", "../array", "../string", "../sort"], function (expo
|
|||
slc.innerHTML += this.slcInnerHtml;
|
||||
}
|
||||
slc.setAttribute("filled", "1");
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
addFirstOption: {
|
||||
|
||||
|
@ -328,17 +325,11 @@ define(["exports", "../dom", "../array", "../string", "../sort"], function (expo
|
|||
}
|
||||
}
|
||||
return slc;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return Dropdown;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=dropdown.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../types", "../helpers", "../event"], function (exports, _dom, _types, _helpers, _event) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Types = _types.Types;
|
||||
var Helpers = _helpers.Helpers;
|
||||
|
@ -52,7 +55,7 @@ define(["exports", "../dom", "../types", "../helpers", "../event"], function (ex
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(GridLayout, null, {
|
||||
_createClass(GridLayout, {
|
||||
init: {
|
||||
|
||||
/**
|
||||
|
@ -312,9 +315,7 @@ define(["exports", "../dom", "../types", "../helpers", "../event"], function (ex
|
|||
|
||||
// Re-adjust reference row
|
||||
//tf.refRow = Helpers.isIE() ? (tf.refRow+1) : 0;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
|
||||
|
@ -341,17 +342,11 @@ define(["exports", "../dom", "../types", "../helpers", "../event"], function (ex
|
|||
tbl.outerHTML = tf.sourceTblHtml;
|
||||
//needed to keep reference of table element
|
||||
tbl = Dom.id(tf.id);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return GridLayout;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=gridLayout.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Event = _event.Event;
|
||||
|
||||
|
@ -46,7 +49,7 @@ define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(Help, null, {
|
||||
_createClass(Help, {
|
||||
init: {
|
||||
value: function init() {
|
||||
var _this = this;
|
||||
|
@ -112,9 +115,7 @@ define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
|||
|
||||
this.helpInstrContEl = helpdiv;
|
||||
this.helpInstrBtnEl = helpspan;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
toggle: {
|
||||
|
||||
|
@ -137,9 +138,7 @@ define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
|||
} else {
|
||||
this.helpInstrContEl.style.display = "none";
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
|
||||
|
@ -158,17 +157,11 @@ define(["exports", "../dom", "../event"], function (exports, _dom, _event) {
|
|||
}
|
||||
this.helpInstrContEl.parentNode.removeChild(this.helpInstrContEl);
|
||||
this.helpInstrContEl = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return Help;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=help.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../string"], function (exports, _dom, _string) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Str = _string.Str;
|
||||
|
||||
|
@ -26,7 +29,7 @@ define(["exports", "../dom", "../string"], function (exports, _dom, _string) {
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(HighlightKeyword, null, {
|
||||
_createClass(HighlightKeyword, {
|
||||
highlight: {
|
||||
|
||||
/**
|
||||
|
@ -71,9 +74,7 @@ define(["exports", "../dom", "../string"], function (exports, _dom, _string) {
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
unhighlight: {
|
||||
|
||||
|
@ -111,9 +112,7 @@ define(["exports", "../dom", "../string"], function (exports, _dom, _string) {
|
|||
for (var k = 0; k < arrRemove.length; k++) {
|
||||
highlightedNodes.splice(arrRemove[k], 1);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
unhighlightAll: {
|
||||
|
||||
|
@ -129,17 +128,11 @@ define(["exports", "../dom", "../string"], function (exports, _dom, _string) {
|
|||
this.unhighlight(this.tf.searchArgs[y], this.highlightCssClass);
|
||||
}
|
||||
this.highlightedNodes = [];
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return HighlightKeyword;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=highlightKeywords.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../types"], function (exports, _dom, _types) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Types = _types.Types;
|
||||
|
||||
|
@ -57,7 +60,7 @@ define(["exports", "../dom", "../types"], function (exports, _dom, _types) {
|
|||
}
|
||||
}
|
||||
|
||||
_prototypeProperties(Loader, null, {
|
||||
_createClass(Loader, {
|
||||
show: {
|
||||
value: function show(p) {
|
||||
var _this = this;
|
||||
|
@ -81,9 +84,7 @@ define(["exports", "../dom", "../types"], function (exports, _dom, _types) {
|
|||
|
||||
var t = p === "none" ? this.loaderCloseDelay : 1;
|
||||
global.setTimeout(displayLoader, t);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
remove: {
|
||||
value: function remove() {
|
||||
|
@ -94,17 +95,11 @@ define(["exports", "../dom", "../types"], function (exports, _dom, _types) {
|
|||
targetEl = !this.loaderTgtId ? tf.gridLayout ? tf.Cpt.gridLayout.tblCont : tf.tbl.parentNode : Dom.id(this.loaderTgtId);
|
||||
targetEl.removeChild(this.loaderDiv);
|
||||
this.loaderDiv = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return Loader;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=loader.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../types", "../string", "../helpers", "../event"], function (exports, _dom, _types, _string, _helpers, _event) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Types = _types.Types;
|
||||
var Str = _string.Str;
|
||||
|
@ -135,7 +138,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(Paging, null, {
|
||||
_createClass(Paging, {
|
||||
init: {
|
||||
|
||||
/**
|
||||
|
@ -270,9 +273,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
}
|
||||
|
||||
this.isPagingRemoved = false;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
addPaging: {
|
||||
|
||||
|
@ -295,9 +296,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
if (filterTable) {
|
||||
tf.filter();
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setPagingInfo: {
|
||||
|
||||
|
@ -357,9 +356,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
mdiv.style.visibility = "hidden";
|
||||
}
|
||||
this.groupByPage(tf.validRowsIndex);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
groupByPage: {
|
||||
|
||||
|
@ -400,9 +397,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
tf.isStartBgAlternate = false;
|
||||
//re-applies filter behaviours after filtering process
|
||||
tf.applyGridProps();
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setPage: {
|
||||
|
||||
|
@ -414,7 +409,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
|
||||
value: function setPage(cmd) {
|
||||
var tf = this.tf;
|
||||
if (!tf.hasGrid() || !this.paging) {
|
||||
if (!tf.hasGrid() || !tf.paging) {
|
||||
return;
|
||||
}
|
||||
var btnEvt = this.evt,
|
||||
|
@ -440,9 +435,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
} else if (cmdtype === "number") {
|
||||
this.changePage(cmd - 1);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setResultsPerPage: {
|
||||
|
||||
|
@ -494,9 +487,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
this.resultsPerPageSlc.options[r] = currOpt;
|
||||
}
|
||||
Event.add(slcR, "change", evt.slcResultsChange);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
removeResultsPerPage: {
|
||||
|
||||
|
@ -518,9 +509,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
slcRSpan.parentNode.removeChild(slcRSpan);
|
||||
}
|
||||
this.resultsPerPageSlc = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
changePage: {
|
||||
|
||||
|
@ -533,9 +522,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
var tf = this.tf;
|
||||
var evt = tf.Evt;
|
||||
tf.EvtManager(evt.name.changepage, { pgIndex: index });
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
changeResultsPerPage: {
|
||||
|
||||
|
@ -547,9 +534,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
var tf = this.tf;
|
||||
var evt = tf.Evt;
|
||||
tf.EvtManager(evt.name.changeresultsperpage);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
resetPage: {
|
||||
|
||||
|
@ -561,9 +546,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
var tf = this.tf;
|
||||
var evt = tf.Evt;
|
||||
tf.EvtManager(evt.name.resetpage);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
resetPageLength: {
|
||||
|
||||
|
@ -575,9 +558,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
var tf = this.tf;
|
||||
var evt = tf.Evt;
|
||||
tf.EvtManager(evt.name.resetpagelength);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_changePage: {
|
||||
|
||||
|
@ -617,9 +598,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
this.onAfterChangePage.call(null, this, index);
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_changeResultsPerPage: {
|
||||
|
||||
|
@ -652,9 +631,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
tf.Cpt.store.savePageLength(tf.pgLenCookie);
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_resetPage: {
|
||||
|
||||
|
@ -668,9 +645,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
if (pgnb !== "") {
|
||||
this.changePage(pgnb - 1);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_resetPageLength: {
|
||||
|
||||
|
@ -689,9 +664,7 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
this.resultsPerPageSlc.options[pglenIndex].selected = true;
|
||||
this.changeResultsPerPage();
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
|
||||
|
@ -770,17 +743,11 @@ define(["exports", "../dom", "../types", "../string", "../helpers", "../event"],
|
|||
this.nbPages = 0;
|
||||
this.isPagingRemoved = true;
|
||||
tf.paging = false;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return Paging;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=paging.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../types", "../dom", "../event", "../helpers"], function (exports, _types, _dom, _event, _helpers) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Types = _types.Types;
|
||||
var Dom = _dom.Dom;
|
||||
var Event = _event.Event;
|
||||
|
@ -54,7 +57,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(PopupFilter, null, {
|
||||
_createClass(PopupFilter, {
|
||||
onClick: {
|
||||
value: function onClick(e) {
|
||||
var evt = e || global.event,
|
||||
|
@ -76,9 +79,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
}
|
||||
Event.cancel(evt);
|
||||
Event.stop(evt);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
init: {
|
||||
|
||||
|
@ -104,9 +105,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
this.popUpFltSpans[i] = popUpSpan;
|
||||
this.popUpFltImgs[i] = popUpSpan.firstChild;
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
buildAll: {
|
||||
|
||||
|
@ -118,9 +117,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
for (var i = 0; i < this.popUpFltElmCache.length; i++) {
|
||||
this.build(i, this.popUpFltElmCache[i]);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
build: {
|
||||
|
||||
|
@ -141,9 +138,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
Event.stop(evt);
|
||||
});
|
||||
this.popUpFltElms[colIndex] = popUpDiv;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
toggle: {
|
||||
|
||||
|
@ -176,9 +171,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
this.onAfterPopUpClose.call(null, this, this.popUpFltElms[colIndex], colIndex);
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
closeAll: {
|
||||
|
||||
|
@ -197,9 +190,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
popUpFltElm.style.display = "none";
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
buildIcons: {
|
||||
|
||||
|
@ -211,9 +202,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
for (var i = 0; i < this.popUpFltImgs.length; i++) {
|
||||
this.buildIcon(i, false);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
buildIcon: {
|
||||
|
||||
|
@ -228,9 +217,7 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
if (this.popUpFltImgs[colIndex]) {
|
||||
this.popUpFltImgs[colIndex].src = active ? this.popUpImgFltActive : this.popUpImgFlt;
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
|
||||
|
@ -261,17 +248,11 @@ define(["exports", "../types", "../dom", "../event", "../helpers"], function (ex
|
|||
this.popUpFltElms = [];
|
||||
this.popUpFltSpans = [];
|
||||
this.popUpFltImgs = [];
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return PopupFilter;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=popupFilter.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../types", "../helpers"], function (exports, _dom, _types, _helpers) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Types = _types.Types;
|
||||
var Helpers = _helpers.Helpers;
|
||||
|
@ -42,7 +45,7 @@ define(["exports", "../dom", "../types", "../helpers"], function (exports, _dom,
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(RowsCounter, null, {
|
||||
_createClass(RowsCounter, {
|
||||
init: {
|
||||
value: function init() {
|
||||
var tf = this.tf;
|
||||
|
@ -83,9 +86,7 @@ define(["exports", "../dom", "../types", "../helpers"], function (exports, _dom,
|
|||
this.rowsCounterSpan = countSpan;
|
||||
|
||||
this.refresh();
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
refresh: {
|
||||
value: function refresh(p) {
|
||||
|
@ -119,9 +120,7 @@ define(["exports", "../dom", "../types", "../helpers"], function (exports, _dom,
|
|||
if (this.onAfterRefreshCounter) {
|
||||
this.onAfterRefreshCounter.call(null, tf, this.rowsCounterSpan, totTxt);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
value: function destroy() {
|
||||
|
@ -145,17 +144,11 @@ define(["exports", "../dom", "../types", "../helpers"], function (exports, _dom,
|
|||
}
|
||||
this.rowsCounterSpan = null;
|
||||
this.rowsCounterDiv = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return RowsCounter;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=rowsCounter.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../dom", "../event", "../types", "../helpers"], function (exports, _dom, _event, _types, _helpers) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Dom = _dom.Dom;
|
||||
var Event = _event.Event;
|
||||
var Types = _types.Types;
|
||||
|
@ -48,7 +51,7 @@ define(["exports", "../dom", "../event", "../types", "../helpers"], function (ex
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(StatusBar, null, {
|
||||
_createClass(StatusBar, {
|
||||
init: {
|
||||
value: function init() {
|
||||
var tf = this.tf;
|
||||
|
@ -91,9 +94,7 @@ define(["exports", "../dom", "../event", "../types", "../helpers"], function (ex
|
|||
this.statusBarDiv = statusDiv;
|
||||
this.statusBarSpan = statusSpan;
|
||||
this.statusBarSpanText = statusSpanText;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
message: {
|
||||
value: function message() {
|
||||
|
@ -116,9 +117,7 @@ define(["exports", "../dom", "../event", "../types", "../helpers"], function (ex
|
|||
_this.onAfterShowMsg.call(null, _this.tf, t);
|
||||
}
|
||||
}, d);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
destroy: {
|
||||
value: function destroy() {
|
||||
|
@ -132,17 +131,11 @@ define(["exports", "../dom", "../event", "../types", "../helpers"], function (ex
|
|||
this.statusBarSpan = null;
|
||||
this.statusBarSpanText = null;
|
||||
this.statusBarDiv = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return StatusBar;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=statusBar.js.map
|
|
@ -1,10 +1,13 @@
|
|||
define(["exports", "../cookie"], function (exports, _cookie) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var Cookie = _cookie.Cookie;
|
||||
|
||||
var Store = exports.Store = (function () {
|
||||
|
@ -24,7 +27,7 @@ define(["exports", "../cookie"], function (exports, _cookie) {
|
|||
this.tf = tf;
|
||||
}
|
||||
|
||||
_prototypeProperties(Store, null, {
|
||||
_createClass(Store, {
|
||||
saveFilterValues: {
|
||||
|
||||
/**
|
||||
|
@ -48,9 +51,7 @@ define(["exports", "../cookie"], function (exports, _cookie) {
|
|||
|
||||
//writes cookie
|
||||
Cookie.write(name, fltValues.join(tf.separator), this.duration);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFilterValues: {
|
||||
|
||||
|
@ -65,9 +66,7 @@ define(["exports", "../cookie"], function (exports, _cookie) {
|
|||
var rgx = new RegExp(this.tf.separator, "g");
|
||||
// filters' values array
|
||||
return flts.split(rgx);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
savePageNb: {
|
||||
|
||||
|
@ -78,9 +77,7 @@ define(["exports", "../cookie"], function (exports, _cookie) {
|
|||
|
||||
value: function savePageNb(name) {
|
||||
Cookie.write(name, this.tf.Cpt.paging.currentPageNb, this.duration);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getPageNb: {
|
||||
|
||||
|
@ -92,9 +89,7 @@ define(["exports", "../cookie"], function (exports, _cookie) {
|
|||
|
||||
value: function getPageNb(name) {
|
||||
return Cookie.read(name);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
savePageLength: {
|
||||
|
||||
|
@ -105,9 +100,7 @@ define(["exports", "../cookie"], function (exports, _cookie) {
|
|||
|
||||
value: function savePageLength(name) {
|
||||
Cookie.write(name, this.tf.Cpt.paging.resultsPerPageSlc.selectedIndex, this.duration);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getPageLength: {
|
||||
|
||||
|
@ -119,17 +112,11 @@ define(["exports", "../cookie"], function (exports, _cookie) {
|
|||
|
||||
value: function getPageLength(name) {
|
||||
return Cookie.read(name);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return Store;
|
||||
})();
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
});
|
||||
//# sourceMappingURL=store.js.map
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports", "string"], function (exports, _string) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* Sort helpers
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Str = _string.Str;
|
||||
|
||||
var Sort = {
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports"], function (exports) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* String utilities
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Str = {};
|
||||
|
||||
Str.lower = function (text) {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
define(["exports", "module", "event", "dom", "string", "cookie", "types", "array", "helpers", "date", "sort", "modules/store", "modules/gridLayout", "modules/loader", "modules/highlightKeywords", "modules/popupFilter", "modules/dropdown", "modules/checkList", "modules/rowsCounter", "modules/statusBar", "modules/paging", "modules/clearButton", "modules/help", "modules/alternateRows", "modules/colOps", "extensions/sortabletable/sortabletable", "extensions/sortabletable/adapterSortabletable"], function (exports, module, _event, _dom, _string, _cookie, _types, _array, _helpers, _date, _sort, _modulesStore, _modulesGridLayout, _modulesLoader, _modulesHighlightKeywords, _modulesPopupFilter, _modulesDropdown, _modulesCheckList, _modulesRowsCounter, _modulesStatusBar, _modulesPaging, _modulesClearButton, _modulesHelp, _modulesAlternateRows, _modulesColOps, _extensionsSortabletableSortabletable, _extensionsSortabletableAdapterSortabletable) {
|
||||
"use strict";
|
||||
|
||||
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var key in props) { var prop = props[key]; prop.configurable = true; if (prop.value) prop.writable = true; } Object.defineProperties(target, props); } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
|
||||
|
||||
|
@ -394,11 +394,11 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.editable = f.editable === true ? true : false;
|
||||
this.ezEditTableConfig = f.ezEditTable_config || {};
|
||||
this.ezEditTableConfig.name = this.ezEditTableConfig.name !== undefined ? f.ezEditTable_config.name : "ezedittable";
|
||||
this.ezEditTableConfig.src = this.ezEditTableConfig.src !== undefined ? f.ezEditTable_config.src : this.basePath + "ezEditTable/ezEditTable.js";
|
||||
this.ezEditTableConfig.src = this.ezEditTableConfig.src !== undefined ? f.ezEditTable_config.src : this.basePath + "extensions/ezEditTable/ezEditTable.js";
|
||||
//ezEditTable stylesheet not imported by default as filtergrid.css
|
||||
//applies
|
||||
this.ezEditTableConfig.loadStylesheet = this.ezEditTableConfig.loadStylesheet === true ? true : false;
|
||||
this.ezEditTableConfig.stylesheet = this.ezEditTableConfig.stylesheet || this.basePath + "ezEditTable/ezEditTable.css";
|
||||
this.ezEditTableConfig.stylesheet = this.ezEditTableConfig.stylesheet || this.basePath + "extensions/ezEditTable/ezEditTable.css";
|
||||
this.ezEditTableConfig.stylesheetName = this.ezEditTableConfig.stylesheetName !== undefined ? f.ezEditTable_config.stylesheetName : "ezEditTableCss";
|
||||
this.ezEditTableConfig.err = "Failed to instantiate EditTable " + "object.\n\"ezEditTable\" module may not be available.";
|
||||
|
||||
|
@ -597,7 +597,8 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
|
||||
// Extensions registry
|
||||
this.Extensions = {
|
||||
sort: null
|
||||
sort: null,
|
||||
ezEditTable: null
|
||||
};
|
||||
|
||||
/*** TF events ***/
|
||||
|
@ -803,7 +804,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
};
|
||||
}
|
||||
|
||||
_prototypeProperties(TableFilter, null, {
|
||||
_createClass(TableFilter, {
|
||||
init: {
|
||||
|
||||
/*====================================================
|
||||
|
@ -1125,7 +1126,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.setSort();
|
||||
}
|
||||
if (this.selectable || this.editable) {
|
||||
this.SetEditable();
|
||||
this.setEditable();
|
||||
}
|
||||
|
||||
this.isFirstLoad = false;
|
||||
|
@ -1152,9 +1153,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
if (this.onFiltersLoaded) {
|
||||
this.onFiltersLoaded.call(null, this);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
EvtManager: {
|
||||
|
||||
|
@ -1246,9 +1245,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
} else {
|
||||
efx();
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
ImportModule: {
|
||||
value: function ImportModule(module) {
|
||||
|
@ -1256,9 +1253,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
this.includeFile(module.name, module.path, module.init);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
LoadExtensions: {
|
||||
value: function LoadExtensions() {
|
||||
|
@ -1282,9 +1277,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
};
|
||||
}
|
||||
this.EvtManager(this.Evt.name.loadextensions);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_LoadExtensions: {
|
||||
|
||||
|
@ -1311,16 +1304,12 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.includeFile(extName, extPath, extInit);
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
LoadThemes: {
|
||||
value: function LoadThemes() {
|
||||
this.EvtManager(this.Evt.name.loadthemes);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_LoadThemes: {
|
||||
|
||||
|
@ -1396,9 +1385,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.loader = true;
|
||||
this.loaderHtml = "<div class=\"defaultLoader\"></div>";
|
||||
this.loaderText = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
remove: {
|
||||
|
||||
|
@ -1447,7 +1434,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.clearActiveColumns();
|
||||
}
|
||||
if (this.editable || this.selectable) {
|
||||
this.RemoveEditable();
|
||||
this.removeEditable();
|
||||
}
|
||||
//this loop shows all rows and removes validRow attribute
|
||||
for (var j = this.refRow; j < this.nbRows; j++) {
|
||||
|
@ -1486,9 +1473,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this._hasGrid = false;
|
||||
this.tbl = null;
|
||||
} //if this.fltGrid
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setToolbar: {
|
||||
|
||||
|
@ -1549,9 +1534,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
this.Cpt.help.init();
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
removeToolbar: {
|
||||
|
||||
|
@ -1566,9 +1549,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
this.infDiv.parentNode.removeChild(this.infDiv);
|
||||
this.infDiv = null;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
removeExternalFlts: {
|
||||
|
||||
|
@ -1587,9 +1568,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
externalFlt.innerHTML = "";
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setSort: {
|
||||
|
||||
|
@ -1603,9 +1582,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
var adapterSortabletable = new AdapterSortableTable(this);
|
||||
this.Extensions.sort = adapterSortabletable;
|
||||
adapterSortabletable.init();
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setOldSort: {
|
||||
value: function setOldSort() {
|
||||
|
@ -1704,9 +1681,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
// }
|
||||
// );
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
performSort: {
|
||||
|
||||
|
@ -1719,38 +1694,34 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
|
||||
value: function performSort() {
|
||||
this.EvtManager(this.Evt.name.sort);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
SetEditable: {
|
||||
setEditable: {
|
||||
|
||||
/*====================================================
|
||||
- Sets selection or edition features by loading
|
||||
ezEditTable script by Max Guglielmi
|
||||
=====================================================*/
|
||||
|
||||
value: function SetEditable() {
|
||||
value: function setEditable() {
|
||||
var ezEditConfig = this.ezEditTableConfig;
|
||||
if (this.isImported(ezEditConfig.src)) {
|
||||
this._EnableEditable();
|
||||
this._enableEditable();
|
||||
} else {
|
||||
this.includeFile(ezEditConfig.name, ezEditConfig.src, this._EnableEditable);
|
||||
this.includeFile(ezEditConfig.name, ezEditConfig.src, this._enableEditable);
|
||||
}
|
||||
if (ezEditConfig.loadStylesheet && !this.isImported(ezEditConfig.stylesheet, "link")) {
|
||||
this.includeFile(ezEditConfig.stylesheetName, ezEditConfig.stylesheet, null, "link");
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
RemoveEditable: {
|
||||
removeEditable: {
|
||||
|
||||
/*====================================================
|
||||
- Removes selection or edition features
|
||||
=====================================================*/
|
||||
|
||||
value: function RemoveEditable() {
|
||||
value: function removeEditable() {
|
||||
var ezEditTable = this.ezEditTable;
|
||||
if (ezEditTable) {
|
||||
if (this.selectable) {
|
||||
|
@ -1761,18 +1732,16 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
ezEditTable.Editable.Remove();
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
ResetEditable: {
|
||||
resetEditable: {
|
||||
|
||||
/*====================================================
|
||||
- Resets selection or edition features after
|
||||
removal
|
||||
=====================================================*/
|
||||
|
||||
value: function ResetEditable() {
|
||||
value: function resetEditable() {
|
||||
var ezEditTable = this.ezEditTable;
|
||||
if (ezEditTable) {
|
||||
if (this.selectable) {
|
||||
|
@ -1782,12 +1751,10 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
ezEditTable.Editable.Set();
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_EnableEditable: {
|
||||
value: function _EnableEditable(o) {
|
||||
_enableEditable: {
|
||||
value: function _enableEditable(o) {
|
||||
if (!o) {
|
||||
o = this;
|
||||
}
|
||||
|
@ -1825,6 +1792,40 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
//Row navigation needs to be calculated according to TableFilter's
|
||||
//validRowsIndex array
|
||||
var onAfterSelection = function onAfterSelection(et, selectedElm, e) {
|
||||
var slc = et.Selection;
|
||||
//Next valid filtered row needs to be selected
|
||||
var doSelect = function doSelect(nextRowIndex) {
|
||||
if (et.defaultSelection === "row") {
|
||||
slc.SelectRowByIndex(nextRowIndex);
|
||||
} else {
|
||||
et.ClearSelections();
|
||||
var cellIndex = selectedElm.cellIndex,
|
||||
row = o.tbl.rows[nextRowIndex];
|
||||
if (et.defaultSelection === "both") {
|
||||
slc.SelectRowByIndex(nextRowIndex);
|
||||
}
|
||||
if (row) {
|
||||
slc.SelectCell(row.cells[cellIndex]);
|
||||
}
|
||||
}
|
||||
//Table is filtered
|
||||
if (o.validRowsIndex.length !== o.getRowsNb()) {
|
||||
var r = o.tbl.rows[nextRowIndex];
|
||||
if (r) {
|
||||
r.scrollIntoView(false);
|
||||
}
|
||||
if (cell) {
|
||||
if (cell.cellIndex === o.getCellsNb() - 1 && o.gridLayout) {
|
||||
o.tblCont.scrollLeft = 100000000;
|
||||
} else if (cell.cellIndex === 0 && o.gridLayout) {
|
||||
o.tblCont.scrollLeft = 0;
|
||||
} else {
|
||||
cell.scrollIntoView(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
//table is not filtered
|
||||
if (!o.validRowsIndex) {
|
||||
return;
|
||||
|
@ -1868,7 +1869,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
o._lastRowIndex = row.rowIndex;
|
||||
DoSelection(nextRowIndex);
|
||||
doSelect(nextRowIndex);
|
||||
} else {
|
||||
//If filtered row is valid, special calculation for
|
||||
//pgup/pgdown keys
|
||||
|
@ -1895,42 +1896,9 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
o._lastRowIndex = nextRowIndex;
|
||||
o._lastValidRowIndex = array.indexByValue(validIndexes, nextRowIndex);
|
||||
DoSelection(nextRowIndex);
|
||||
doSelect(nextRowIndex);
|
||||
}
|
||||
}
|
||||
|
||||
//Next valid filtered row needs to be selected
|
||||
var DoSelection = function DoSelection(nextRowIndex) {
|
||||
if (et.defaultSelection === "row") {
|
||||
et.Selection.SelectRowByIndex(nextRowIndex);
|
||||
} else {
|
||||
et.ClearSelections();
|
||||
var cellIndex = selectedElm.cellIndex,
|
||||
row = o.tbl.rows[nextRowIndex];
|
||||
if (et.defaultSelection === "both") {
|
||||
et.Selection.SelectRowByIndex(nextRowIndex);
|
||||
}
|
||||
if (row) {
|
||||
et.Selection.SelectCell(row.cells[cellIndex]);
|
||||
}
|
||||
}
|
||||
//Table is filtered
|
||||
if (o.validRowsIndex.length !== o.getRowsNb()) {
|
||||
var r = o.tbl.rows[nextRowIndex];
|
||||
if (r) {
|
||||
r.scrollIntoView(false);
|
||||
}
|
||||
if (cell) {
|
||||
if (cell.cellIndex === o.getCellsNb() - 1 && o.gridLayout) {
|
||||
o.tblCont.scrollLeft = 100000000;
|
||||
} else if (cell.cellIndex === 0 && o.gridLayout) {
|
||||
o.tblCont.scrollLeft = 0;
|
||||
} else {
|
||||
cell.scrollIntoView(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
//Page navigation has to be enforced whenever selected row is out of
|
||||
|
@ -1938,25 +1906,27 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
var onBeforeSelection = function onBeforeSelection(et, selectedElm, e) {
|
||||
var row = et.defaultSelection !== "row" ? selectedElm.parentNode : selectedElm;
|
||||
if (o.paging) {
|
||||
if (o.nbPages > 1) {
|
||||
if (o.Cpt.paging.nbPages > 1) {
|
||||
var paging = o.Cpt.paging;
|
||||
//page length is re-assigned in case it has changed
|
||||
et.nbRowsPerPage = o.pagingLength;
|
||||
et.nbRowsPerPage = paging.pagingLength;
|
||||
var validIndexes = o.validRowsIndex,
|
||||
validIdxLen = validIndexes.length,
|
||||
pagingEndRow = parseInt(o.startPagingRow, 10) + parseInt(o.pagingLength, 10);
|
||||
pagingEndRow = parseInt(paging.startPagingRow, 10) + parseInt(paging.pagingLength, 10);
|
||||
var rowIndex = row.rowIndex;
|
||||
if (rowIndex === validIndexes[validIdxLen - 1] && o.currentPageNb != o.nbPages) {
|
||||
// o.SetPage('last');
|
||||
o.Cpt.paging.setPage("last");
|
||||
} else if (rowIndex == validIndexes[0] && o.currentPageNb !== 1) {
|
||||
// o.SetPage('first');
|
||||
o.Cpt.paging.setPage("first");
|
||||
|
||||
if (rowIndex === validIndexes[validIdxLen - 1] && paging.currentPageNb !== paging.nbPages) {
|
||||
console.log("last");
|
||||
paging.setPage("last");
|
||||
} else if (rowIndex == validIndexes[0] && paging.currentPageNb !== 1) {
|
||||
console.log("first");
|
||||
paging.setPage("first");
|
||||
} else if (rowIndex > validIndexes[pagingEndRow - 1] && rowIndex < validIndexes[validIdxLen - 1]) {
|
||||
// o.SetPage('next');
|
||||
o.Cpt.paging.setPage("next");
|
||||
} else if (rowIndex < validIndexes[o.startPagingRow] && rowIndex > validIndexes[0]) {
|
||||
// o.SetPage('previous');
|
||||
o.Cpt.paging.setPage("previous");
|
||||
console.log("next");
|
||||
paging.setPage("next");
|
||||
} else if (rowIndex < validIndexes[paging.startPagingRow] && rowIndex > validIndexes[0]) {
|
||||
console.log("previous");
|
||||
paging.setPage("previous");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1965,12 +1935,13 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
//Selected row needs to be visible when paging is activated
|
||||
if (o.paging) {
|
||||
o.onAfterChangePage = function (tf, i) {
|
||||
var et = tf.ezEditTable;
|
||||
var row = et.Selection.GetActiveRow();
|
||||
var et = tf.Extensions.ezEditTable;
|
||||
var slc = et.Selection;
|
||||
var row = slc.GetActiveRow();
|
||||
if (row) {
|
||||
row.scrollIntoView(false);
|
||||
}
|
||||
var cell = et.Selection.GetActiveCell();
|
||||
var cell = slc.GetActiveCell();
|
||||
if (cell) {
|
||||
cell.scrollIntoView(false);
|
||||
}
|
||||
|
@ -2058,14 +2029,12 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
|
||||
try {
|
||||
o.ezEditTable = new EditTable(o.id, ezEditConfig, startRow);
|
||||
o.ezEditTable.Init();
|
||||
o.Extensions.ezEditTable = new EditTable(o.id, ezEditConfig, startRow);
|
||||
o.Extensions.ezEditTable.Init();
|
||||
} catch (e) {
|
||||
console.log(ezEditConfig.err);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
resetValues: {
|
||||
|
||||
|
@ -2141,9 +2110,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
|
||||
value: function resetValues() {
|
||||
this.EvtManager(this.Evt.name.resetvalues);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_resetValues: {
|
||||
|
||||
|
@ -2168,9 +2135,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
// this.ResetPage(this.pgNbCookie);
|
||||
this.Cpt.paging.resetPage(this.pgNbCookie);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
resetGridValues: {
|
||||
|
||||
|
@ -2261,16 +2226,12 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.Cpt.paging.setPagingInfo();
|
||||
}
|
||||
} //end if
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
filter: {
|
||||
value: function filter() {
|
||||
this.EvtManager(this.Evt.name.filter);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_filter: {
|
||||
/*====================================================
|
||||
|
@ -2634,9 +2595,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
if (this.onAfterFilter) {
|
||||
this.onAfterFilter.call(null, this);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
applyGridProps: {
|
||||
|
||||
|
@ -2675,9 +2634,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
if (this.popUpFilters) {
|
||||
this.Cpt.popupFilter.closeAll();
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getColValues: {
|
||||
|
||||
|
@ -2722,9 +2679,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
} //for i
|
||||
return colValues;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFilterValue: {
|
||||
|
||||
|
@ -2769,9 +2724,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
return fltValue;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFiltersValue: {
|
||||
|
||||
|
@ -2788,9 +2741,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
searchArgs.push(str.trim(str.matchCase(this.getFilterValue(i), this.matchCase)));
|
||||
}
|
||||
return searchArgs;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFilterId: {
|
||||
|
||||
|
@ -2805,9 +2756,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
return this.fltIds[i];
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFiltersByType: {
|
||||
|
||||
|
@ -2835,9 +2784,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
return arr;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFilterElement: {
|
||||
|
||||
|
@ -2851,9 +2798,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return null;
|
||||
}
|
||||
return dom.id(this.fltIds[index]);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getCellsNb: {
|
||||
|
||||
|
@ -2866,9 +2811,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
value: function getCellsNb(rowIndex) {
|
||||
var tr = !rowIndex ? this.tbl.rows[0] : this.tbl.rows[rowIndex];
|
||||
return tr.cells.length;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getRowsNb: {
|
||||
|
||||
|
@ -2887,9 +2830,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
s = 0;
|
||||
}
|
||||
return parseInt(ntrs - s, 10);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getCellData: {
|
||||
|
||||
|
@ -2910,9 +2851,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
} else {
|
||||
return dom.getText(cell);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getTableData: {
|
||||
|
||||
|
@ -2934,9 +2873,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.tblData.push(rowData);
|
||||
}
|
||||
return this.tblData;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFilteredData: {
|
||||
|
||||
|
@ -2973,9 +2910,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
filteredData.push(rData);
|
||||
}
|
||||
return filteredData;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFilteredDataCol: {
|
||||
|
||||
|
@ -3005,9 +2940,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
colData.push(c);
|
||||
}
|
||||
return colData;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getRowDisplay: {
|
||||
value: function getRowDisplay(row) {
|
||||
|
@ -3015,9 +2948,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
return row.style.display;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
validateRow: {
|
||||
|
||||
|
@ -3047,9 +2978,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
if (this.paging) {
|
||||
row.setAttribute("validRow", validFlag);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
validateAllRows: {
|
||||
|
||||
|
@ -3066,9 +2995,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
this.validateRow(k, true);
|
||||
this.validRowsIndex.push(k);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setFilterValue: {
|
||||
|
||||
|
@ -3141,9 +3068,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
setColWidths: {
|
||||
|
||||
|
@ -3174,9 +3099,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
enforceVisibility: {
|
||||
|
||||
|
@ -3194,16 +3117,12 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
clearFilters: {
|
||||
value: function clearFilters() {
|
||||
this.EvtManager(this.Evt.name.clear);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_clearFilters: {
|
||||
/*====================================================
|
||||
|
@ -3233,9 +3152,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
if (this.onAfterReset) {
|
||||
this.onAfterReset.call(null, this);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
clearActiveColumns: {
|
||||
|
||||
|
@ -3247,9 +3164,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
for (var i = 0; i < this.fltIds.length; i++) {
|
||||
dom.removeClass(this.getHeaderElement(i), this.activeColumnsCssClass);
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
refresh: {
|
||||
|
||||
|
@ -3281,9 +3196,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
//finally sort property is enabled again
|
||||
this.sort = true;
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
linkFilters: {
|
||||
|
||||
|
@ -3332,9 +3245,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
} // for i
|
||||
}
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_resetGrid: {
|
||||
|
||||
|
@ -3413,9 +3324,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
dom.addClass(this.tbl, this.prfxTf);
|
||||
}
|
||||
this._hasGrid = true;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
_containsStr: {
|
||||
|
||||
|
@ -3445,9 +3354,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
regexp = new RegExp(str.rgxEsc(arg), modifier);
|
||||
}
|
||||
return regexp.test(data);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
isImported: {
|
||||
value: function isImported(filePath, type) {
|
||||
|
@ -3465,9 +3372,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
return imported;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
includeFile: {
|
||||
value: function includeFile(fileId, filePath, callback, type) {
|
||||
|
@ -3500,9 +3405,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
throw new Error("TF script could not load:\n" + this.src);
|
||||
};
|
||||
head.appendChild(file);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
hasGrid: {
|
||||
|
||||
|
@ -3513,9 +3416,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
|
||||
value: function hasGrid() {
|
||||
return this._hasGrid;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFiltersId: {
|
||||
|
||||
|
@ -3529,9 +3430,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
return this.fltIds;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getValidRowsIndex: {
|
||||
|
||||
|
@ -3562,9 +3461,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
}
|
||||
}
|
||||
return this.validRowsIndex;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFiltersRowIndex: {
|
||||
|
||||
|
@ -3578,9 +3475,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
return this.filtersRowIndex;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getHeadersRowIndex: {
|
||||
|
||||
|
@ -3593,9 +3488,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
return this.headersRow;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getStartRowIndex: {
|
||||
|
||||
|
@ -3609,9 +3502,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
return this.refRow;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getLastRowIndex: {
|
||||
|
||||
|
@ -3624,9 +3515,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
return;
|
||||
}
|
||||
return this.nbRows - 1;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getHeaderElement: {
|
||||
|
||||
|
@ -3653,9 +3542,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
break;
|
||||
}
|
||||
return header;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
config: {
|
||||
|
||||
|
@ -3665,9 +3552,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
|
||||
value: function config() {
|
||||
return this.cfg;
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
},
|
||||
getFilterableRowsNb: {
|
||||
|
||||
|
@ -3678,9 +3563,7 @@ define(["exports", "module", "event", "dom", "string", "cookie", "types", "array
|
|||
|
||||
value: function getFilterableRowsNb() {
|
||||
return this.getRowsNb(false);
|
||||
},
|
||||
writable: true,
|
||||
configurable: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
define(["exports"], function (exports) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* Types utilities
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
var Types = {};
|
||||
|
||||
var UNDEFINED = void 0;
|
||||
|
|