Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
DBAController event
Bleistivt
Moderator
Hi everyone,
I have a plugin which stores counts in various tables and I would like to add the option to recalculate these with dba/counts.
How do I hook into that action? Is this even possible for plugins? I couldn't find a plugin, that does that yet.
Thanks
My themes: pure | minusbaseline - My plugins: CSSedit | HTMLedit | InfiniteScroll | BirthdayModule | [all] - PM me about customizations
VanillaSkins.com - Plugins, Themes and Graphics for Vanillaforums OS
0
Comments
That's actually how even the default counts are added - by a hook in the Vanilla application. See
DbaController_CountJobs_Handler
inapplications/vanilla/settings/class.hooks.php
.I wrote a patch for the tagging plugin that does this:
https://github.com/hgtonight/Garden/commit/e6d0ff83efdc7b236241e0486c2825b1d413d5f3
The key is you have to have a method named
Counts
on the appropriate model for the hook to work.Search first
Check out the Documentation! We are always looking for new content and pull requests.
Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.
Thats exactly what I was looking for!
I had already prepared a Query but then I saw
DBAModel::GetCountSQL
which made it even easier.My themes: pure | minusbaseline - My plugins: CSSedit | HTMLedit | InfiniteScroll | BirthdayModule | [all] - PM me about customizations
VanillaSkins.com - Plugins, Themes and Graphics for Vanillaforums OS