How can I add the data in a row to another table by clicking on the row.
How can I add the data in a row to another table by clicking on the row.

I'm trying to make a medical prescription creating web app using npm and angular.
I want to search the drug from the database and when you click on it, the name of the drug should go to a table below.
And it should be repeated until I press a button.
I have finished designing the drug data table using angular-datatables.
I have no idea how to do this function. please help.
This discussion has been closed.
Answers
You can use
row().data()
to get the data of the clicked row. Not sure how this works with Angular but this example shows how to click a row and get the clicked data. You will then userow.add()
to add the row to the second table.Kevin