I'm trying to get my head around the inner workings of DataObjects at the moment. I have set up this: http://pastie.org/1156856
When I try to use my addProduct function, it works. A new record is created in the Order_ProductPages table. Whenever I call the function again to try and make the same connection between the order and the product, the previous record is overwritten.
I’m obviously missing something basic here. Or I’m trying to use ComponentSet for something it isn’t meant for.
Can anyone point me in the right direction? Thanks.