Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi there,
Sometimes I wish I could temporary disable recipients rather than deleting them from the /webform/emails section. I know it’s possible to uncheck recipients in the result section.
Moreover cloning recipients settings including Mail Header details, From Address, From Name and the E-Mail Template customization would be great.
Comment | File | Size | Author |
---|---|---|---|
#13 | webform-disable_emails-interdiff-9-13.do-not-test.diff | 8.08 KB | DanChadwick |
#13 | webform-disable_emails-2485371-13.patch | 9.55 KB | DanChadwick |
#9 | ability_to_disable-2485371-9.patch | 6.87 KB | sumitmadan |
#5 | ability_to_disable-2485371-5.patch | 7.02 KB | sumitmadan |
#2 | ability_to_disable-2485371-2.patch | 3.54 KB | sumitmadan |
Comments
Comment #1
DanChadwick CreditAttribution: DanChadwick commentedI understand the desire to disable, but webform already offers cloning for e-mail and components. Look to the right of the e-mail list.
Editing the title accordingly.
Comment #2
sumitmadan CreditAttribution: sumitmadan at QED42 commentedSubmitting a patch for this feature.
Also I would love to be the co-maintainer of the module. :)
Comment #3
DanChadwick CreditAttribution: DanChadwick commentedThank for the patch!!
I think the best name for this would be status, to mirror users and nodes. The default would be 1, reversing the sense of disabled in the patch.
Also, I think this needs to be exposed in the list of emails as checkboxes, in the same way that required is for components. Otherwise it would be difficult to set these and to know which are active. I see end user confusion otherwise.
Comment #4
sumitmadan CreditAttribution: sumitmadan commentedComment #5
sumitmadan CreditAttribution: sumitmadan commentedComment #6
DanChadwick CreditAttribution: DanChadwick commentedI didn't try the patch, but I read it.
Needs a condition on nid too. eid's are specific to a particular node. Each node can have an eid of 1.
What is the purpose of this ternary expression? Seems like this should just be
$email['status']
Should be 1, lest the email not be initially enabled.
Description could be better. Maybe "Whether this email is enabled."
Default should be 1.
Use the new description and default. Then you won't need the db_update().
Comment #7
DanChadwick CreditAttribution: DanChadwick commentedComment #8
sumitmadan CreditAttribution: sumitmadan commentedComment #9
sumitmadan CreditAttribution: sumitmadan at QED42 commentedThanks. I have updated the code. :)
Comment #10
sumitmadan CreditAttribution: sumitmadan commentedComment #11
DanChadwick CreditAttribution: DanChadwick commentedI will (eventually) work on this. There were a few minor issues with #9, but more importantly, I don't love the UI. We already have an interface where you select e-mail to be RE-sent with a checkbox in column 1. The Save button only applies to this column and the add button only applies to the last row.
I may move the Save button to the checkbox column and put the add button in-line after the radio buttons. I'm not sure that webform has existing in-line markup for this though.
I'm also not totally happy that this feature has so much UI, but I don't see a good way around it.
Comment #12
sumitmadan CreditAttribution: sumitmadan commentedWell, I have followed the same UI as on components add form. But I'll be happy to see improved UI and then it can be implemented on components form too.
Just a thought.
Comment #13
DanChadwick CreditAttribution: DanChadwick commented@sumitmadan -- thank you for all your work on this issue.
Changes I made:
Committed to 7.x-4.x.
Comment #15
DanChadwick CreditAttribution: DanChadwick commentedComment #16
fenstratPorted #13, committed and pushed to 8.x-4.x. Thanks!