Tags/topics: 
1
Answers
Vote up!
0
Vote down!

grant user points equals to product price

I would like to grant user points to product owner in amount of product price after product sold.
for this I define a rule as below:

    Events:
  • Completing the checkout process
  • Actions:

  • Loop (commerce-order:commerce-line-items)

and define a Rule component as below:

    Conditions:
  • Entity has field (Entity: commerce-line-item, Field: commerce_product)
  • Actions:

  • Grant points to a user: (User: commerce-line-item:commerce-product:creator, Points: commerce-line-item:commerce-product:commerce-price:amount)

But when I save component it makes error:

Error message
Data selector commerce-line-item:commerce-product:commerce-price:amount for parameter points is invalid.

How I can do that?
tnx

Asked by: fathollahi.mehdi
on November 24, 2012

1 Answer