5

I have a webform set up as a Contact page that creates a civi contact and activity and assigns it. I have a scheduled reminder send out a "Thanks for contacting us...we'll get back to you asap..." email after the activity is created. There's an issue where Webform doesn't allow the Communication Format to be set and we use that in how we format our Email Greeting. We have Formal communication preference set as default option in Civi but when Webform creates the contact for some reason that default doesn't get set and so when the contact record is viewed there's no communication format at all.

What are the options to fix this? Can Webform be updated to be able to set the communication format?

2
  • What CiviCRM version are you using? Aug 7, 2017 at 3:58
  • I'm running Civicrm 4.7.21
    – frTommy
    Aug 7, 2017 at 4:03

2 Answers 2

1

If Communication Style is set to Formal -> is_default on:

civicrm/admin/options/communication_style?reset=1

Then that's what shows in the Contact record (see below); Are you saying that webform_civicrm removes this default for existing contacts; or that new contacts have their is_default set wrong?

enter image description here

Added: I've confirmed that creating a New Contact with the API leaves the Communication Style 'blank'. However one would expect it should be setting it to the default value that is specified in the Administer settings.

So it's an API issue - we could fix this in webform_civicrm - by explicitly passing on a value for Parameter Communication Style - but I think it should be fixed in CiviCRM Core itself.

6
  • Yes, is set to default. When webform creates a contact it doesn't set anything and the default doesn't get set either. So if you view a newly created contact by webform none of the radio buttons are selected. Webform doesn't remove it on an existing contact.
    – frTommy
    Aug 7, 2017 at 17:51
  • Webform uses the API to create contacts; let me run a check Aug 7, 2017 at 17:53
  • Yeah sounds like fixing the actual issue would be better. So do I need to log an issue in Jira for the API issue to get fixed? Or will you since you might be better able to describe the issue with the API?
    – frTommy
    Aug 7, 2017 at 18:56
  • Why don't you log the issue - and then I'll jump in to mark it verified. Aug 7, 2017 at 20:41
  • Let me know when you've had a chance to do that. Aug 7, 2017 at 20:48
0

This looks like a bug in core. Either an incorrect blank is set as a parameter from API layer before calling lower down, or the lower level BAO is not setting default correctly. Fr Tommy, could you create an issue in JIRA on this, including link to here, then assign the issue to Josh and mark as PIQ. My guess is that it would cost about $125 - $250 to fix the bug and add a test to ensure the API works properly on this.

1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.