7

I'm trying to render a select field with email templates under Sytemem->Configuration . When i open the configuration tab it doenst show any config fields more.

Here are my files

etc/system.xml

  <field id="pickup_template" translate="label comment" type="select" sortOrder="3" showInDefault="1" showInWebsite="1" showInStore="1">
                <label>New Order Confirmation Template for Guest</label>
                <comment>Email template chosen based on theme fallback when "Default" option is selected.</comment>
                <source_model>Magento\Config\Model\Config\Source\Email\Template</source_model>
  </field>

etc/email_templates.xml

   <template id="pickup_template" label="New Order" file="yourfile.html" type="html" module="Hello_StorePickup" area="frontend"/>

view/frontend/email/yourfile.html

    <b>message</b>
  • What do you mean by "it doenst show any config fields more"? Sounds like an exception that is thrown. – Fabian Blechschmidt Jan 30 '16 at 12:17
  • In log system.log show a error check it – ND17 Apr 19 '16 at 6:52
  • @ND17 would you able to resolve that I have the same problem ?? – Manish Sep 5 '16 at 13:48
  • you can check apache/server log if exception.log have no error – Ashish Raj Feb 1 '18 at 6:35
2

Get Section id and group id of that field For example Section id= id1 and group id = id2

and your etc/email_templates.xml like this

  <template id="id1_id2_pickup_template" label="New Order" file="yourfile.html" type="html" module="Hello_StorePickup" area="frontend"/>
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.