Topic: Table editor - enable/disable

De Berardinis free asked 3 years ago


I bought a pro license to be able to use the datatable editor plugin, with JQuery MDB 4. I have seen the examples available on the site (https://mdbootstrap.com/docs/b4/jquery/plugins/table-editor/).

What I would like to use is the Content Editor. All the examples have keys to manage the activation / deactivation of the editor functions. This step is essential, that is, could I create a table implicitly enabled for modification? Otherwise, when clicking on the button to enable the modification, which method should I call to make the table editable?

Thank you all


De Berardinis free answered 3 years ago


I feel as stupid as it is. I created this simple snippet

https://mdbootstrap.com/snippets/jquery/de-berardinis/3033902

for an editable datatable but it doesn't work, neither in view nor in modification.

Thank you.


Marcin Luczak staff commented 3 years ago

You've added an external jquery library that corrupts your snippet. Please check my fixed snippet with your data: https://mdbootstrap.com/snippets/jquery/marcin-luczak/3035886


Marcin Luczak staff answered 3 years ago


Hi,

There is no method to make the table editable. However, if you would like to have a table with a content editor that is by default enabled for modification you could try to trigger a click event on a toggle button after your table initialization. My other idea is you can remove .disabled-table class from tbody element of your DataTable that has content editor. This should work for enabling your content to be edited but you will still have to manually remove disabled attribute from the search element.

I hope this will help you with your problem.

Keep coding, Marcin



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

  • ForumUser: Free
  • Premium support: No
  • Technology: MDB jQuery
  • MDB Version: 4.19.2
  • Device: PC
  • Browser: Chrome
  • OS: Win10
  • Provided sample code: No
  • Provided link: Yes