Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 1.********************MY VISUALFORCE PAGEBLOCK CODE********************
- 2.<apex:pageBlock title="Possible Personal Customer(s)" rendered="{!DisplayPosPersonalRecords = true && checkCustomer = 'No'}">
- 3. <apex:pageBlockTable value="{!ListPossiblePersonalRecords}" var="per" columnsWidth="5px, 5px" border="1">
- 4. <apex:column headerValue="Options">
- 5. <apex:commandLink value="Selectd" style="font-weight:bold;" action="{!SubmitNewContactMoveToOpp}" >
- 6. <apex:param name="paccId" value="{!per.Id}" assignTo="{!SelectedId}"/>
- 7. <apex:param name="paccType" value="Ppersonal" assignTo="{!SelectedType}" />
- 8. </apex:commandLink>
- 9. </apex:column>
- 10. <apex:column headerValue="Customer Name" value="{!per.aName}" width="80px"/>
- 11. ..
- 12. ..
- 13. ..
- 14. </apex:pageBlockTable>
- 15.</apex:pageBlock>
- 16.
- 17.********************MY APEX CODE {!ListPossiblePersonalRecords} NOW********************
- 18.public List<accountset> getListPossiblePersonalRecords() {
- 19.
- 20. accountlist = new List<accountset>();
- 21. string cemail = v_con.Email;
- 22. string cLastName = v_con.LastName;
- 23. string cFirstName = v_con.FirstName;
- 24.
- 25. List<Contact> Con = [select Id, Name, Email, FirstName,
- 26. LastName, CreatedDate, CreatedById,
- 27. Date_of_Birth__c, AccountId
- 28. from Contact
- 29. where email =: cemail
- 30. and LastName =: cLastName
- 31. and FirstName =: cFirstName];
- 32. for(Contact a:Con){
- 33. accountset thelist = new accountset();
- 34. thelist.Id = a.Id;
- 35. thelist.aName = a.Name;
- 36. thelist.DoB = a.Date_of_Birth__c;
- 37. thelist.Email = a.Email;
- 38. thelist.CreDate = a.CreatedDate;
- 39. accountlist.add(thelist);
- 40. }
- 41. return accountlist;
- 42.
- 43.}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement