Developer forum

Forum » CMS - Standard features » Can I override the forms for editors receiver from the template?

Can I override the forms for editors receiver from the template?

Peter Leleulya
Peter Leleulya
Reply

In https://doc.dynamicweb.com/documentation-9/content/apps/forms-for-editors it states that all app configuration can be overriden from the template.

I have a situation that I give the customer a list of departments in the form and when they select one the mail must go to the email address of that department.

So for example the customer has 3 options

  • SALES (sales@mycompany.com)
  • HR (hr@mycompany.com)
  • DEVELOPMENT (monkeys@mycompany.com)

When selecting SALES I need the receipient of the company mail to be changed from the module/app setting to sales@mycompany.com.

What would be the best approach?
Can it be done by a hidden field as stated? And what would the id/name be?
Do I need to post the value and handle it in beforepost observer?
Is there a better way?
 


Replies

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply
This post has been marked as an answer

Hi Peter,

 

Yes, it is possible. The short answer is the field name (systemname) must be MailRecipient

 

For a lenghtier explanation check out this thread (and subsequent threads on it) https://doc.dynamicweb.com/forum/development/development/forms-for-editors-specific-recipient-from-submitted-form-value

 

Best Regards,

Nuno Aguiar

Votes for this answer: 1
 
Nicolai Pedersen
Reply
This post has been marked as an answer

Yeah - and the ninja way to find out what fields should be called is to inspect the names in developer tools:

Votes for this answer: 1

 

You must be logged in to post in the forum