Page 1 of 1

How to access current order from custom serial key provider?

Posted: Tue Sep 23, 2008 11:08 am
by poconnell
How can I get access to the current order from within a custom serial key provider?

In my store, the SAME digital good is available with 1 and 12 month subscriptions and this needs to be reflected in the assigned key.

My experiments show that the DigitalGood provided in the Initialize method is simply a reference into the catalog as a whole and provides no means to navigate to the actual order being placed/activated.

Am I missing something? Is there a "global" way to access the active order (via HttpContext perhaps?)

Thanks for any suggestions,

Pete

Re: How to access current order from custom serial key provider?

Posted: Tue Sep 23, 2008 1:56 pm
by afm
According to this thread, the order is not easily accessible (I'm thinking it is not accessible at all in the current build).

According to bug 7047, there will be a new AcquireSerialKey overload in 7.1 that provides access to the order item (and order, etc). The notes suggest that they may send you a private hotfix with the new overload if you request it.

Re: How to access current order from custom serial key provider?

Posted: Wed Sep 24, 2008 8:46 am
by poconnell
Thanks Andy.

I hadn't seen that bug report/discussion - but it sounds like that hotfix is what I needed.

Pete