This is not just another "stock by attributes" question. If I want to sell accessories at the bottom of a product page by using attributes, how do I do it so that stock levels are tracked too?

For example, I have five £10 widgets in stock. On the product page I set up a radio button attribute that has "Buy some batteries for your widget?". The options are "No" and "Yes +£2".

If the customer chooses to buy the batteries, the order entry in the shopping cart will be for one widget, plus batteries at total cost of £12. Zen-Cart will then deduct one widget from stock, but it doesn't recognise that the battery was another product ID that needs to have stock level reduced too.

Is there a way to do this?