You are here

function access_by_ref_admin in Access by Reference 7

1 string reference to 'access_by_ref_admin'
access_by_ref_menu in ./access_by_ref.module

File

./access_by_ref.module, line 129

Code

function access_by_ref_admin() {
  $uvars = explode("\n", variable_get('access_by_ref_user_field', ''));
  $form = array();
  $form['access_by_ref_referenced'] = array(
    '#type' => 'textarea',
    '#title' => t('<b>"Transitive": </b>Grant Access to Editor of Referenced Node'),
    '#default_value' => variable_get('access_by_ref_referenced', ''),
    '#rows' => 3,
    '#cols' => 30,
    '#description' => t("Enter one per line in format content_type|field_name. \n\tA user who may edit the node referenced in that field may edit the node being looked at."),
    '#required' => FALSE,
  );
  $form['access_by_ref_user_field'] = array(
    '#type' => 'textarea',
    '#title' => t('<b>"Shared": </b>Grant Access to User with Shared Profile Value'),
    '#default_value' => variable_get('access_by_ref_user_field', ''),
    '#rows' => 3,
    '#cols' => 30,
    '#description' => t("Enter one per line in format content_type|field_name. \n\tA user with the same value in their profile for this field may edit the node being looked at."),
    '#required' => FALSE,
  );
  $form['access_by_ref_user_reference_field'] = array(
    '#type' => 'textarea',
    '#title' => t('<b>"User": </b>Grant Access to User referenced in this field'),
    '#default_value' => variable_get('access_by_ref_user_reference_field', ''),
    '#rows' => 3,
    '#cols' => 30,
    '#description' => t("Enter one per line in format content_type|field_name. \n\tA user referenced in this field may edit the node being looked at."),
    '#required' => FALSE,
  );
  $form['access_by_ref_user_email'] = array(
    '#type' => 'textarea',
    '#title' => t('<b>"Email": </b>Grant Access to a User with the email address in this field'),
    '#default_value' => variable_get('access_by_ref_user_email', ''),
    '#rows' => 3,
    '#cols' => 30,
    '#description' => t("Enter one per line in format content_type|field_name. \n\tA user having the email address referenced in this field may edit the node being looked at."),
    '#required' => FALSE,
  );
  return system_settings_form($form);
}