Jump to content

Id oridne nella pagine storico ordini


Recommended Posts

  • 3 months later...

Non sò se ti serve ancora, ma sicuramente servirà a qualcun altro:

 

la soluzione è

 

Aprire il file Order.php in classes>order

 

trovare la riga (è verso la fine)

 

e aggiungere le parti in rosso

 

     public function getUniqReference()
 

 

    {
             $query = new DbQuery();
             $query->select('MIN(id_order) as min, MAX(id_order) as max');
             $query->from('orders');
             $query->where('id_cart = '.(int)$this->id_cart);
             $query->orderBy('id_order');

             $order = Db::getInstance()->getRow($query);
            
            
/*if ($order['min'] == $order['max'])
                     return $this->reference;
             else
                     return $this->reference.'#'.($this->id + 1 - $order['min']);*/

                    
            
return sprintf('%06d', $this->id);
     }

 

 

 

Testato il funzionamento sulla versione 1.6.0.9

 

Se funziona metti il "RISOLTO" nel titolo del topic

 

Bye

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...
  • 9 months later...
  • 5 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...