Révision 136a805a
Ajouté par Assos Assos il y a plus de 7 ans
drupal7/sites/all/modules/forum_access/forum_access.admin.inc | ||
---|---|---|
62 | 62 |
); |
63 | 63 |
$form['forum_access']['update_choice'] = array( |
64 | 64 |
'#type' => 'radios', |
65 |
'#title' => 'Update the permissions',
|
|
65 |
'#title' => t('Update the permissions'),
|
|
66 | 66 |
'#description' => t('<em>If</em> you make any node access changes, then each node in this forum needs to be updated. Hover over the radiobuttons for details.'), |
67 | 67 |
'#options' => NULL, |
68 | 68 |
0 => array( |
... | ... | |
403 | 403 |
$ca_priority = content_access_get_settings('priority', 'forum'); |
404 | 404 |
$is_conflict = ($ca_priority >= $fa_priority && !empty($ca_interferes) || $ca_priority > $fa_priority); |
405 | 405 |
$variables += array( |
406 |
'!link' => l(t('@Content_Access configuration for the %content_type type', $variables), 'admin/content/node-type/forum/access', array('html' => TRUE)),
|
|
406 |
'!link' => l(t('@Content_Access configuration for the %content_type type', $variables), 'admin/structure/types/manage/forum/access', array('html' => TRUE)),
|
|
407 | 407 |
'%Advanced' => $tr('Advanced'), |
408 | 408 |
); |
409 | 409 |
$specifically = ($ca_priority == $fa_priority ? t('Specifically, any grants given by !Content_Access cannot be taken back by !Forum_Access.', $variables) : ''); |
... | ... | |
795 | 795 |
* Add warnings on Content Access admin forms where CA wants |
796 | 796 |
* to control the same content types as we do. |
797 | 797 |
*/ |
798 |
function _forum_access_content_access_admin_form() { |
|
799 |
return; |
|
800 |
//TODO Fix when CA is released! |
|
798 |
function _forum_access_content_access_admin_form($bundle) { |
|
801 | 799 |
$tr = 't'; |
802 | 800 |
$l = 'l'; |
803 | 801 |
$variables = array( |
... | ... | |
809 | 807 |
'%Advanced' => $tr('Advanced'), |
810 | 808 |
); |
811 | 809 |
$dsm = 'drupal_set_message'; |
812 |
if (arg(3) == 'forum') {
|
|
810 |
if ($bundle->type == 'forum') {
|
|
813 | 811 |
$dsm(t('Note: In Drupal, access can only be granted, not taken away. Whatever access you grant here will not be reflected in the !Forum_Access_link settings, but !Forum_Access can only allow <i>more</i> access, not less.', $variables) |
814 | 812 |
. '<br /><span class="error">' . t('Specifically, any rights granted to the %anonymous_user and/or the %authenticated_user will <b>override</b> the settings of !Forum_Access!', $variables) . '</span>' |
815 | 813 |
. '<br />' . t('To avoid conflicts with !Forum_Access settings, you may want to lower the priority of !Content_Access (under %Advanced below) below the priority of !Forum_Access for the content types that you want to be controlled by !Forum_Access.', $variables), 'warning'); |
816 | 814 |
} |
817 | 815 |
else { |
818 |
$vid = _forum_access_get_vid(); |
|
819 |
$vocabulary = taxonomy_vocabulary_load($vid); |
|
820 |
if (isset($vocabulary->nodes[arg(3)])) { |
|
816 |
$instances = field_info_instances('node', $bundle->type); |
|
817 |
if (isset($instances['taxonomy_forums'])) { |
|
821 | 818 |
$dsm(t('Note: Nodes of this content type can be put inside forums, where access to them will also be controlled by !Forum_Access.<br />In Drupal, access can only be granted, not taken away. Whatever access you grant here will not be reflected on the !Forum_Access_link settings, and vice versa, but any node access module can only allow <i>more</i> access, not less.', $variables), 'warning'); |
822 | 819 |
} |
823 | 820 |
} |
Formats disponibles : Unified diff
Weekly update of contrib modules