Jump to content
cingkonext

[MODULE] Priceupdate

Recommended Posts

what you exactly expect?

Share this post


Link to post
Share on other sites

Bad english.. sorry..

 

This is my module to update the references, price, weight and quantity product, as well as to update the product status. products that appear on the display is restricted by category.

problem: This module has not been able to update the table product_shop, quantity field in the table stock_available and some other additional functions that I have written it in the script module file (priceupdate.php)

Share this post


Link to post
Share on other sites

[PrestaShop] Fatal error in module priceupdate:

syntax error, unexpected '['

 

PS 1.5.3.1

Edited by Fehmi135 (see edit history)

Share this post


Link to post
Share on other sites

Hi!

If you are writing a price updater module for 1.5x I will be glad to help any way. But when I´d try to install it:

 

[PrestaShop] Fatal error in module priceupdate:

syntax error, unexpected '['

Share this post


Link to post
Share on other sites

PREVIEW:

post-24657-0-69052800-1368193467_thumb.jpg

 

priceupdate.zip

I have updated this module. I apply this module in prestashop version 1.5.4.1 (localhost) and this module works very well.

This module without including the update status of the product (checkbox).

 

This module has not been developed to update product combinations. Please help you all to enhance this module.

 

Thank you very much

Edited by hady (see edit history)

Share this post


Link to post
Share on other sites

Hi!

Still showing:

[PrestaShop] Fatal error in module priceupdate:

syntax error, unexpected '['

 

I can´t even install it.

I have Prestashop 1.5.3.1

Edited by leomazz (see edit history)

Share this post


Link to post
Share on other sites

Hi!

Still showing:

[PrestaShop] Fatal error in module priceupdate:

syntax error, unexpected '['

 

I hace Prestashop 1.5.3.1

Me too.

Share this post


Link to post
Share on other sites

I just tried this module on prestashop 1.5.3.1 and this module also works very well.

This module deficiency: could not update the entries for a combination product such as price impact, weight impact and quantity.

post-24657-0-49105100-1368416548_thumb.jpg

Edited by hady (see edit history)

Share this post


Link to post
Share on other sites

PREVIEW:

post-24657-0-69052800-1368193467_thumb.jpg

 

I have updated this module. I apply this module in prestashop version 1.5.4.1 (localhost) and this module works very well.

This module without including the update status of the product (checkbox).

 

This module has not been developed to update product combinations. Please help you all to enhance this module.

 

Thank you very much

 

 

 

Hi Hady!

I have so much expectations to test your module!!!!

But I can´t even install it.

What can I do?

Share this post


Link to post
Share on other sites

Hi Hady!

I have so much expectations to test your module!!!!

But I can´t even install it.

What can I do?

 

maybe you can try to install prestashop version 1.5.xx on a local server first, then try this module installed.

I also did the same thing when you say that this module can not be installed in prestashop 1.5.3.1. But I can put it up and this module run well at all.

 

issues related to language or country I think it's not a problem, because I tried this module without changing anything related to language or country

Edited by hady (see edit history)

Share this post


Link to post
Share on other sites

ohh .. I know the problem now,

 

the problem is in this code:

 

'reference'=>''.(Tools::getValue('reference')[$i]),
'price'=>''.(int)(Tools::getValue('price')[$i]),
'quantity'=>''.(Tools::getValue('quantity')[$i]),
'weight'=>''.(Tools::getValue('weight')[$i])

Edited by hady (see edit history)

Share this post


Link to post
Share on other sites

Hi thank you for sharing. The installation is ok, but I don't see anything from the B.O, except "Pilih" ?

 

185348priceup.png

Edited by Fehmi135 (see edit history)

Share this post


Link to post
Share on other sites

Hi thank you for sharing. The installation is ok, but I don't see anything from the B.O, except "Pilih" ?

 

185348priceup.png

 

This time I've tried this module on my website: www.alatlukis.com. and this module is working properly.

as seen in this picture:

post-24657-0-03190500-1368521169_thumb.jpg

Share this post


Link to post
Share on other sites

It's work perfect!!! but there's a error for me:

 

Quantity is set to 0 in all products. When i list products, in the table, qty column is the same that i have in my BD in ps_product, i mean, 0. The real stock (prestashop 1.5.4) can be found in ps_stock_available so i think i´ll try to fix this by changing the select and update functions.

 

Thanks hady for your work.

Edited by xinito (see edit history)

Share this post


Link to post
Share on other sites

We are closing!

Now I could install it, it shows the prices but the row Qty shows all "0"

Share this post


Link to post
Share on other sites

We are closing!

Now I could install it, it shows the prices but the row Qty shows all "0"

quantity displayed 0 because the value selected from the table ps_product, while quantity is really on the table ps_stock_available.

 

I hope there is someone who helps to enhance this module ..

Share this post


Link to post
Share on other sites

Any one looking at this fantastic tool? Come on!!!!!!

 

Thanks!

Share this post


Link to post
Share on other sites

Well, i´m not an expert in mysql but i´m trying to fix the quantity problem, about line 164 of priceupdate.php:

 

//products

$sqlproducts = 'SELECT * FROM `'._DB_PREFIX_.'product` p

LEFT JOIN `'._DB_PREFIX_.'product_lang` pl ON (p.`id_product` = pl.`id_product`)

WHERE (p.`id_category_default` = '.(int)$id_category.'

AND pl.`id_lang` = '.(int)$language.')';

 

$products = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS($sqlproducts);

 

i would like to know how to add a mysql sentence more to select the quantity row in ps_stock_available.

Edited by xinito (see edit history)

Share this post


Link to post
Share on other sites

I see that the quantity value in the table: "ps_product" does not affect anything against the stock. precisely the value of the product quantity is taken from field "quantity" at the table "ps_stock_available" where "id_product_attibute" = 0. and its quantity value is the sum of the whole quantity attribute values ​​associated with the product.

 

for example: if the product "x" has the 5 attributes and each attribute has a value of quantity 7, the product quantity is 5 * 7 = 35.

post-24657-0-06295200-1369103726_thumb.jpg

 

 

 

FIX in productupdate.php:

replace :

$languages = Country::getCountries($this->context->language->id); 

 

with :

$language = Context::getContext()->language->id;

 

and remove:

foreach ($languages as $language)

 

OR download this updated

priceupdate.zip

Edited by hady (see edit history)

Share this post


Link to post
Share on other sites

hello ..

this module not support UTF8 ... PLEASE HELP ME ...

Capture.PNG

Share this post


Link to post
Share on other sites

hello ..

this module not support UTF8 ... PLEASE HELP ME ...

Capture.PNG

I did not know about it, maybe you can try to change this: (priceupdate.php)

'. htmlentities ($ product [' name '].'').'

into this:

'. $ product [' name '].'

Share this post


Link to post
Share on other sites

thank you for answer .. i try this , not ok ... this bug must update for use better ... please solved this problem ...

Share this post


Link to post
Share on other sites

i get this error

Fatal error: Call to a member function getSign() on a non-object in /www/modules/priceupdate/priceupdate.php on line 216

Share this post


Link to post
Share on other sites

BAD ENGLISH, Sorry

 

I have tried to fix this module. And now, this module is able to display a combination product (but has not reached the process of updating the values ​​associated with the combination product).

priceupdate.zip

 

 

The problem:

looping the list of combinations of existing products on the line before the line products thereafter. as shown in the picture that I attach

post-24657-0-38675100-1369661792_thumb.jpg

 

if there is someone willing to help solve this problem?

Edited by hady (see edit history)

Share this post


Link to post
Share on other sites

Well done Hady!

It works more than perfect!!!!

I`d put your link in my site: http://undermusicweb.com.ar

 

Question:

Would be possible to add a combo box to select "manufacter"?

 

Thank you very much again!!

 

leomazz

Share this post


Link to post
Share on other sites

Well done Hady!

It works more than perfect!!!!

I`d put your link in my site: http://undermusicweb.com.ar

 

Question:

Would be possible to add a combo box to select "manufacter"?

 

Thank you very much again!!

 

leomazz

thank you...

 

yes, we can add options manufacturer. I will try to add the option in the next few days..

Share this post


Link to post
Share on other sites

thanks very much for your module. Is possible modify final price with vat included instead of price without vat?

 

best regards

Share this post


Link to post
Share on other sites

Hi!

Any news about the "Manufacturer" combo box?

Thanks!

Share this post


Link to post
Share on other sites

Not work in PS 1.4.9.0, when i open the configuration folder the page dont make the complete load, and dont show nothing..

 

Any suggestion ?

 

Tks..

Share this post


Link to post
Share on other sites

Hi again!

How can I change the code to order de results by "product name" instead of "product_id" ?

 

Thanks!

Share this post


Link to post
Share on other sites

Nice module, works very nice in 1.5.4.

 

is possible to have some export - import to csv or excel?

 

many thanks!

Share this post


Link to post
Share on other sites

Hi! I´m refloting this topic...

Any news to the "manufacter" selector? or any idea to how modify it to choose "manufacter"?

 

Thanks!

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More