Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Developer Name of Email Template in Personal Site Contact Lookup Controller #348

Open
jesslopez-sf opened this issue May 29, 2018 · 2 comments

Comments

@jesslopez-sf
Copy link

The VOL_CTRL_PersonalSiteContactLookup Apex class queries for an Email Template using the Name field. If a customer renames the Email Template, it results in a "nullREQUIRED_FIELD_MISSING: Email body is required" error on the PersonalSiteContactLookup Visualforce page.

Proposing we instead query on DeveloperName instead in case they rename.
https://github.com/SalesforceFoundation/Volunteers-for-Salesforce/blob/master/src/classes/VOL_CTRL_PersonalSiteContactLookup.cls#L91

Current Query:
list<EmailTemplate> listT = [select Id from EmailTemplate where Name='Volunteers Personal Site Contact Lookup' limit 1];

Proposed Query:
list<EmailTemplate> listT = [select Id from EmailTemplate where DeveloperName='Volunteers_Personal_Site_Contact_Lookup' limit 1];

Other areas of the package are using the DeveloperName when querying against the EmailTemplate object.

@jesslopez-sf
Copy link
Author

**lurch: add

@LurchTheButler
Copy link

Tracking W-025094

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants