Excel Export callback
Excel Export callback
belu
Posts: 38Questions: 14Answers: 0
Hi there,
does something like an export to excel callback exist?
I have a column 'marked_as_exported' and want every exported row to be marked as exported automatically. So ist there a 'callback', where I set the 'marked_as_exported' - value to 1 after a successful export?
Thanks in advance!
This discussion has been closed.
Answers
Yes, you can use a
row-selector
as part of theexportOptions
object for theexcelHtml5
button type.The row selector can be given as a function and is executed once for each row, you return a boolean to indicate if you want the row to be included or not.
Allan
Does the row-selector show only rows that are selected by clicking on them, or every row that is shown by the actual filter?
I would like to export e.g. every entry that was made in february - so I would filter for february (several thousand entries) and export them and make them marked as exported. If I would have to select (mark) them separately, this is no option, because too much work...
Hi @belu ,
Your function will be passed all rows. As Allan said, you can then decide whether to include or exclude them,
Cheers,
Colin