Conditional Actions

Project:Ubercart Contributions
Component:Code
Category:feature request
Priority:critical
Assigned:heydra
Status:active
Description
Project: 
Order Updates

Hi

I am having trouble creating a node once a user has completed a checkout.

What i am trying to do is create an even from the order, so it recalls the order number and puts that as the event title and adds the user, and date of delivery as the date for the event. and that will go into a calendar using the drupal calendar module.

Any help please....

Thank you.

Version: 
Ubercart 2.0-RC1
Rosso69's picture
Offline
Joined: 11/08/2010
Juice: 12
#2

Hello there,

I use a php script in the Conditional Actions

example

$newnode = new stdClass();
$newnode->title = "order :".$order->order_id;
global $user;
$newnode->uid = $user->uid;
$newnode->type = 'order'; // can also be another content type like event.
$newnode->status = 1;
$newnode->promote = 0;
$newnode->field_order_order_id[0]['value'] = $order->order_id;
node_save($newnode);