1
0
Fork 0
mirror of https://github.com/koalyptus/TableFilter.git synced 2024-06-01 21:42:20 +02:00

Updated 1.02 Main features (markdown)

koalyptus 2016-06-04 17:36:09 +10:00
parent d3821fc900
commit 70458f05d4

@ -312,10 +312,9 @@
</tr>
</tbody>
</table>
## Events
<p>
Assuming `TableFilter` is already instanciated:
Assuming <code>TableFilter</code> is already instanciated:
</p>
<pre>
var tf = new TableFilter('my-table-id');
@ -331,13 +330,30 @@ var tf = new TableFilter('my-table-id');
</thead>
<tbody>
<tr>
<th>before-filter-init</th>
<td>Event emitted just before a filter is generated during TableFilter initialization</td>
<th>initialized</th>
<td>Event emitted just after <code>TableFilter</code> initialization</td>
<td>
Subscribers receives the following parameter:
Subscribers receives the following parameters:
<ul>
<li>tf - current TableFilter instance</li>
<li>colIndex - current column index</li>
<li><code>tf</code> - current TableFilter instance</li>
</ul>
</td>
<td>
<pre>
tf.emitter.on(['initialized'], function(tf){
console.log(tf);
});
</pre>
</td>
</tr>
<tr>
<th>before-filter-init</th>
<td>Event emitted just before a filter is generated during <code>TableFilter</code> initialization</td>
<td>
Subscribers receives the following parameters:
<ul>
<li><code>tf</code> - current TableFilter instance</li>
<li><code>colIndex</code> - current column index</li>
</ul>
</td>
<td>
@ -348,5 +364,23 @@ var tf = new TableFilter('my-table-id');
</pre>
</td>
</tr>
<tr>
<th>after-filter-init</th>
<td>Event emitted just after a filter is generated during <code>TableFilter</code> initialization</td>
<td>
Subscribers receives the following parameters:
<ul>
<li><code>tf</code> - current TableFilter instance</li>
<li><code>colIndex</code> - current column index</li>
</ul>
</td>
<td>
<pre>
tf.emitter.on(['after-filter-init'], function(tf, colIndex){
console.log(tf, colIndex);
});
</pre>
</td>
</tr>
</tbody>
</table>
</table>