Problem/Motivation

The current Report a Problem block allows us to reference a webform, which then gets linked to by the Report a Problem block. In order to keep inline with Canada.ca, we need to have the webform display inline, then show a success message in place of the webform.

Proposed resolution

Add a checkbox to the Report a Problem block that allows the user to enable an inline webform.

Remaining tasks

  • Add the ability for user to enter an external URL where the form data will be sent.

User interface changes

  • Checkbox on the Report a Problem block form

Notes

  • There are two patch files, one for the WXT profile (wxt_ext_webform module) and the other for the wxt_bootstrap theme. If there is a preferred method for patching two different components like this please let me know.
  • I added a config file for the Report a Problem webform, same as available on Canada.ca

Comments

smulvih2 created an issue. See original summary.

smulvih2’s picture

sylus’s picture

This on first glance looks great to me. I will try to either try it out myself this upcoming week or get someone else to and then will commit!

smulvih2’s picture

Status: Active » Needs review
smulvih2’s picture

Fixed an issue from previous patch files. Tested on new install of 3.014 and works as expected. The patch shouldn't change anything unless admin selects the inline webform option on block config form.

smulvih2’s picture

Change in composer.json to apply patches:

"patches": {
  "drupalwxt/wxt": {
    "Enable inline webform for Report a Problem block": "https://www.drupal.org/files/issues/2020-10-19/enable-inline-webform-for-report-a-problem-block-3162505-5.patch"
  },
 "drupal/wxt_bootstrap": {
    "Enable inline webform for Report a Problem block": "https://www.drupal.org/files/issues/2020-10-19/template-files-for-inline-webform-3162505-5.patch"
  }
},
joseph.olstad’s picture

Version: 8.x-3.013 » 8.x-3.014
sylus’s picture

Status: Needs review » Fixed

Committed and attributed :D

Thanks so much :D

  • sylus committed 1a107bb on 8.x-3.x authored by smulvih2
    Issue #3162505 by smulvih2: Enable inline webform for Report a Problem...
  • sylus committed 7b0004e on 8.x-3.x
    Issue #3162505 by smulvih2: Enable inline webform for Report a Problem...

  • 6319035 committed on 8.x-3.x
    Issue #3162505 by natew: Remove search_api_solr and facets. Updated...

Status: Fixed » Closed (fixed)

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