Jump to content

AndreasAnemyr

Members
  • Posts

    8
  • Joined

  • Last visited

1 Follower

Profile Information

  • Location
    Sweden
  • Activity
    Web development agency

Recent Profile Visitors

1,764,544 profile views

AndreasAnemyr's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. And solution is.... ( I use prestashop 1.4.0.17) yourtheme/shopping-cart-product-line.tpl: Change the inputfield to readonly="readonly". Customer would not be able to change it to custom value Put a new hidden field in yourtheme/shopping-cart-product-line.tpl <input id="min_{$product.id}_{$productAttributeId}" type="hidden" value"$product.minimal.quantity" With Jquery you can use this new hidden field to change the "default" qty. for eht functions downQuantity( ) & upQuantity( ) This is done in the cart-summary.js This is the simple code how it´s made... qty = $('#min_'+ productID+'_'+productAttributeId).val( ); Do you need more information. Reply here and i will explain more in details....
  2. I use 1.4.0.17 Problem: When the user clicks on upQuantity or the downQuantity the used value should be based on the minal Qty (you can set this value in general info or on the combinations if used... Example Min qty = 3pcs When you click Up, it counts up 3,6,9,12 ..... Not 3,4,5,6... order-opc.php Would be great if somene have a great solution for this ( maybe in the js cart_summary. Best regards! Andréas
  3. $ret = (isset($_POST[$key]) ? $_POST[$key] : (isset($_GET[$key]) ? $_GET[$key] : $defaultValue)); is the code above the same as: if(){ } elseif(){ } else{ } That syntax is new flr me... //Andreas
  4. Happy me!!! To use decimals i had to change all the int cast's to float's instead. But in the cart.php in the classes folder i forgot one... if ((float)$quantity < $minimalQuantity) return -1; I think my solution now works fine for 1.4.0.17. thx to Vekia for the ...tpl help!!!
  5. i've done all the canges (wfreebird gave) but... When i Add product... let´s say with value 10.25 from product.php, with a minium_quantity of 10.25 (the same valu) It seem likt that value is rounde (ceil...) to 10. So it´s not possible to add 10.25. But 11.... Maybe i forgot some changes. Plz Help....
  6. Thx Vekia for your answer! I also wonder how/where this input value is controlled/validated (and autocahnged...) I mod my prestashop to use decimals in all the Qty-felts.... This should be accepted for the input: 10.25 11.23 9,75 for example... Best regards! /Andréas
  7. Hi! I want to use more than 3 chars in the qty form, from the side .... product.php. Where can i change this value. I use 1.4.0.17 Is this controlled in js or somewhere else. Can't find.... Best Regards! Andréas
×
×
  • Create New...