KonaKart Community Forum

Installation / Configuration => Configuration of KonaKart => Topic started by: michaelwechner on October 01, 2010, 10:16:28 pm

Title: How to increase the number of orders?
Post by: michaelwechner on October 01, 2010, 10:16:28 pm
Hi

AFAIK each customer can see/notice how many total orders have been accomplished.
This can look a bit "akward" when a new shop is setup, hence we would like to increase the number of orders.

What is the best way to do this? Just increase the counter within the DB?

Thanks

Michael
Title: Re: How to increase the number of orders?
Post by: Brian on October 05, 2010, 10:55:26 am
Hi,

Do you mean because of the order number that the customer sees?

If you want to create your own order number you can always implement a "createOrderNumber()" of your own... see the OrderIntegrationMgrInterface for details:


    /**
     * This method allows you to introduce a proprietary algorithm for creating the order number for
     * an order just before the order is saved. It is called by the <code>saveOrder()</code> method.
     * The value returned by this method populates the <code>orderNumber</code> attribute of the
     * order when it is saved.<br>
     * If a null value is returned, then the order number of the order is left unchanged.<br>
     * If an exception is thrown, the exception will be also thrown by the saveOrder() method and
     * the order will not be saved.
     *
     * @param order
     * @return Return the order number for the new order
     * @throws Exception
     */
    public String createOrderNumber(OrderIf order) throws Exception;



Alternatively, yes you could try increasing the sequence number in the database... but I would proceed with caution using this technique and check carefully with your particular database (and storage engine) that it is supported.
Title: Re: How to increase the number of orders?
Post by: michaelwechner on October 05, 2010, 11:57:53 am
thanks very much for this information.

Cheers

Michael