Was wondering if this add-on module would allow me to build a rule to auto add specific products (and quantity) to the loged in users cart? Perhaps the action "Load product node by order line item" gets me close?
Any thoughts on the matter would be helpful. Thanks
C
Comments
Comment #1
lonehorseend commentedWhat about using Rules (not UC Rules) and doing a re-direct to a cart link?
Comment #2
vasrush commentedI recently found this. This is exactly what you want.
http://drupal.stackexchange.com/questions/8555/automatically-adding-paid...
Comment #3
innovafire commentedTwo points/questions:
1. The code above references a post on Drupal Stack Exchange and in that post the person posting it says he switched to D7. Is the code above D7 specific? I need it for D6. I did make a custom module with the above, and it installed correctly, but when I went to use the rule, it gave me the action to choose from, but on the second screen (after clicking "next") it did not give me any option to choose a product. So something seems to be off with that code. Can someone take a look and see what might be needing correction?
2. What I really want to do is to use this with Smartqueue. I have a Rule setup that saves the last viewed product to that user's Smartqueue. And I have it set that only the last product viewed is in there, so there is only ever one item in there. I have the person take another action (fill out a Webform) and then I want to trigger adding the product only after they are done. Can anyone help me on how to edit the above code to make that happen specifically?
#2 above is what I really need. I've been struggling with this for days and if anyone can help, I'd really appreciate it.
Thanks,
Chris
Comment #4
tinker commentedThis issue is very old and I am answering the questions just in case someone is looking for the same functionality.
@clintthayer, this module cannot do what you are looking for. You would need a trigger like 'user account created' then action 'load product' and action 'add product to cart'. If you want the product to always be in the cart even after the account is created then you would need something like trigger 'user has logged in', action 'load product', condition 'product not in cart', action 'add product to cart'. Unfortunately none of these are currently provided by this module. BTW, priority 'critical' is pretty much reserved for bugs that stop the module functioning.
@innovafire, yes the code provided by @vasrush is for drupal 7.
Marking this 'closed (fixed)' as I have hopefully answered the questions, the age of the requests, and an effort to close out old issues. If this is still a pertinent issue for anyone please reopen this issue as a feature request.