I am making a check-in list using views, but it seems Editablefields and Entity Registrations does not really play well together. The idea is take all the registrations for an event, display them in a view, use editablefields to display a checkbox outside each registration. Check the attendees in using a connected iPad.

But I get some errors when I try to compine the two modules. Using a standard article it works fine, but in combination with Entity Registrations, I get an error. I am not sure if the problem is with this module or the Entity Registrations module.

Does anyone have some experience in with these two module together ?

The error is:

Notice: Undefined index: module in editablefields_fallback_formatter() (line 201 of /localpath/sites/all/modules/editablefields/editablefields.module).

Best,
Jens

Comments

SlashCrew’s picture

The Display variable in editablefields_fallback_formatter($entity_type, $entity, $field, $instance, $langcode, $items, $display) contains:

array (
  'label' => 'above',
  'type' => 'editable',
  'weight' => '0',
  'settings' => 
  array (
    'fallback_format' => NULL,
    'fallback_settings' => 
    array (
    ),
    'click_to_edit' => false,
    'click_to_edit_style' => 'button',
    'empty_text' => '',
  ),
  'module' => 'editablefields',
)
SlashCrew’s picture

entity_access('update', $entity_type, $entity) in function editablefields_field_formatter_view($entity_type, $entity, $field, $instance, $langcode, &$items, $display) returns null, this seems to be the problem.

If I change

if (!entity_access('update', $entity_type, $entity) || !field_access('edit', $field, $entity_type, $entity)) {

to

if (!entity_access('update', $entity_type, $entity) && !field_access('edit', $field, $entity_type, $entity)) {

It's working

SlashCrew’s picture

The problem is here:

entity_access('update', $entity_type, $entity)

returns null

SlashCrew’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.