0

Hello I have created a custom field for Quantity(under Order Product object) to get the number as integer. Through the formula-->number-->decimal=0 and had the Standard field Quantity. The result worked fine, instead of 3.0 I do get 3.

My problem is that I have tried to get the custom field into the template and when i use quantity__c , i still get 3.0 and not 3 as i get on the order product. enter image description here enter image description here

<td style="background-color: #BA4697; color: #FFFFFF">
                    <b>Description-Type of Flower</b>
                </td>
                <td style="background-color: #BA4697; color: #FFFFFF">
                    <b>Details</b>
                </td>
                <td style="background-color: #BA4697; color: #FFFFFF">
                    <b>Quantity</b>
                </td>

            </tr>
                   <apex:repeat value="{!relatedTo.OrderItems}" var="lineItem">
                    <tr>
                        <td>
                             {!lineItem.PricebookEntry.Product2.Name}
                         </td>
                         <td>
                            {!lineItem.Description}
                        </td>
                         <td>
                             {!lineItem.Quant__c}
                        </td>

Any ideas please!!

0

If you can format the Quantity in Output Text something like:

<apex:outputText value="{0, number, ###,###}"><apex:param value="{!lineItem.Quant__c}"/></apex:outputText>

it may work.

| 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.