Jump to content

Can`t import unit price with CSV


Recommended Posts

Hello 

 

I seems to be impossible to import unit price ratio. 

I create a csv file with 3 columns:                              ID, unit price,          unity.

Then in backoffice i map them to following fields:      ID, unity price ratio, unity

 

Afterwards I run the import process. Unity value is imported propely, but unit price field is empty?

Is it me or its a common problem?

 

My presta is 1.5.6.1

 

 

  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...

Hello 

 

I seems to be impossible to import unit price ratio. 

I create a csv file with 3 columns:                              ID, unit price,          unity.

Then in backoffice i map them to following fields:      ID, unity price ratio, unity

 

Afterwards I run the import process. Unity value is imported propely, but unit price field is empty?

Is it me or its a common problem?

 

My presta is 1.5.6.1

 

No Solution for this topic??

ohh i wanted to.

Link to comment
Share on other sites

  • 3 weeks later...

 

There is a bug in AdminImportController.php.

Replace the line (232):

'unit_price_ratio' => array ('label' => $ this-> l ('Unit price ratio')),
with:

'unit_price' => array ('label' => $ this-> l ('Unit price ratio')),
and it works.

 

 

Thanks it works

Link to comment
Share on other sites

  • 2 months later...

 

There is a bug in AdminImportController.php.

Replace the line (232):

'unit_price_ratio' => array ('label' => $ this-> l ('Unit price ratio')),
with:

'unit_price' => array ('label' => $ this-> l ('Unit price ratio')),
and it works.

 

 

Thanks, it works for me too.

Link to comment
Share on other sites

  • 2 weeks later...
  • 1 month later...
  • 4 months later...
  • 4 months later...
  • 5 months later...
  • 4 months later...
  • 4 months later...

using 1.6.1.3, unit price is imported but the decimal value is ignored, ex. : i have 10,52 in my CSV file but in the BO unit price is changed to 10,00. I don't use tax system at all.

 

It's not true, PS 1.6.1.5 not working yet. Anyone can help us?

Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...
  • 1 month later...

Hello,

 

For those who have the same problem as I had, I could find a solution (not sure if the propper one, but it works for me).

So, go to your AdminImportController.php file and make sure that in the 247 line where it says: 

 

'unit_price' => array('label' => $this->l('Unit price')),

 

and change it to:

 

'unit_price_ratio' => array('label' => $this->l('Unit price')),

 

Notice that 'unit_price_ratio' is the name of my Database column for this item (unit price). You need to make sure yours is the same. If not change the unit_price_ratio accordingly.

 

Thanks for the other suggestions that lead me to this solution.

Link to comment
Share on other sites

Hello,

 

For those who have the same problem as I had, I could find a solution (not sure if the propper one, but it works for me).

So, go to your AdminImportController.php file and make sure that in the 247 line where it says: 

 

'unit_price' => array('label' => $this->l('Unit price')),

 

and change it to:

 

'unit_price_ratio' => array('label' => $this->l('Unit price')),

 

Notice that 'unit_price_ratio' is the name of my Database column for this item (unit price). You need to make sure yours is the same. If not change the unit_price_ratio accordingly.

 

Thanks for the other suggestions that lead me to this solution.

I've tried but it doesnt work for me.

The voice is unit_price_ratio for my database too.

It is a draining situation -.-''

Link to comment
Share on other sites

×
×
  • Create New...