backdrop-contrib / examples

Examples for Developers
GNU General Public License v2.0
7 stars 9 forks source link

Fix entity class in entity_example #15

Closed herbdool closed 2 years ago

herbdool commented 2 years ago

I was using entity_example for testing something in core and found that the methods on the class aren't returning useful stuff. Needs some fixing. I've got a PR coming.

herbdool commented 2 years ago

@docwilmot I've added a PR for this.

herbdool commented 2 years ago

@argiepiano I added a PR to get it working. (I had tested by changing the page callback from entity_example_basic_view to entity_view).

Perhaps @docwilmot would be interested in you, @argiepiano, and/or me also maintaining this module?

docwilmot commented 2 years ago

I would be happy for the additional maintainers, yes. This module I believed is also parsed by API module on docs.backdropcms.org and its functions also appear in the lists of core functions on the API site. So really we should be keeping this continuously up to date. Been woefully neglected these years.

argiepiano commented 2 years ago

I'd be happy to help maintain. I created a custom entity module based entity_example called panettone that contains two branches: one using the EntityDatabaseStorageController and another that extends that controller and provides its own theme, preprocessing and templates. It's in my github at the moment - I don't intend to create an official module with it; it is just for testing.

https://github.com/argiepiano/panettone

I see that @herbdool submitted a PR (merged) with some changes to test the new entity_view functionality. I will submit a PR with additional modifications that were needed to adapt the example entity module to fully work with the current controller.