Closed (fixed)
Project:
Magento
Version:
6.x-1.0-rc1
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
15 Jul 2009 at 11:30 UTC
Updated:
10 Apr 2010 at 11:30 UTC
Hi all,
There is a problem I faced with while integrating Magento: I have a pricing rule for a specified user group. However, when I create a quote from Drupal using magento_api_quote_create() it returns prices with all rules applied except the group-specific ones. If I set cutomer group in a pricing rule to NOT LOGGED IN (in Magento admin panel), magento_api_quote_create() returns the correct price. If anyone faced this problem and knows how to fix it? This is of great importance to me. I hope, I've explained my problem well =)
Thanks in advance.
Comments
Comment #1
chrisstina commentedHello again,
Is it only me, who faced this problem? I am in desperate need of any comments on this problem.
Well, what I have understood for now, the API function quote.create() tries to get a session, but since we are not logged in as a customer (but as an api user), Mage::getSingleton('checkout/session') returns an empty session (or whatever it considers as "not logged in" state). What I have done for now, is adding
before Mage::getSingleton('checkout/session'). At least, this leads to applying correct pricing rules, including the customer-specific ones.
This is the only way I've found to make it work. However, it feels that this approach is a potential security hole.
I have to mention, that I am new to Magento, so I may be missing something.
Please, help.
Comment #2
Maxime Topolov commentedChrisstina, we'll check that issue shortly, we were all in hollydays :) We'll get back with a solution asap. Thanks.
Comment #3
qwaygon commentedThis will be fixed (in fact already is) in 1.3.4 (will be available soon) along with all rule application and "actual price" determination routine along with other major improvements.
Comment #4
qwaygon commentedComment #5
qwaygon commentedI have released 1.4 and it fix this issue, thanks for your feedbacks
p.s. note that 1.4 version of drupal modules pack require 1.3.4 version of megento extension