Author Topic: temporary order id  (Read 388 times)

Offline limessl

  • Sr. Member
  • ****
  • Posts: 82
    • View Profile
temporary order id
« on: 21/February/2011, 01:29:44 PM »
I'm needing to allocate what will be a unique number to an order whilst it's in the process of being created. I seem to remember there's a "pending order" ID but I am not sure at what stage this is created.

So, question is simply "does nbill allocate any sort of unique reference to an order before it is confirmed?" It is only used for a temporary look up whilst the order is in progress, so it's not an issue if the temporary number is not stored once the order is correctly submitted.

many thanks in advance :)

Offline netshine

  • Administrator
  • Hero Member
  • *****
  • Posts: 4,984
    • View Profile
Re: temporary order id
« Reply #1 on: 21/February/2011, 01:53:52 PM »
There is a pending order ID, but it does not necessarily correlate with a single order. A pending order, when activated, can result in more than one order record being created. Pending orders are stored in the jos_nbill_pending_orders table.

Offline limessl

  • Sr. Member
  • ****
  • Posts: 82
    • View Profile
Re: temporary order id
« Reply #2 on: 22/February/2011, 08:32:15 PM »
The use of the temp ID will terminate well before the order's placed - it is needed simply to store something in a database and then retrieve it straight back on the next page. My concern was simply that a temp ID might get re-used by the system and cause conflict.

Offline netshine

  • Administrator
  • Hero Member
  • *****
  • Posts: 4,984
    • View Profile
Re: temporary order id
« Reply #3 on: 23/February/2011, 08:46:19 AM »
Pending order IDs are not re-used, although it is possible for an existing client to abandon an order and then resume it later (in which case there could be 2 different gateway transaction IDs but only 1 pending order ID).