How to put/insert/update/modify bonus to all employees in the table based on input amount
How to put/insert/update/modify bonus to all employees in the table based on input amount
![stancaballero](https://secure.gravatar.com/avatar/dc4fb6e0ff8c57cde71ed26c626f4052/?default=https%3A%2F%2Fvanillicon.com%2Fdc4fb6e0ff8c57cde71ed26c626f4052_200.png&rating=g&size=120)
Link to test case:
Debugger code (debug.datatables.net):
Error messages shown:
Description of problem:
Answers
Can you provide more information, please? Such as is this just a display issue, where you want a DataTables column that's not in the database to show a value, or are you looking to do the calculation and send that data to the server when the field is updated?
Colin
I want to share the total incentives based on their percentage per employee amount
I want to do a calculation based on percentage and total amount and send back to the server and also update the display table.
I'm not fully getting it either I'm afraid. Do you have an input element somewhere (not shown in your screenshot) where you enter a value and then you perform some calculations when you then want to edit all rows with and submit that to the server?
If so, you want to use the Editor multi-row API. Trigger an edit on all rows (
edit()
with a suitable selector for the rows you want) and then iterate over the rows using the Editor multi-row API to edit the values. Finallysubmit()
to send to the server.Allan