Is there a built-in workflow email notification in EPiServer 7 CMS? I mean for example an editor changes or publishes a page, a set of users would be notified. And how do I set this up and make it work?
Workflows were not included in EPiServer 7.0 but reintroduced in 7.1.
Email notification on pages ready for publishing should be included by default for the SequentialApproval and ParallelApproval workflows.
What is your actual problem - that you can't enable and set up workflows, or that workflows are enabled but no emails are sent?
The EPiServer 7 admin manual contains a chapter on basic setup of workflows: http://world.episerver.com/Documents/Manuals/EPiServer%20CMS/AdminManuals/EPiServer%207%20CMS/EPiServer%207%20CMS%20Administrator%20User%20Guide%20(print)%20in%20English.pdf
Actually, I am also seeking for the same question. In my scenario, after user made changes, they should be approved by aprover.
This works ok.
But, after approver approved content changes - there should be sent email to other content editors, that there is changes approved and published. And I could not find built-in solution for this
So am I. I found information that the user WorkflowInstance should be setup, but it's not clear how to setup email notification.
Have you set up a working <smtp> section in your web.config? See http://stackoverflow.com/questions/4568392/smtp-web-config-configuration-and-usage
There's no UI for setting the from- and to-addresses for workflows. Since the email addresses of the users involved in the workflows are already known to EPiServer, they use the default smtp config to send emails. So if smtp config is missing or incorrect, no mails will be sent. Could that be the case?
In fact, if your smtp config does not specify a from-address, EPiServer will use "task@<hostname>" as the default from-address for workflow notifications. For more information about how to change the from-address and the layout of the notification email, see http://world.episerver.com/Blogs/Santosh-Achanta/Dates/2013/1/Tailoring-workflows-for-EPiServer-5-6-and-7/
Tip: Smtp4Dev is a great tool for faking a mail server in your dev/test environment.
As I noted, first part (with ParallelApproval workflow) works ok from the box - user makes a changes, approver receives a mail, approves or dissaproves - user (who made a change) - receives an email.
And then, there is a tricky part:
1) All other content editors, belonging to some groups, should receive an email, that there was an approved change. I imagine, that this could be done by calling next step, but how I could define this next step? As far as I see, it does not include such a functionality from the box :(...
2) From the box, we also have RequestForFeedbackService in Workflow. It have pretty self explanatory name - I suppose, that it allows us to request feedback, but, there is no (at least, no easily foundable) documentation, how to configure it.
Could you advice?
Thank you for assistance,
Yes, the <smtp> was configured incorrect. Currently mails are sent, and I use
<system.net> <mailSettings> <smtp deliveryMethod="Network" from="email@example.com"> <network host="smtp.gmail.com" port="587" enableSsl="true" defaultCredentials="false" userName="firstname.lastname@example.org" password="****" /> </smtp> </mailSettings> </system.net>
The same situation with RequestForFeedbackService (cms 7.2.).
When I strat it, I set the current page and the user to get the feedback from,
but the email is not sent to the aprover, and the aprover doesn't see the tickets in CMS.
How to check does the request for feedback works or not?
I've enabled the section, but no information in log, that RequestForFeedbackService doesn't work.
<system.diagnostics> <switches> <add name="System.Workflow.Runtime" value="All" /> <add name="System.Workflow.Runtime.Hosting" value="All" /> <add name="System.Workflow.Runtime.Tracking" value="All" /> <add name="System.Workflow.Activities" value="All" /> <add name="System.Workflow.Activities.Rules" value="All" /> <add name="System.Workflow LogToTraceListeners" value="0" /> <add name="System.Workflow LogToFile" value="1" /> </switches> <trace autoflush="true" indentsize="4"> <listeners> <add name="customListener" type="System.Diagnostics.TextWriterTraceListener" initializeData="WFTrace.log" /> </listeners> </trace> </system.diagnostics>
I have additional question about SequentialApproval.
If the approver rejects the changes, the creator of content sees the rejected message only in mailbox, he does'n see the ticket in cms.
Is it correct?
addition to the above questions http://world.episerver.com/Forum/Developer-forum/EPiServer-7-CMS/Thread-Container/2013/10/sequential--parallell-workflow-is-not-sending-feedback-mail-to-page-creator/
Yes, the email notification sometimes are swallowed.
Do not know, if you seen this, but Episerver support sent me this:
"Workflows haven't changed since CMS 6 R2, so there is CMS 6 R2 workflow source code you can look at to help you change the behavior of your workflows, such as Feedback Workflow: http://world.episerver.com/Blogs/Johan-Bjornfot/Dates1/2011/8/Source-code-for-the-CMS6R2-built-in-workflows/. There is a link in the blog post.
I know you've seen this document already, but when working with the workflows, you'll want to focus on the section "Task Related Activities" - http://world.episerver.com/Documentation/Items/Developers-Guide/EPiServer-CMS/7/Workflows/Developing-Workflows/."
Maybe you would be able to gain some added value out of there
I'm trying to set up sequential workflow with CMS 7.5 and according to this thread my workflow should send emails assuming I have the SMTP settings correct. I'm not seeing any evidence of the emails but the workflow seems to work as expected.
The SMTP settings I have are:
<system.net> <mailSettings> <smtp deliveryMethod="SpecifiedPickupDirectory" from="localhost@localdomain"> <network host="localhost" port="25" userName="" password="" defaultCredentials="false" /> <specifiedPickupDirectory pickupDirectoryLocation="C:\inetpub\mailroot\pickup" /> </smtp> </mailSettings> </system.net>
And I have also tried using SMTP4Dev and I don't get any mails in the pickup folder or coming through SMTP4Dev. Does anyone know a way of testing the email settings I have in web.config or know why the emails are not getting generated?
I am running into the same problem. Is there any activity or answer for this. I am using episerver 7.10
I am trying to setup Workflows on my current project and am also having the same problem where emails are not being sent (currently running 188.8.131.52)
When I debug within the EPiServer code there is an object reference error being thrown within the SendMail() method of EPiServer.Personalization.Task.
The line causing this is:
The null reference is being thrown on SiteDefinition.Current.SiteUrl. Within the context of this method an empty SiteDefinition is returned that has a null SiteUrl.
Calls to SiteDefinition.Current.SiteUrl elsewhere on the site do not have this problem. My suspiscion is that the WorkFlow task is being run in a thread that by default would have a null HttpContext.
This looks like a bug. Please could somebody from EPiServer add some insight to this issue?
The cause is likely as Simon says that workflows executes in a non-request thread.
SiteDefintion resolving works so that it tries to resolve the current site from the httprequest, if no http request is available it fallbacks to the site that has a wildcard host '*'. This applies to background tasks like workflow, scheduled job etc.
So the solution would be to add a host '*' to the site that you want background jobs to execute under. (An alternative solution is to assign SiteDefinition.Current in the background job, e.g. the workflow or the scheduled job).
Since posting this I have reported the problem to EPiServer Support who said they would log it as a bug. I have just tried your workaround by adding a wildcard host and this seems to have solved the problem, so thank you.