Whatever work was done in #1172970: provide a unified way to retrieve result entities seems to break the signup module.
With rc1 (before this patch), clicking on the signup tab (which goes to /node/%/signups/admin) works just fine.
With views rc3, it results in a WSOD.
The following code is the culprit in the file signup/views/handlers/signup_handler_field_signup_edit_link.inc
// Line 25-27
// $this->aliases is empty
$signup->sid = $values->{$this->aliases['sid']};
$signup->nid = $values->{$this->aliases['nid']};
$signup->uid = $values->{$this->aliases['uid']};
If you dpm($table_data);
(with the Devel module) on line 37 in views\handlers\views_handler_field_entity.inc
(which was added in this patch), you can see there is no entity type. Which in turn, probably, results in the WSOD mentioned above?
// Line 37-39
$table_data = views_fetch_data($this->table);
dpm($table_data);
$this->entity_type = $table_data['table']['entity type'];
For reference: this is the commit for issue #1172970.
Comment | File | Size | Author |
---|---|---|---|
#17 | signup-1358258-17.patch | 2.8 KB | jordojuice |
#13 | signup-1358258-13.patch | 1.68 KB | sgabe |
#4 | 1358258-4.patch | 821 bytes | benjf |
#2 | 1358258-2.patch | 885 bytes | arh1 |
#1 | 1358258.patch | 883 bytes | dawehner |
Comments
Comment #1
dawehnerLet's move to signup issue queue.
Here is a patch
Comment #2
arh1 CreditAttribution: arh1 commentedThanks, dereine!
It looks like your patch was missing a couple of semicolons. I re-rolled it.
Comment #3
kristiaanvandeneyndeThe above patch removes the fatal error, but the 'Edit signup' link that used to be in the table at node/%/signups/admin is missing now.
Comment #4
benjf CreditAttribution: benjf commentedHere is a slightly different patch, which seems to solve this problem for me (and the 'edit signup' links are back). I don't see anything too specific to my situation in there, but please test.
Comment #5
dawehner@benjf
I'm sorry but sadly your patch is wrong you have to use the interval aliases produced by views.
Comment #6
benjf CreditAttribution: benjf commentedhmmm, any suggestions on a solution? or why mine is "wrong" but seems to fix the problem?
The patch from #2 takes care of the fatal error, but I wonder if this piece of code is really "working"? (since it's supposed to generate the edit link and does not).
dpm($signup); results:
$signup->sid (Boolean) FALSE
$signup->uid (Boolean) FALSE
$signup->nid (NULL)
Comment #7
Anonymous (not verified) CreditAttribution: Anonymous commentedFollowing
Comment #8
cwyant CreditAttribution: cwyant commentedSubscribe. I get WSOD when adding "edit signup link" field.
Comment #9
sgabe CreditAttribution: sgabe commentedThe patch in #2 applies fine and eliminates the following error on node/[nid]/signups/admin path:
Fatal error: Cannot access empty property in [...]\www\sites\all\modules\signup\views\handlers\signup_handler_field_signup_edit_link.inc on line 24
Comment #10
kristiaanvandeneyndeThe patch in #1358258-2: Updating to Views 7.x-3.0-rc3 breaks Signup module applies fine, but breaks the functionality: generating an edit link.
(As mentioned in #1358258-3: Updating to Views 7.x-3.0-rc3 breaks Signup module and #1358258-4: Updating to Views 7.x-3.0-rc3 breaks Signup module)
Comment #11
sgabe CreditAttribution: sgabe commentedIMO this is good to go and that is another issue, see #1426028: Edit signup link is not displaying. This issue is about the fatal error which needs to be fixed ASAP.
Comment #12
sgabe CreditAttribution: sgabe commentedCommitted, thanks!
Comment #13
sgabe CreditAttribution: sgabe commentedIt seems this issue has been treated wrongly. I think what we need here is to add the node ID as an additional field to the constructor.
The attached patch reverts the patches in #1358258-2: Updating to Views 7.x-3.0-rc3 breaks Signup module and in #1426028-1: Edit signup link is not displaying and fixes the WSOD and the edit link.
Since I can't reproduce the empty aliases as the issue summary says, please test and report back.
Comment #14
kristiaanvandeneyndeI can confirm that 7.x-1.x-dev + this patch removes the WSOD -and- fixes the edit links.
Cross referencing because this seems to also fix #1428276: Double, threefold and so on entries in the admin interface
Comment #15
kristiaanvandeneyndeSetting to RTBC although my xref in #14 should be further tested.
Comment #16
jordojuice CreditAttribution: jordojuice commentedIndeed.
This patch is essentially the same as my patches in #1285536: SQL error when using Signup: Enabled/Disabled (Enabled) and #1399178: Ajax error when trying to use the sign up link in a view, and those worked for me. I'll mark those as dupes.
EDIT: Meant to mark #1447506: stdClass could not be converted to string in signup edit field as duplicate, but just merged changes from #1399178: Ajax error when trying to use the sign up link in a view below.
Comment #17
jordojuice CreditAttribution: jordojuice commentedNey. There's another issue in the signup_node_link handler. The nid field is never loaded. See #1399178: Ajax error when trying to use the sign up link in a view. Here's an updated patch with those changes.
Comment #18
kristiaanvandeneyndeI do not seem to have that issue, so can't verify whether the added changes fix it.
What are the steps to reproduce?
Comment #19
chaloum CreditAttribution: chaloum commentedjordojuice
I've tested it and the Ajax error no longer occurs but no link is displayed in the view (result not form)
for Signup current user form I wont save the other choices, Signup user list, Administer signups, signup settings, Form to sign up other users and Signup broadcast from.
I suspect the choice Signup current user form only display because its the default
and the check box "set view as return destination" doesn't save
Comment #20
jordojuice CreditAttribution: jordojuice commentedI reproduced it with the cloned 7.x-1.x branch - I just added a Node: Signup link to a node view. Views should display an error (did for us)
Comment #21
jordojuice CreditAttribution: jordojuice commentedHmm... needs work? I'll have to try to check it out tomorrow night if no one else gets to it before me.
It does seem there are still some issues...
Comment #22
sgabe CreditAttribution: sgabe commentedSince jordojuice's patch does not affect the original patch in #13 and we have a separate issue about the signup node link problem, lets deal with it there.
The patch in #13 is committed. The signup node link should be fixed in #1399178: Ajax error when trying to use the sign up link in a view.
Comment #24
flightrisk CreditAttribution: flightrisk commentedI've been bouncing around between a dozen threads that keep hitting dead ends where people say "this is a duplicate", but I can't find the fix. I am also getting this error:
Fatal error: Cannot access empty property in .../sites/all/views/handlers/signup_handler_field_signup_edit_link on line 23
Is there a fix for this?
I just did the automatic update to Signup 7.x-1.x-dev (2012-Feb-29)
and am using Views 7.x-3.x-dev (2011-Nov-27). Old version, but the latest dev releases seem to break a lot of modules.
The drupal update section points to the Feb 29 version, so I would have to manually try the latest dev release, but all the fixes seem to say Feb 29 *IS* the latest version. The commits log shows the last commit was Feb 29, yet the main page shows you can download a March 1 version. Maybe that is just the day it was uploaded and not the actual build date?
Comment #25
jordojuice CreditAttribution: jordojuice commentedI think I had a patch for that bug in another issue. I though @sgabe committed it but maybe I'm thinking of something else.
EDIT: Indeed, it looks like my patch in #17 covered the bug in signup_handler_field_signup_edit_link.inc. Did that part not get committed?
I'll check it out to see if it needs another patch or what.
Comment #26
jordojuice CreditAttribution: jordojuice commentedI just pulled the latest commits and the fix from #17 and other patches is in there. I'm gonna download the snapshot though.
Comment #27
jordojuice CreditAttribution: jordojuice commentedI also downloaded the March 1st snapshot and the fix is in there, so maybe this is still an issue for some reason, though I can't reproduce it.
However, note that with the bug fix line 23 is
global $user;
, whereas prior to the bug fix line 23 was the line with the bug, so it doesn't appear that the version you are using has the fix which is strange since I'm looking at the dev snapshot.signup_handler_field_signup_edit_link.inc
should have:...etc
Comment #28
flightrisk CreditAttribution: flightrisk commentedOk, this is crazy, I flushed the cache a few times yesterday but did not log out. Today's error is different:
Fatal error: Cannot access empty property in /home/mckenzie/public_html/sites/all/modules/signup/views/handlers/signup_handler_field_signup_edit_link.inc on line 27
If me text editor is correct the indicated line is where I am now getting an error trying to view the signups:
// Check access to edit this signup.
$signup = new stdClass();
$signup->sid = $values->{$this->aliases['sid']}; <------- line 27
$signup->nid = $values->{$this->aliases['nid']};
$signup->uid = $values->{$this->aliases['uid']};
Comment #29
-alex- CreditAttribution: -alex- commentedI face the same error