Created a custom module - delete method is causing error

Hi All,

I created a custom module. The Add and Edit is working fine. I’m using the datasets to write to the table. The problem that I’m having is when an element from the module is deleted it doesn’t remove the dataset. When I use delete method - I get the follow error message:

Fatal error : Cannot override final method Xibo\Widget\ModuleWidget::delete() in /home/subdom/public_html/custom/EasyModule/EasyModule.php on line 40

Any suggestion as how I can use the delete function correctly?

I don’t think you want to try and overwrite the delete() in ModuleWidget

That being said, I’m not sure what your widget does or what should happen on delete, since I didn’t see even a snippet of your code, as such I can only guess.

Hi Peter,

We have created a module that creates datatable upon creation. We need to delete the datatable upon deletion of the module widget or region.

Need help to do the same by adding extra code to delete method.

Kindly help.

Any help is appreciated.