More then 999 products

Coastal Scents

Avatar: Coastal Scents

2013-08-26 14:53

I would like to add more products.
Not that I have more then 999 products but I need it for this :

My product catalogue has 13 chapters.
Each chapter has not more then 99 products.
Now I would like to have the position of the products like my product catalogue.

For example : Chapter 9, product 11 => admin position of the product = 911
So far no problem...

Another example : Chapter 12, product 35 => admin position of the product = 1235

So in fact, I just need 4 digits in stead of 3.

I hope someone can help.

» Quick.Cart v6.x

treewood (OpenSolution)

Avatar: treewood

2013-08-26 15:19

edit core/products-admin.php and find:

if( !isset( $aForm['iPosition'] ) || !is_numeric$aForm['iPosition'] ) || $aForm['iPosition'] < -99 || $aForm['iPosition'] > 999 )

and replace to:

if( !isset( $aForm['iPosition'] ) || !is_numeric$aForm['iPosition'] ) || $aForm['iPosition'] < -99 || $aForm['iPosition'] > 9999 )



In the same file find:

<input type="text" name="aPositions['.$aData['iProduct'].']" value="'.$aData['iPosition'].'" class="inputr" size="2" maxlength="3" />

replace to:

<input type="text" name="aPositions['.$aData['iProduct'].']" value="'.$aData['iPosition'].'" class="inputr" size="2" maxlength="4" />



After edit templates/admin/products-form.php and find:

<input type="text" name="iPosition" value="<?php echo isset( $aData['iPosition'] ) ? $aData['iPosition'] : 0?>" class="inputr" size="3" maxlength="3" />

and replace to:

<input type="text" name="iPosition" value="<?php echo isset( $aData['iPosition'] ) ? $aData['iPosition'] : 0?>" class="inputr" size="4" maxlength="4" />

Coastal Scents

Avatar: Coastal Scents

2013-08-26 15:28

WOW

Thank you very much. You are quicker then my shadow :-)

It is not that I want to profit... but I have another question...

In my product catalogue, all prices are VAT ex.
So when I insert them in QC, it is product price ex VAT.

So I would like that price net becomes pricenet + VAT and the other way around...

treewood (OpenSolution)

Avatar: treewood

2013-08-27 11:07

There is plugin vatLite:
http://opensolution.org/download,en,18.html?sDir=Quick.Cart%2Fplugins&sWord=vat&sEdition=all

It calculates net from price with VAT because prices that you add to product are incl with VAT.

Coastal Scents

Avatar: Coastal Scents

2013-08-27 12:50

Dear Treewood,

thanks for your answer.

Plugin vatLite is already installed.
Indeed it calculates net price from price with VAT.

I have changed :
$this->aProducts[$aValue['iProduct']]['fPriceNetto'] = normalizePrice( ( $this->aProducts[$aValue['iProduct']]['mPrice'] / $this->aProducts[$aValue['iProduct']]['fVatCount'] ) );
to
$this->aProducts[$aValue['iProduct']]['fPriceNetto'] = normalizePrice( ( $this->aProducts[$aValue['iProduct']]['mPrice'] * $this->aProducts[$aValue['iProduct']]['fVatCount'] ) );

So now I can add products excl. VAT

Problem now : at checkout, prices are without VAT and should be with VAT

Back to top
about us | contact