You are here

function data_entity_permission in Data 7

Implements hook_permission().

File

data_entity/data_entity.module, line 194
data_entity.module TODO: Enter file description here.

Code

function data_entity_permission() {
  $tables = data_entity_get_entity_tables();
  $permissions = array();
  foreach ($tables as $table_name => $table) {
    $permissions['edit data in table ' . $table_name] = array(
      'title' => t('Edit data in the %table_name table', array(
        '%table_name' => $table->title,
      )),
    );
  }
  return $permissions;
}