mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/15951] Add core.mcp_delete_topic_modify_hidden_fields
Allow modification of the hidden fields when deleting topics This lets you control the permissions for permanently deleting topics Template variables can also be modified at this point PHPBB3-15951
This commit is contained in:
parent
f4a1d4ef02
commit
663e611fae
1 changed files with 22 additions and 0 deletions
|
@ -1024,6 +1024,28 @@ function mcp_delete_topic($topic_ids, $is_soft = false, $soft_delete_reason = ''
|
||||||
$s_hidden_fields['delete_permanent'] = '1';
|
$s_hidden_fields['delete_permanent'] = '1';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This event allows you to modify the hidden form fields when deleting topics
|
||||||
|
*
|
||||||
|
* @event core.mcp_delete_topic_modify_hidden_fields
|
||||||
|
* @var string l_confirm The mode we are deleting in (DELETE_TOPIC(S), DELETE_TOPIC(S)_PERMANENTLY)
|
||||||
|
* @var array s_hidden_fields The array holding the hidden form fields
|
||||||
|
* @var array topic_ids The array of topic IDs to be deleted
|
||||||
|
* @var int forum_id The current forum ID
|
||||||
|
* @var bool only_softdeleted If the topic_ids are all soft deleted, this is true
|
||||||
|
* @var bool only_shadow If the topic_ids are all shadow topics, this is true
|
||||||
|
* @since 3.2.6-RC1
|
||||||
|
*/
|
||||||
|
$vars = array(
|
||||||
|
'l_confirm',
|
||||||
|
's_hidden_fields',
|
||||||
|
'topic_ids',
|
||||||
|
'forum_id',
|
||||||
|
'only_softdeleted',
|
||||||
|
'only_shadow',
|
||||||
|
);
|
||||||
|
extract($phpbb_dispatcher->trigger_event('core.mcp_delete_topic_modify_hidden_fields', compact($vars)));
|
||||||
|
|
||||||
confirm_box(false, $l_confirm, build_hidden_fields($s_hidden_fields), 'confirm_delete_body.html');
|
confirm_box(false, $l_confirm, build_hidden_fields($s_hidden_fields), 'confirm_delete_body.html');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue