Posted by stevenprice1974 on June 9, 2010 at 12:54pm
Hi I am using the Views Bulk Operations module. But I need to include an action to allow the user to download content nodes as an RTF.
I tried to implement my own 'downloads module' with the hook_node_operations like this
/**
* Implementation of hook_node_operations().
*/
function downloads_node_operations() {
$operations = array(
'downloads' => array(
'label' => 'DOWNLOAD',
' callback' => 'mymodule_download_function',
),
);
return $operations;
}
/**
* Valid permissions for this module
* @return array An array of valid permissions for the downloads module
*/
function downloads_perm() {
return array('access downloads content');
}This option did show in the admin drop-down but was not available in selected operations in my view. Why does this not appear, any ideas (I am logged in as admin user1)?
Thanks
Steven
Comments
Any luck figuring it out?
I actually declared a new action with hook_action_info, then created the action with hook_action. Per the VBO documentation, it should register in VBO, but it doesn't. It does show up as an action in my list of actions, however...
I got the same issue
I got the same issue
So, dont know if it is gonna
So, dont know if it is gonna help, but i solved my problem...
I am creating the actions trough the implementation of hook_action_info. On this module, the .install file, I called hook_uninstall in my hook_install method to make things clean, but that was messing with the behaviour of my module, and the actions display.
I don't see where it is related, but this is how i solved it. Maybe It'll help