Topic: How to edit DB from TableEditor?

Wladi79 priority asked 4 months ago


Good afternoon, I was able to display information through a database query through the TableEditor script. https://prnt.sc/BwMxwwgCEb3Q But I do not understand how to change the functionality of these buttons to Add / Delete / Edit rows in the database. https://prnt.sc/6TIpzTaGtwGS I could not find information specifically for TableEditor in the documentation. Can someone explain and show with a real example or piece of code?


Arkadiusz Cacko staff answered 4 months ago


Hi @Wladi79,

here is the API documentation for TableEditor standard version https://mdbootstrap.com/docs/standard/plugins/table-editor/#docsTabsAPI. There are some events that might be helpful for update database on specific action.

For example for adding row

tableEditorEl.addEventListener('add.mdb.tableEditor', function(e) {
   // Here you can send request to update your database if any row will be added 
}); 

Wladi79 priority commented 4 months ago

Could you write an example of adding and editing a row in database using this method? Because I don't really understand what you need to write here (



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Answered

Specification of the issue

  • User: Priority
  • Premium support: Yes
  • Technology: MDB CLI / MDB GO
  • MDB Version: 3.4.0
  • Device: Acer
  • Browser: Chrome
  • OS: Windows 10
  • Provided sample code: No
  • Provided link: Yes