+ Start a Discussion
MattStevensonMattStevenson 

Replicating the opportunity product system.

Hi i am fairly new to visualforce and apex.

 

What i am trying to create is a system that works similar to that of the standard object for opportunites and products. I am going to work with custom objects, i will have a main object (like opportunities in this case), and then i want to be able to add records from another object in the similar fashion of adding products to opportunties. So on the related list i would be able to click add item, and then check the items i want to add and attach them to the main object.

 

Im looking for some suggestions on the best way to go around doing this. I was thinking that it would be best to follow a wizard system using visualforce pages?

 

Any suggestions much appreciated.

 

Matt 

WmWm
Create a master detail relationship between custom Opportunities and Custom Products
WmWm
You would not need to worry about the Apex and VF for just this one. they will just come into picture only when you decide add some complex logics to it...
Cool_DevloperCool_Devloper

Matt,

Are you looking to build a custom Opp/Product relationship here ?

If yes, then you should know that there are many OOTB features which you might have to rebuild with your custom data model!

BTW, y r u looking at using VF in this case? Anything specific?

Cool_D 

MattStevensonMattStevenson
Im have created the custom objects and master detail relationship, im looking to create a visualforce page where i can add multiple products at once rather than going through adding each product one by one.
Cool_DevloperCool_Devloper

Well, in that case you can create a VF page which will have a "Create Child" section.

You can add the input fields here and then save the details on click of a save button. The important thing would be that, instead of refreshing the page, you can reRender just this section. So, that the user comes back to the create section automatically!

In case, you are looking at adding mutiple items, you can create as many sections on ur page which will reRender, independently;)

Cool_D