I had this working perfectly, C1 is individual, C2 is organization, and they have a relationship of employee to employer. c1 can edit 2, because they are a current employee - had this working on the webform.

then, after some staff added some civicrm field components and/or changed wordings of fields and/or unknown stuff, it stopped working. it prefills C1 data, but not C2.

I made a new webform and tested it, and it works for C1 and C2 with the same settings.

is there any way to debug this, could a field be "throwing" off my c2 auto-fill?

Comments

zkrebs’s picture

Title: Webform has ceased to update C2 data » Automatically save as draft between pages breaks contact 2 webform autofill
Status: Active » Needs review

I found the problem - when I disabled this functionality, my form started autofilling just fine.

Is that the expected behavior, or a weird bug?

colemanw’s picture

Is the page break between the contacts?

zkrebs’s picture

Yes it is, in this case.

colemanw’s picture

That makes sense actually, because during save draft the contact ids get stored by this module. Because current employer is not actually set but only "sort of" set this would mess it up. In other words, saving the draft saves the empolyer id as 0 ('unknown') whereas before it was not set to anything and so would do the lookup.

zkrebs’s picture

Ah..well, maybe we could just add this to documentation somewhere that its not currently supported as a feature? I don't need the auto-save, just thought it was cool.

Or I guess we could fix that?

colemanw’s picture

The next version of this module will have an entirely different way of matching and autofilling contacts, so this should be moot.

colemanw’s picture

Version: 6.x-2.4 » 7.x-2.x-dev
Category: support » bug
Status: Needs review » Closed (won't fix)

Marking as won't fix for 2.x branch. Should work fine in 3.x