Closed skalimer0 closed 3 years ago
I tried to patch projects_controller and dashboard_async_blocks_controller to include my own Helper... i tried to call my own Helper in html.slim file.... I tried to patch DashboardsHelper by different way... but nothing worked.
On each test, the result is the same : "undefined method"
For information... I'm rails and ruby newbie... and i don't find solution for now.
Yes !!! I found, sorry for the issue.
I make a patch this all my methods and add this to the patch
ProjectsController.send :helper, MyPlugin::Patches::DashboardsHelperPatch
WelcomeController.send :helper, MyPlugin::Patches::DashboardsHelperPatch
DashboardAsyncBlocksController.send :helper, MyPlugin::Patches::DashboardsHelperPatch
Hi @skalimer0, I am glad you found your solution. Just for info:
Hello,
I want create new block in my plugin. I watch GitHosting example and i have something to execute. OK 👍
But, now, i must put my methods in dashboards_helper.rb of Additionals plugins to execute action like your feed's block with dashboard_feed_catcher or dashboard_feed_title.
How can i put my method in my own plugins ? how patch dashboards_helper ?
thanks and good job.