0
votes

This is a simplified version of the problem I am facing right now.I have a List of employee objects with attributes Name, Salary and Designation. This information for about 10000 employees is displayed in three respective tables in a html page.
A remove button is provided against emp names on the Name table.

What should I do so when the remove button is pressed, it removes the employees displayed records from all three tables ?

Rendering all the tables again on every remove action by looping around the employee list is the obvious option, but is there a more efficient way to do this ?

1

1 Answers

0
votes

Just hide that particular row when user deletes it.

And as you updating the data in js then if the user refreshes the page the table will be formed without those values in it so there won't be anything to worry about.

If the name comes in the same order in other two rows then simply hide them or else you have to traverse and find the row and then hide. This will save time of forming the table again.