Link for pdf liabrary https://automationchampion.com/2024/05/27/a-step-by-step-guide-to-merging-and-displaying-pdfs-in-salesforce-2/ public class QuoteFileService { @AuraEnabled(cacheable=true) public static List<Map<String, String>> getPdfFilesWithIdsAsBase64(Id opportunityId) { // List of statuses in the required order List<String> statusOrder = new List<String>{'Accepted','Denied','Rejected','Approved','In Review','Needs Review','Draft'}; // Find all quotes related to the given opportunity List<Quote> quotes = [SELECT Id, Status FROM Quote WHERE OpportunityId = :opportunityId]; // Collect all quote IDs Set<Id> quoteIds = new Set<Id>(); ...
Comments
Post a Comment