0

I update the QTY based on case_size of a product. I've made an observer to do that. If the case_size is 144 and a customer buys two cases then QTY will automatically become 288PCS. When the customer clicks the Edit button then the product QTY on the add to cart page goes back to 2 case. Everything is working good, but when a customer edits the QTY see (image) then everything goes wrong of course!!

I want to remove the UPDATE button and make the QTY input readonly but until now no luck.

I've tried app\design\frontend\base\default\template\checkout\cart.phtml but it works on the magento/checkout/cart/configure page not on magento/checkout/cart/ (see image)

Any tips would be highly appreciated.

Thank you all

magento/checkout/cart/

6
  • have you used any custom magento theme?
    – Abdul
    Commented Nov 7, 2015 at 7:05
  • Yes we have our own theme and I put these files in my theme's template folder. Of course no direct editing the CORE files.
    – Jos
    Commented Nov 7, 2015 at 7:13
  • pls update code in your theme's themplate file :: template\checkout\cart\item\default.phtml
    – Abdul
    Commented Nov 7, 2015 at 7:42
  • find <input name="cart[<?php echo $_item->getId() ?>][qty]" value="<?php echo $this->getQty() ?>" size="4" title="<?php echo $this->__('Qty') ?>" class="input-text qty" maxlength="12" />
    – Abdul
    Commented Nov 7, 2015 at 7:43
  • Replace : <input name="cart[<?php echo $_item->getId() ?>][qty]" value="<?php echo $this->getQty() ?>" size="4" title="<?php echo $this->__('Qty') ?>" class="input-text qty" disabled="disabled" maxlength="12" />
    – Abdul
    Commented Nov 7, 2015 at 7:43

1 Answer 1

0

To finalize the question Mr.Abdul has answered me and after change everything is working as expected.

So the problem is solved. Thank you Mr. Abdul and everyone else.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.