-
ChatterFeed
-
2Best Answers
-
0Likes Received
-
0Likes Given
-
4Questions
-
9Replies
"An internal server error has occurred" when rendered as pdf
We are trying to render build specifications based on sales order data. Various data elements need to be pulled in and related to output the necessary content. The Visual Force page leverages the standard controller for the SalesOrder custom object, and uses an extension controller to pull together all the relevant related records.
Problem: When this page is rendered as HTML, the page displays as expected. However, if the page is rendered as PDF, a generic error message appears:
An internal server error has occurred |
An error has occurred while processing your request. The salesforce.com support team has been notified of the problem. If you believe you have additional information that may be of help in reproducing or correcting the error, please contact support@salesforce.com. Please indicate the URL of the page you were requesting, any error id shown on this page as well as any other related information. We apologize for the inconvenience. Thank you again for your patience and assistance. And thanks for using Salesforce! Error ID: 938602852-1015 (-236663650) |
How can we get more information about the source of the issue that causes this error? Better yet, what is the cause of the problem?
The related code is attached below:
Main VS Page:
<apex:page standardController="kaz_salesorder__c" extensions="extSalesOrderPrint" showHeader="false" renderAs="pdf"> <html> <head> <style type="text/css" media="print"> .PB { page-break-inside: avoid; page-break-after: always; height: 100%; width: 100%; border: solid 0px #000000; } .PBAVOID, .PBAVOID div, .PBAVOID table{ page-break-inside: avoid;} body { margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font-family: Arial, Helvetica, Geneva, SunSans-Regular, sans-serif; } @page { size: portrait; } </style> <style type="text/css" media="screen,print"> body, td, span, div { font-family: Arial, Helvetica, Geneva, SunSans-Regular, sans-serif; font-size: 11px;} .OUTLINE_DARK, .OUTLINE_MEDIUM, .OUTLINE_LIGHT { border: solid 1px #000000; padding: 5px; } .OUTLINE_DARK { background-color: #CCCCCC; } .OUTLINE_MEDIUM { background-color: #EEEEEE; } .OUTLINE_LIGHT { background-color: none; } .LABEL_BOLD { font-weight: bold; font-size: 12px;} .LABEL_LARGE { font-weight: bold; font-size:16px; } .LABEL_HEADING { font-weight: bold; font-size:22px; } td.BOMChecklist, th.BOMChecklist { border-bottom: 1px solid #000000;border-right: 1px solid #000000;} table.BOMChecklist { border-top: 1px solid #000000;border-left: 1px solid #000000;} table.BOMChecklist th, th.BOMChecklist{ Background-Color: #eeeeee; font-size: 14; } table.ProductList td, table.ProductList th { border-bottom: 1px solid #000000;border-right: 1px solid #000000;} table.ProductList th { Background-color: #eeeeee; font-size: 14; text-align: right;} table.ProductList { border-top: 1px solid #000000;border-left: 1px solid #000000;} table.AvoidBorder td, table.AvoidBorder th { border-bottom: 0px solid #000000;border-right: 0px solid #000000;} </style> </head> <body> <apex:variable var="itemIndex" value="{!0}" /> <apex:outputPanel rendered="{!(HwBaseItems.size>0)}" layout="none" id="hw"> <apex:repeat value="{!HwBaseItems.items}" var="li" id="HwLineItems"> <apex:repeat value="{!li.assets}" var="ia" id="ItemAssets"> <apex:variable var="itemIndex" value="{!(itemIndex+1)}" /> <div class="PB"> <c:BuildSheetHeader so="{!kaz_salesorder__c}" /> <br /> <apex:variable var="FeatureLicensesCombined" value="{!IF(ISNULL(li.item.Product__r.Addon_Licenses__c),'',li.item.Product__r.Addon_Licenses__c)}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAssets2"><apex:variable var="FeatureLicensesCombined" value="{!IF(FeatureLicensesCombined='','',FeatureLicensesCombined&' ')&IF(ISNULL(ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c),'',ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c)}" /></apex:repeat> <c:BuildSheetItemDetails ProductCategory="Appliance" ProductItemIndex="{!Text(itemIndex/1)}" ProductCode="{!li.item.ProductCode__c}" ItemName="{!ia.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ia.duration}" ProductName="{!li.item.ProductName__c}" BaseLicense="{!li.item.Product__r.Base_License__c}" FeatureLicense="{!FeatureLicensesCombined}"/> <br /> <c:BillOfMaterialChecklist bom="{!li.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> <apex:variable var="itemSubIndex" value="{!0}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAddonAssets"> <apex:variable var="itemSubIndex" value="{!(itemSubIndex+1)}" /> <br /> <c:BuildSheetItemDetails ProductCategory="Installed Add-on Item" ProductItemIndex="{!TEXT(itemIndex/1)&'.'&TEXT(itemSubIndex/1)}" ProductCode="{!ra.itemAsset.Sales_Order_Item__r.Product__r.ProductCode}" ItemName="{!ra.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ra.duration}" ProductName="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Name}" BaseLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Base_License__c}" FeatureLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c}"/> <br /> <c:BillOfMaterialChecklist bom="{!ra.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> </apex:repeat> </div> </apex:repeat> </apex:repeat> </apex:outputPanel> <apex:outputPanel rendered="{!(SwBaseItems.size>0)}" layout="none" id="sw"> <apex:repeat value="{!SwBaseItems.items}" var="li" id="SwLineItems"> <apex:repeat value="{!li.assets}" var="ia" id="ItemAssets"> <apex:variable var="itemIndex" value="{!(itemIndex+1)}" /> <div class="PB"> <c:BuildSheetHeader so="{!kaz_salesorder__c}" /> <br /> <apex:variable var="FeatureLicensesCombined" value="{!IF(ISNULL(li.item.Product__r.Addon_Licenses__c),'',li.item.Product__r.Addon_Licenses__c)}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAssets2"><apex:variable var="FeatureLicensesCombined" value="{!IF(FeatureLicensesCombined='','',FeatureLicensesCombined&' ')&IF(ISNULL(ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c),'',ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c)}" /></apex:repeat> <c:BuildSheetItemDetails ProductCategory="Software Only" ProductItemIndex="{!Text(itemIndex/1)}" ProductCode="{!li.item.ProductCode__c}" ItemName="{!ia.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ia.duration}" ProductName="{!li.item.ProductName__c}" BaseLicense="{!li.item.Product__r.Base_License__c}" FeatureLicense="{!FeatureLicensesCombined}"/> <br /> <c:BillOfMaterialChecklist bom="{!li.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> <apex:variable var="itemSubIndex" value="{!0}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAddonAssets"> <apex:variable var="itemSubIndex" value="{!(itemSubIndex+1)}" /> <br /> <c:BuildSheetItemDetails ProductCategory="Installed Add-on Item" ProductItemIndex="{!TEXT(itemIndex/1)&'.'&TEXT(itemSubIndex/1)}" ProductCode="{!ra.itemAsset.Sales_Order_Item__r.Product__r.ProductCode}" ItemName="{!ra.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ra.duration}" ProductName="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Name}" BaseLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Base_License__c}" FeatureLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c}"/> <br /> <c:BillOfMaterialChecklist bom="{!ra.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> </apex:repeat> </div> </apex:repeat> </apex:repeat> </apex:outputPanel> <apex:outputPanel rendered="{!(AddonItems.size>0)}" layout="none" id="addon"> <apex:repeat value="{!AddonItems.items}" var="li" id="AssonLineItems"> <apex:repeat value="{!li.assets}" var="ia" id="ItemAssets"> <apex:outputPanel rendered="{!NOT(ia.HasParent)}" layout="none" id="addon"> <apex:variable var="itemIndex" value="{!(itemIndex+1)}" /> <div class="PB"> <c:BuildSheetHeader so="{!kaz_salesorder__c}" /> <br /> <apex:variable var="FeatureLicensesCombined" value="{!IF(ISNULL(li.item.Product__r.Addon_Licenses__c),'',li.item.Product__r.Addon_Licenses__c)}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAssets2"><apex:variable var="FeatureLicensesCombined" value="{!IF(FeatureLicensesCombined='','',FeatureLicensesCombined&' ')&IF(ISNULL(ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c),'',ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c)}" /></apex:repeat> <c:BuildSheetItemDetails ProductCategory="Add-on Item" ProductItemIndex="{!Text(itemIndex/1)}" ProductCode="{!li.item.ProductCode__c}" ItemName="{!ia.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ia.duration}" ProductName="{!li.item.ProductName__c}" BaseLicense="{!li.item.Product__r.Base_License__c}" FeatureLicense="{!FeatureLicensesCombined}"/> <br /> <c:BillOfMaterialChecklist bom="{!li.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> <apex:variable var="itemSubIndex" value="{!0}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAddonAssets"> <apex:variable var="itemSubIndex" value="{!(itemSubIndex+1)}" /> <br /> <c:BuildSheetItemDetails ProductCategory="Installed Add-on Item" ProductItemIndex="{!TEXT(itemIndex/1)&'.'&TEXT(itemSubIndex/1)}" ProductCode="{!ra.itemAsset.Sales_Order_Item__r.Product__r.ProductCode}" ItemName="{!ra.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ra.duration}" ProductName="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Name}" BaseLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Base_License__c}" FeatureLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c}"/> <br /> <c:BillOfMaterialChecklist bom="{!ra.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> </apex:repeat> </div> </apex:outputPanel> </apex:repeat> </apex:repeat> </apex:outputPanel> </body> </html> </apex:page>
BuildSheetHeader code:
<apex:component > <apex:attribute name="so" description="Items reflects the Sales Order object" type="kaz_salesorder__c" required="true"/> <div class="OUTLINE_DARK"> <table width="100%"> <tr> <td width="0%"><img src="{!$Resource.TrainingCertificate}/kazeon_logo_hd.png" height="20px"/></td> <td width="60%" align="center"><span class="LABEL_HEADING">BUILD ORDER</span></td> <td width="20%"> <span class="LABEL_BOLD">Kazeon SO</span><br /><apex:outputText value="{!so.Name}" /> </td> <td width="20%"> <span class="LABEL_BOLD">Date</span><br /><apex:outputText value="{!TEXT(MONTH(TODAY()))&'/'&TEXT(DAY(TODAY()))&'/'&TEXT(YEAR(TODAY()))}" /> </td> </tr> </table> </div> <div class="OUTLINE_LIGHT"> <table cellpadding="2" cellspacing="0" border="0" width="100%"> <tr> <td valign="top"> <table cellpadding="4" cellspacing="0" border="0" width="100%"> <tr> <td align="right"><span class="LABEL_BOLD">Customer: </span></td> <td><apex:outputText styleClass="" value="{!so.Account__r.Name}" /></td> </tr> <tr> <td align="right"><span class="LABEL_BOLD">PO: </span></td> <td><apex:outputText value="{!so.PurchaseOrderNumber__c}" /></td> <tr> <apex:outputPanel rendered="{!NOT(ISNULL(so.Partner_Sales_Order__c))}" layout="none"> <tr> <td align="right"><span class="LABEL_BOLD">Partner SO: </span></td> <td><apex:outputText value="{!so.Partner_Sales_Order__c}" /></td> </tr> </apex:outputPanel> </table> </td> <td> <table cellpadding="4" cellspacing="0" border="0" width="100%"> <tr> <td valign="top" align="right"><span class="LABEL_BOLD">Shipping Address:</span></td> <td> <pre><apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingStreet__c))}" layout="none"><apex:outputText value="{!so.ShippingStreet__c}" /><br /></apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingCity__c))}" layout="none"><apex:outputText value="{!so.ShippingCity__c}" />, </apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingState__c))}" layout="none"><apex:outputText value="{!so.ShippingState__c}" /> </apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingPostalCode__c))}" layout="none"><apex:outputText value="{!so.ShippingPostalCode__c}" /></apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingCountry__c))}" layout="none"><br />(<apex:outputText value="{!so.ShippingCountry__c}" />)</apex:outputPanel></pre> </td> </tr> </table> </td> </tr> </table> </div> </apex:component>
-
- gribis
- March 16, 2009
- Like
- 0
- Continue reading or reply
Send Email URL hack not passing multiple parameters
I'm trying to create a custom button on Task that will auto close the task and launch the Send Email form.
I have gotten this far:
/{!Task.Id}/e?&tsk12=Completed&save=x&saveURL=/_ui/core/email/author/EmailAuthor?p3_lkid={!Task.What}
I have two problems that I am struggling to overcome:
1.
I am unable to add more than 1 parameter to be passed to the send email form
If I add &p2_lkid={!Task.Who} or&p6=Order Confirmation
none of the parameters are passed through to the send email form..... the hacked url just seems to end at the first parameter p3_lkid={!Task.What}
2.
Once the email is sent, I am returned to the home page..... I cannot work out how to return either to the orininal task or the Related To record
Thanks in advance for any help/advice
-
- Alexy1967
- December 04, 2012
- Like
- 0
- Continue reading or reply
Rounding Percentage
I am trying to round a percentage to 2 decimal places using the ROUND function, however the result returned is to the nearest whole number.
Any help would be most appreciated.
-
- Alexy1967
- July 10, 2010
- Like
- 0
- Continue reading or reply
site does not work with IE
Hi
I have created a very simple site to allow users to book an exam date.
The site works as required in firefox and safari but I'm having issues trying to get it to work in IE7 or IE8.
Firstly, the page will not render correctly, telling me that my "'DatePicker' is undefined"
Secondly, the link to today's date does not work and the pop up calendar does not work.
Here is my code:
VF Page: <apex:page standardcontroller="Exam_Booking__c" extensions="ExamBooking" sidebar="false" standardStylesheets="true" showHeader="false"> <html> <body> <apex:form > <apex:pageBlock > <br></br> <br></br> <apex:image value="{!$Resource.AAPT_Logo_2009}" width="150" height="30"/> <br></br> <br></br> <h1>AAPT Business Solutions Product Accreditation Program</h1> <br></br> <br></br> <h1>Exam Registration</h1> <br></br> <br></br> <apex:panelGrid columns="2" cellpadding="3"> <apex:outputText value="First Name"/> <apex:inputField value="{!Exam_Booking__c.First_Name__c}" required="true" /> <apex:outputText value="Last Name"/> <apex:inputField value="{!Exam_Booking__c.Last_Name__c}" required="true" /> <apex:outputText value="Phone"/> <apex:inputField value="{!Exam_Booking__c.Phone__c}" required="true" /> <apex:outputText value="Email"/> <apex:inputField value="{!Exam_Booking__c.Email__c}" required="true" /> <apex:outputText value="Subject"/> <apex:inputField value="{!Exam_Booking__c.Subject__c}"required="true" /> <apex:outputText value="Date"/> <apex:inputfield value="{!Exam_Booking__c.Date__c}"required="true" /> </apex:panelGrid> <br></br> <br></br> <apex:pageMessages /> <apex:pageblockButtons location="bottom"> <apex:commandButton value="Save" action="{!Save}" /> <apex:commandButton value="Cancel" action="{!cancel}" /> </apex:pageBlockButtons> </apex:pageBlock> </apex:form> </body> </html> </apex:page> Controller: public class ExamBooking { private final Exam_Booking__c ExamBooking; public ExamBooking (ApexPages.StandardController stdController) { this.ExamBooking = (Exam_Booking__c)stdController.getRecord(); } public PageReference save() { try { insert(ExamBooking); } catch(System.DMLException e) { ApexPages.addMessages(e); return null; } PageReference p = Page.publicthankyou; p.setRedirect(true); return p; } }
Any thoughts would be most appreciated
Thanks in advance
-
- Alexy1967
- February 15, 2010
- Like
- 0
- Continue reading or reply
Contolling Customizable forecasting with Record Type
-
- Alexy1967
- November 08, 2006
- Like
- 0
- Continue reading or reply
Managed Package for Popup Alert
- TMango
- April 05, 2019
- Like
- 0
- Continue reading or reply
How to add an Outputlink next to an inputfield on a form
I have been able to add the outputlink to the page but cannot work out how to get the link to appear next to the field rather than next to it.
Attached is a mockup of what I'd like it to look like:
Any help would be greatly appreciated
thanks
- Alex Youroukelis 4
- May 14, 2014
- Like
- 0
- Continue reading or reply
Send Email URL hack not passing multiple parameters
I'm trying to create a custom button on Task that will auto close the task and launch the Send Email form.
I have gotten this far:
/{!Task.Id}/e?&tsk12=Completed&save=x&saveURL=/_ui/core/email/author/EmailAuthor?p3_lkid={!Task.What}
I have two problems that I am struggling to overcome:
1.
I am unable to add more than 1 parameter to be passed to the send email form
If I add &p2_lkid={!Task.Who} or&p6=Order Confirmation
none of the parameters are passed through to the send email form..... the hacked url just seems to end at the first parameter p3_lkid={!Task.What}
2.
Once the email is sent, I am returned to the home page..... I cannot work out how to return either to the orininal task or the Related To record
Thanks in advance for any help/advice
- Alexy1967
- December 04, 2012
- Like
- 0
- Continue reading or reply
Rounding Percentage
I am trying to round a percentage to 2 decimal places using the ROUND function, however the result returned is to the nearest whole number.
Any help would be most appreciated.
- Alexy1967
- July 10, 2010
- Like
- 0
- Continue reading or reply
Error: The value attribute on <apex:outputText> is not in a valid format. It must be a positive number, and of type Number, Date, Time, or Choice.
I am using an outputText tag along with a param tag to format a date file. This works quite well in the sprin'09 release. I get compile errors in Summer '09. Here is a simple page that works in spring'09 but gets an error on save in the summer '09 release.
<apex:page >
<h1>Congratulations</h1>
This is your new Page
<apex:outputText value="{0,date, MMMM d', 'yyyy}">
<apex:param value="{!NOW()}" />
</apex:outputText>
</apex:page>
The error message I get in summer '09 is below. Does anyone have any idea how to get around this? I have opened a case on this - the number is 02709898
Error: The value attribute on <apex:outputText> is not in a valid format. It must be a positive number, and of type Number, Date, Time, or Choice.
|
![]() |
- DianeM
- June 08, 2009
- Like
- 0
- Continue reading or reply
"An internal server error has occurred" when rendered as pdf
We are trying to render build specifications based on sales order data. Various data elements need to be pulled in and related to output the necessary content. The Visual Force page leverages the standard controller for the SalesOrder custom object, and uses an extension controller to pull together all the relevant related records.
Problem: When this page is rendered as HTML, the page displays as expected. However, if the page is rendered as PDF, a generic error message appears:
An internal server error has occurred |
An error has occurred while processing your request. The salesforce.com support team has been notified of the problem. If you believe you have additional information that may be of help in reproducing or correcting the error, please contact support@salesforce.com. Please indicate the URL of the page you were requesting, any error id shown on this page as well as any other related information. We apologize for the inconvenience. Thank you again for your patience and assistance. And thanks for using Salesforce! Error ID: 938602852-1015 (-236663650) |
How can we get more information about the source of the issue that causes this error? Better yet, what is the cause of the problem?
The related code is attached below:
Main VS Page:
<apex:page standardController="kaz_salesorder__c" extensions="extSalesOrderPrint" showHeader="false" renderAs="pdf"> <html> <head> <style type="text/css" media="print"> .PB { page-break-inside: avoid; page-break-after: always; height: 100%; width: 100%; border: solid 0px #000000; } .PBAVOID, .PBAVOID div, .PBAVOID table{ page-break-inside: avoid;} body { margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font-family: Arial, Helvetica, Geneva, SunSans-Regular, sans-serif; } @page { size: portrait; } </style> <style type="text/css" media="screen,print"> body, td, span, div { font-family: Arial, Helvetica, Geneva, SunSans-Regular, sans-serif; font-size: 11px;} .OUTLINE_DARK, .OUTLINE_MEDIUM, .OUTLINE_LIGHT { border: solid 1px #000000; padding: 5px; } .OUTLINE_DARK { background-color: #CCCCCC; } .OUTLINE_MEDIUM { background-color: #EEEEEE; } .OUTLINE_LIGHT { background-color: none; } .LABEL_BOLD { font-weight: bold; font-size: 12px;} .LABEL_LARGE { font-weight: bold; font-size:16px; } .LABEL_HEADING { font-weight: bold; font-size:22px; } td.BOMChecklist, th.BOMChecklist { border-bottom: 1px solid #000000;border-right: 1px solid #000000;} table.BOMChecklist { border-top: 1px solid #000000;border-left: 1px solid #000000;} table.BOMChecklist th, th.BOMChecklist{ Background-Color: #eeeeee; font-size: 14; } table.ProductList td, table.ProductList th { border-bottom: 1px solid #000000;border-right: 1px solid #000000;} table.ProductList th { Background-color: #eeeeee; font-size: 14; text-align: right;} table.ProductList { border-top: 1px solid #000000;border-left: 1px solid #000000;} table.AvoidBorder td, table.AvoidBorder th { border-bottom: 0px solid #000000;border-right: 0px solid #000000;} </style> </head> <body> <apex:variable var="itemIndex" value="{!0}" /> <apex:outputPanel rendered="{!(HwBaseItems.size>0)}" layout="none" id="hw"> <apex:repeat value="{!HwBaseItems.items}" var="li" id="HwLineItems"> <apex:repeat value="{!li.assets}" var="ia" id="ItemAssets"> <apex:variable var="itemIndex" value="{!(itemIndex+1)}" /> <div class="PB"> <c:BuildSheetHeader so="{!kaz_salesorder__c}" /> <br /> <apex:variable var="FeatureLicensesCombined" value="{!IF(ISNULL(li.item.Product__r.Addon_Licenses__c),'',li.item.Product__r.Addon_Licenses__c)}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAssets2"><apex:variable var="FeatureLicensesCombined" value="{!IF(FeatureLicensesCombined='','',FeatureLicensesCombined&' ')&IF(ISNULL(ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c),'',ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c)}" /></apex:repeat> <c:BuildSheetItemDetails ProductCategory="Appliance" ProductItemIndex="{!Text(itemIndex/1)}" ProductCode="{!li.item.ProductCode__c}" ItemName="{!ia.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ia.duration}" ProductName="{!li.item.ProductName__c}" BaseLicense="{!li.item.Product__r.Base_License__c}" FeatureLicense="{!FeatureLicensesCombined}"/> <br /> <c:BillOfMaterialChecklist bom="{!li.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> <apex:variable var="itemSubIndex" value="{!0}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAddonAssets"> <apex:variable var="itemSubIndex" value="{!(itemSubIndex+1)}" /> <br /> <c:BuildSheetItemDetails ProductCategory="Installed Add-on Item" ProductItemIndex="{!TEXT(itemIndex/1)&'.'&TEXT(itemSubIndex/1)}" ProductCode="{!ra.itemAsset.Sales_Order_Item__r.Product__r.ProductCode}" ItemName="{!ra.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ra.duration}" ProductName="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Name}" BaseLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Base_License__c}" FeatureLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c}"/> <br /> <c:BillOfMaterialChecklist bom="{!ra.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> </apex:repeat> </div> </apex:repeat> </apex:repeat> </apex:outputPanel> <apex:outputPanel rendered="{!(SwBaseItems.size>0)}" layout="none" id="sw"> <apex:repeat value="{!SwBaseItems.items}" var="li" id="SwLineItems"> <apex:repeat value="{!li.assets}" var="ia" id="ItemAssets"> <apex:variable var="itemIndex" value="{!(itemIndex+1)}" /> <div class="PB"> <c:BuildSheetHeader so="{!kaz_salesorder__c}" /> <br /> <apex:variable var="FeatureLicensesCombined" value="{!IF(ISNULL(li.item.Product__r.Addon_Licenses__c),'',li.item.Product__r.Addon_Licenses__c)}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAssets2"><apex:variable var="FeatureLicensesCombined" value="{!IF(FeatureLicensesCombined='','',FeatureLicensesCombined&' ')&IF(ISNULL(ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c),'',ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c)}" /></apex:repeat> <c:BuildSheetItemDetails ProductCategory="Software Only" ProductItemIndex="{!Text(itemIndex/1)}" ProductCode="{!li.item.ProductCode__c}" ItemName="{!ia.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ia.duration}" ProductName="{!li.item.ProductName__c}" BaseLicense="{!li.item.Product__r.Base_License__c}" FeatureLicense="{!FeatureLicensesCombined}"/> <br /> <c:BillOfMaterialChecklist bom="{!li.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> <apex:variable var="itemSubIndex" value="{!0}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAddonAssets"> <apex:variable var="itemSubIndex" value="{!(itemSubIndex+1)}" /> <br /> <c:BuildSheetItemDetails ProductCategory="Installed Add-on Item" ProductItemIndex="{!TEXT(itemIndex/1)&'.'&TEXT(itemSubIndex/1)}" ProductCode="{!ra.itemAsset.Sales_Order_Item__r.Product__r.ProductCode}" ItemName="{!ra.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ra.duration}" ProductName="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Name}" BaseLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Base_License__c}" FeatureLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c}"/> <br /> <c:BillOfMaterialChecklist bom="{!ra.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> </apex:repeat> </div> </apex:repeat> </apex:repeat> </apex:outputPanel> <apex:outputPanel rendered="{!(AddonItems.size>0)}" layout="none" id="addon"> <apex:repeat value="{!AddonItems.items}" var="li" id="AssonLineItems"> <apex:repeat value="{!li.assets}" var="ia" id="ItemAssets"> <apex:outputPanel rendered="{!NOT(ia.HasParent)}" layout="none" id="addon"> <apex:variable var="itemIndex" value="{!(itemIndex+1)}" /> <div class="PB"> <c:BuildSheetHeader so="{!kaz_salesorder__c}" /> <br /> <apex:variable var="FeatureLicensesCombined" value="{!IF(ISNULL(li.item.Product__r.Addon_Licenses__c),'',li.item.Product__r.Addon_Licenses__c)}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAssets2"><apex:variable var="FeatureLicensesCombined" value="{!IF(FeatureLicensesCombined='','',FeatureLicensesCombined&' ')&IF(ISNULL(ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c),'',ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c)}" /></apex:repeat> <c:BuildSheetItemDetails ProductCategory="Add-on Item" ProductItemIndex="{!Text(itemIndex/1)}" ProductCode="{!li.item.ProductCode__c}" ItemName="{!ia.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ia.duration}" ProductName="{!li.item.ProductName__c}" BaseLicense="{!li.item.Product__r.Base_License__c}" FeatureLicense="{!FeatureLicensesCombined}"/> <br /> <c:BillOfMaterialChecklist bom="{!li.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> <apex:variable var="itemSubIndex" value="{!0}" /> <apex:repeat value="{!ia.assets}" var="ra" id="RelatedAddonAssets"> <apex:variable var="itemSubIndex" value="{!(itemSubIndex+1)}" /> <br /> <c:BuildSheetItemDetails ProductCategory="Installed Add-on Item" ProductItemIndex="{!TEXT(itemIndex/1)&'.'&TEXT(itemSubIndex/1)}" ProductCode="{!ra.itemAsset.Sales_Order_Item__r.Product__r.ProductCode}" ItemName="{!ra.item.Name}" Release="{!kaz_salesorder__c.Release__c}" Duration="{!ra.duration}" ProductName="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Name}" BaseLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Base_License__c}" FeatureLicense="{!ra.itemAsset.Sales_Order_Item__r.Product__r.Addon_Licenses__c}"/> <br /> <c:BillOfMaterialChecklist bom="{!ra.bom}" channel="{!kaz_salesorder__c.Channel__c}" /> </apex:repeat> </div> </apex:outputPanel> </apex:repeat> </apex:repeat> </apex:outputPanel> </body> </html> </apex:page>
BuildSheetHeader code:
<apex:component > <apex:attribute name="so" description="Items reflects the Sales Order object" type="kaz_salesorder__c" required="true"/> <div class="OUTLINE_DARK"> <table width="100%"> <tr> <td width="0%"><img src="{!$Resource.TrainingCertificate}/kazeon_logo_hd.png" height="20px"/></td> <td width="60%" align="center"><span class="LABEL_HEADING">BUILD ORDER</span></td> <td width="20%"> <span class="LABEL_BOLD">Kazeon SO</span><br /><apex:outputText value="{!so.Name}" /> </td> <td width="20%"> <span class="LABEL_BOLD">Date</span><br /><apex:outputText value="{!TEXT(MONTH(TODAY()))&'/'&TEXT(DAY(TODAY()))&'/'&TEXT(YEAR(TODAY()))}" /> </td> </tr> </table> </div> <div class="OUTLINE_LIGHT"> <table cellpadding="2" cellspacing="0" border="0" width="100%"> <tr> <td valign="top"> <table cellpadding="4" cellspacing="0" border="0" width="100%"> <tr> <td align="right"><span class="LABEL_BOLD">Customer: </span></td> <td><apex:outputText styleClass="" value="{!so.Account__r.Name}" /></td> </tr> <tr> <td align="right"><span class="LABEL_BOLD">PO: </span></td> <td><apex:outputText value="{!so.PurchaseOrderNumber__c}" /></td> <tr> <apex:outputPanel rendered="{!NOT(ISNULL(so.Partner_Sales_Order__c))}" layout="none"> <tr> <td align="right"><span class="LABEL_BOLD">Partner SO: </span></td> <td><apex:outputText value="{!so.Partner_Sales_Order__c}" /></td> </tr> </apex:outputPanel> </table> </td> <td> <table cellpadding="4" cellspacing="0" border="0" width="100%"> <tr> <td valign="top" align="right"><span class="LABEL_BOLD">Shipping Address:</span></td> <td> <pre><apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingStreet__c))}" layout="none"><apex:outputText value="{!so.ShippingStreet__c}" /><br /></apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingCity__c))}" layout="none"><apex:outputText value="{!so.ShippingCity__c}" />, </apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingState__c))}" layout="none"><apex:outputText value="{!so.ShippingState__c}" /> </apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingPostalCode__c))}" layout="none"><apex:outputText value="{!so.ShippingPostalCode__c}" /></apex:outputPanel> <apex:outputPanel rendered="{!NOT(ISNULL(so.ShippingCountry__c))}" layout="none"><br />(<apex:outputText value="{!so.ShippingCountry__c}" />)</apex:outputPanel></pre> </td> </tr> </table> </td> </tr> </table> </div> </apex:component>
- gribis
- March 16, 2009
- Like
- 0
- Continue reading or reply
Contolling Customizable forecasting with Record Type
- Alexy1967
- November 08, 2006
- Like
- 0
- Continue reading or reply