Home › Forums › Classic DFFS › Stop scheduled email not working
Tagged: email
- This topic has 2 replies, 2 voices, and was last updated 4 years, 4 months ago by Amal Vellappillil.
-
AuthorPosts
-
-
June 9, 2020 at 18:06 #30517
Hi,
I am running into an issue where I want a rule to stop a pending (scheduled) email from a rule. I did specify “stop:emailtemplateid”. But for some reason the “Stop” value does not get updated in DFFS_Email list.
Here are my findings.
– DFFS gets all the pending emails for list item when processEmailTemplate function is called.
– getPendingEmails function builds up a query to retrieve pending emails from DFFS_Email list.
– However, the “Title” it constructs for the list item is different than the entry in DFFS_Email list.
– See attachments to see the discrepancy. “Item_edi_view” screenshot has the developer window open with the query constructed just like getPendingEmails function.
– Looks like DFFSID associated with the item and DFFS_Email entry is not what you get in edit form when queried with spjs.dffs.data._DFFSID (which is what is used to construct the query).
– Also the spjs.dffs.data._DFFSID is a different value every time edit form is refreshed. I dont know if this is by design.
– Because of this discrepancy, no emails are found as pending emails for the list item and nothing gets flagged to be stopped.Can you please look into this issue and let me know how to get this issue resolved?
Thank you,
Amal VellappillilAttachments:
-
June 9, 2020 at 20:21 #30526
Thanks for finding this bug – it was caused by an error in an internal function – and as you have documented it affects the stop:emailtemplate function.
I’ll include this fix in the next release, but you can fix it by adding this to your custom js for now:
spjs.dffs.writeDFFSID = function () { if (spjs.dffs.fieldData._DFFSID !== undefined) { var inp = jQspjs("#dffs__DFFSID input"); if (inp.length === 0) { setTimeout(function () { spjs.dffs.writeDFFSID(); }, 100); } else { var currId = inp.val(); if (currId === "") { var id = new Date().valueOf(); setFieldValue("_DFFSID", id); spjs.dffs.data._DFFSID = id; }else{ spjs.dffs.data._DFFSID = currId; } } } };
Best regards,
Alexander -
June 9, 2020 at 20:59 #30527
Hi Alex,
Thank you for getting back so quickly. I will use this workaround till a proper fix is released.
Thank you,
Amal Vellappillil
-
-
AuthorPosts
- You must be logged in to reply to this topic.