I am making a custom store that can sell half pounds of items. I've noticed through sending calls through my plugin to the
craft()->commerce_cart->addToCart($cart, $itemNumber, $qty); to add an item to an order while specifying a non-integer quantity gives me the error: "Qty must be an integer"
Is there any way to allow quantity to be a non-integer? Customers will be ordering in .5 pound increments occasionally. I am not anemic to plugin development and php so I thought I'd ask the community if there was a way around this, or if I'm stuck with Qty being an integer.
Couple other options I've though of:
- Make a custom field to deal with qty
- Split my items into .5 increments so someone adding 5.5 lbs would really be adding qty 11 and there'd be special things going on with the admin and front-end to hide that fact