Skip to content

Commit 101f5a0

Browse files
authored
Merge pull request #87 from mrezagolestan/10.0
add exportRender docs
2 parents 554c576 + 39cd196 commit 101f5a0

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

‎html-builder-column-builder.md

+1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ $column = Column::make('id')
3131
->searchable(true)
3232
->orderable(true)
3333
->render('\'<div class="editor-active" >\' + (full[\'deleted_at\'] == null ? \'<i class="fas fa-check-circle client-is-active"></i>Active\' : \'<i class="fas fa-times-circle"></i>Inactive\') + \'</div>\';\'\'' )
34+
->exportRender(function($row,$data){return $data == 1 ? 'Active' : 'Inactive'})
3435
->footer('Id')
3536
->exportable(true)
3637
->printable(true);

‎html-builder-column.md

+4
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ Orderable attribute will toggle the `ordering` ability for the defined column. D
4747
### Render (Optional)
4848
Render attribute is a `js` script string that you can use to modify the way the column is being rendered via `javascript`.
4949

50+
### Export Render (Optional)
51+
Export Render attribute is a `php callback function` that you can use to modify the way the column is being rendered via `print` or `export (CSV/Excel/PDF)`.
52+
53+
5054
### Footer (Optional)
5155
Footer attribute will be as your `tables` column's `footer` content `<tfoot></tfoot>`.
5256

0 commit comments

Comments
 (0)